Templatize NoncopyableFunction class similarly to std::function, so that it can be used as a std::function replacement in more places. Currently, NoncopyableFunction only supports "void()" lambdas.
Created attachment 280050 [details] Patch
Attachment 280050 [details] did not pass style-queue: ERROR: Source/WebCore/platform/mediastream/mac/AVMediaCaptureSource.mm:243: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.h:42: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.h:49: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.h:52: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.h:58: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.h:65: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/MainThread.cpp:50: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/MainThread.cpp:52: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/MainThread.cpp:123: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/MainThread.cpp:147: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/WorkQueue.h:75: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/WorkQueue.h:76: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/fileapi/AsyncFileStream.cpp:67: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/fileapi/AsyncFileStream.cpp:72: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/fileapi/AsyncFileStream.cpp:93: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkQueueWin.cpp:132: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkQueueWin.cpp:152: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkQueueWin.cpp:183: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/glib/RunLoopGLib.cpp:127: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/glib/RunLoopGLib.cpp:138: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/glib/RunLoopGLib.cpp:141: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheIOChannelSoup.cpp:72: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.h:51: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.h:55: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.h:83: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:627: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/WorkQueueEfl.cpp:57: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/WorkQueueEfl.cpp:65: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.h:81: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.h:95: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.cpp:98: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/RunLoopGeneric.cpp:35: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/RunLoopGeneric.cpp:40: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/RunLoopGeneric.cpp:93: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/RunLoopGeneric.cpp:240: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.h:146: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/WorkQueueGeneric.cpp:84: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/WorkQueueGeneric.cpp:92: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/FunctionDispatcher.h:42: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.cpp:94: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.cpp:109: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.cpp:126: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/cocoa/WorkQueueCocoa.cpp:31: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/cocoa/WorkQueueCocoa.cpp:42: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.cpp:48: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.cpp:61: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.cpp:107: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.h:62: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.h:82: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.h:158: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/MainThread.h:44: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.cpp:35: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.cpp:41: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.cpp:50: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.cpp:58: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageThread.h:49: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageThread.h:62: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageThread.cpp:77: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageThread.cpp:81: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageThread.cpp:93: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/platform/mediastream/mac/AVMediaCaptureSource.h:89: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/platform/mediastream/MediaStreamPrivate.h:115: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/platform/mediastream/MediaStreamPrivate.cpp:302: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageSyncManager.h:46: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageSyncManager.cpp:66: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/DispatchQueueWorkItemEfl.h:37: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/DispatchQueueWorkItemEfl.h:47: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/DispatchQueueWorkItemEfl.h:52: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/DispatchQueueWorkItemEfl.h:61: Extra space before ( in function call [whitespace/parens] [4] Total errors found: 69 in 37 files If any of these errors are false positives, please file a bug against check-webkit-style.
Created attachment 280051 [details] Patch
Attachment 280051 [details] did not pass style-queue: ERROR: Source/WebCore/platform/mediastream/mac/AVMediaCaptureSource.mm:243: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.h:42: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.h:49: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.h:52: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.h:58: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.h:65: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/MainThread.cpp:50: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/MainThread.cpp:52: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/MainThread.cpp:123: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/MainThread.cpp:147: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/WorkQueue.h:75: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/WorkQueue.h:76: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/fileapi/AsyncFileStream.cpp:67: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/fileapi/AsyncFileStream.cpp:72: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/fileapi/AsyncFileStream.cpp:93: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkQueueWin.cpp:132: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkQueueWin.cpp:152: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkQueueWin.cpp:183: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/glib/RunLoopGLib.cpp:127: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/glib/RunLoopGLib.cpp:138: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/glib/RunLoopGLib.cpp:141: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheIOChannelSoup.cpp:72: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.h:51: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.h:55: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.h:83: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:627: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/WorkQueueEfl.cpp:57: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/WorkQueueEfl.cpp:65: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.h:81: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.h:95: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.cpp:98: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/RunLoopGeneric.cpp:35: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/RunLoopGeneric.cpp:40: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/RunLoopGeneric.cpp:93: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/RunLoopGeneric.cpp:240: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.h:146: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/WorkQueueGeneric.cpp:84: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/WorkQueueGeneric.cpp:92: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/FunctionDispatcher.h:42: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.cpp:94: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.cpp:109: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.cpp:126: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/cocoa/WorkQueueCocoa.cpp:31: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/cocoa/WorkQueueCocoa.cpp:42: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.cpp:48: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.cpp:61: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.cpp:107: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.h:62: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.h:82: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.h:158: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/MainThread.h:44: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.cpp:35: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.cpp:41: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.cpp:50: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.cpp:58: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageThread.h:49: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageThread.h:62: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageThread.cpp:77: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageThread.cpp:81: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageThread.cpp:93: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/platform/mediastream/mac/AVMediaCaptureSource.h:89: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/platform/mediastream/MediaStreamPrivate.h:115: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/platform/mediastream/MediaStreamPrivate.cpp:302: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageSyncManager.h:46: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageSyncManager.cpp:66: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/DispatchQueueWorkItemEfl.h:37: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/DispatchQueueWorkItemEfl.h:47: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/DispatchQueueWorkItemEfl.h:52: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/DispatchQueueWorkItemEfl.h:61: Extra space before ( in function call [whitespace/parens] [4] Total errors found: 69 in 37 files If any of these errors are false positives, please file a bug against check-webkit-style.
Created attachment 280052 [details] Patch
Attachment 280052 [details] did not pass style-queue: ERROR: Source/WebCore/platform/mediastream/mac/AVMediaCaptureSource.mm:243: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.h:42: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.h:49: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.h:52: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.h:58: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.h:65: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/MainThread.cpp:50: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/MainThread.cpp:52: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/MainThread.cpp:123: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/MainThread.cpp:147: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/WorkQueue.h:75: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/WorkQueue.h:76: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/fileapi/AsyncFileStream.cpp:67: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/fileapi/AsyncFileStream.cpp:72: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/fileapi/AsyncFileStream.cpp:93: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkQueueWin.cpp:132: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkQueueWin.cpp:152: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkQueueWin.cpp:183: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/glib/RunLoopGLib.cpp:127: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/glib/RunLoopGLib.cpp:138: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/glib/RunLoopGLib.cpp:141: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheIOChannelSoup.cpp:72: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.h:51: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.h:55: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.h:83: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:627: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/WorkQueueEfl.cpp:57: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/WorkQueueEfl.cpp:65: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.h:81: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.h:95: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.cpp:98: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/RunLoopGeneric.cpp:35: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/RunLoopGeneric.cpp:40: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/RunLoopGeneric.cpp:93: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/RunLoopGeneric.cpp:240: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.h:146: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/WorkQueueGeneric.cpp:84: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/generic/WorkQueueGeneric.cpp:92: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/FunctionDispatcher.h:42: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.cpp:94: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.cpp:109: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.cpp:126: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/cocoa/WorkQueueCocoa.cpp:31: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/cocoa/WorkQueueCocoa.cpp:42: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.cpp:48: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.cpp:61: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/page/scrolling/ScrollingThread.cpp:107: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.h:62: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.h:82: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/RunLoop.h:158: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/MainThread.h:44: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.cpp:35: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.cpp:41: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.cpp:50: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/win/WorkItemWin.cpp:58: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageThread.h:49: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageThread.h:62: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageThread.cpp:77: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageThread.cpp:81: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageThread.cpp:93: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/platform/mediastream/mac/AVMediaCaptureSource.h:89: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/platform/mediastream/MediaStreamPrivate.h:115: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebCore/platform/mediastream/MediaStreamPrivate.cpp:302: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageSyncManager.h:46: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit/Storage/StorageSyncManager.cpp:66: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/DispatchQueueWorkItemEfl.h:37: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/DispatchQueueWorkItemEfl.h:47: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/DispatchQueueWorkItemEfl.h:52: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WTF/wtf/efl/DispatchQueueWorkItemEfl.h:61: Extra space before ( in function call [whitespace/parens] [4] Total errors found: 69 in 37 files If any of these errors are false positives, please file a bug against check-webkit-style.
Comment on attachment 280052 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=280052&action=review > Source/WTF/wtf/NoncopyableFunction.h:36 > +template <typename Out, typename... In> > +class NoncopyableFunction<Out(In...)> { The one thing I don’t understand about this template is that I would have expected it to contain a std::function as a data member and forward things in and out. > Source/WTF/wtf/NoncopyableFunction.h:78 > - class CallableWrapper final : public CallableWrapperBase { > + class CallableWrapper : public CallableWrapperBase { Why no longer final?
Comment on attachment 280052 [details] Patch Clearing flags on attachment: 280052 Committed r201493: <http://trac.webkit.org/changeset/201493>
All reviewed patches have been landed. Closing bug.
God dammit. I'm doing this right now. *Sigh*
(In reply to comment #7) > Comment on attachment 280052 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=280052&action=review > > > Source/WTF/wtf/NoncopyableFunction.h:36 > > +template <typename Out, typename... In> > > +class NoncopyableFunction<Out(In...)> { > > The one thing I don’t understand about this template is that I would have > expected it to contain a std::function as a data member and forward things > in and out. > > > Source/WTF/wtf/NoncopyableFunction.h:78 > > - class CallableWrapper final : public CallableWrapperBase { > > + class CallableWrapper : public CallableWrapperBase { > > Why no longer final? Oops, I did not mean to drop it.
Comment on attachment 280052 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=280052&action=review That'll teach me to work on something before checking my email ever 4 hours ever again. That said, I spotted something that I believe is suboptimal. > Source/WTF/wtf/NoncopyableFunction.h:46 > + Out operator()(In... in) const I believe this could be: Out operator()(In&&... in) const > Source/WTF/wtf/NoncopyableFunction.h:74 > + virtual Out call(In...) = 0; I believe this could be: virtual Out call(In&&... in) = 0; > Source/WTF/wtf/NoncopyableFunction.h:88 > + Out call(In... in) final { return m_callable(std::forward<In>(in)...); } I believe this could be: Out call(In&&... in) final { return m_callable(std::forward<In>(in)...); }
(In reply to comment #10) > God dammit. > > I'm doing this right now. > > *Sigh* Sorry, I did not know. I thought you were working on cleaning up the dispatch() call sites.
(In reply to comment #7) > Comment on attachment 280052 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=280052&action=review > > > Source/WTF/wtf/NoncopyableFunction.h:36 > > +template <typename Out, typename... In> > > +class NoncopyableFunction<Out(In...)> { > > The one thing I don’t understand about this template is that I would have > expected it to contain a std::function as a data member and forward things > in and out. Just to close the loop on this review feedback, and leave it here for the record in case anybody else is looking around in the future: We actually *can't* do this, and the reason why is why we had to make NoncopyableFunction in the first place. std::function<> has a crappy spec requirement which is that any std::function<> has to be Copy Constructible. Even if you plan to be very careful, and only ever move() your std::function<>s around, never making copies of them... std::function itself is still copy constructible. Which means, if you're wrapping a lambda that is *not* copy constructible, std::function<> cannot wrap it. So lambdas that contain Ref<> or std::unique_ptrs<> cannot be wrapped by std::function<> And it turns out we have a *lot* of such lambdas that we *want* to wrap in a std::function<>-type wrapper.
Comment on attachment 280052 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=280052&action=review >> Source/WTF/wtf/NoncopyableFunction.h:46 >> + Out operator()(In... in) const > > I believe this could be: > Out operator()(In&&... in) const my version matches std::function I believe. Since In is a template , it can match references or rvalue references.
(In reply to comment #13) > (In reply to comment #10) > > God dammit. > > > > I'm doing this right now. > > > > *Sigh* > > Sorry, I did not know. I thought you were working on cleaning up the > dispatch() call sites. You had no way of knowing. I was working on that. And it turns out, to make meaningful progress on that task, I needed this. :) No bigs, I had barely templates out the WTF class and hadn't done any of this other work.
(In reply to comment #15) > Comment on attachment 280052 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=280052&action=review > > >> Source/WTF/wtf/NoncopyableFunction.h:46 > >> + Out operator()(In... in) const > > > > I believe this could be: > > Out operator()(In&&... in) const > > my version matches std::function I believe. Since In is a template , it can > match references or rvalue references. I guess what I was getting at was that if our NoncopyableFunction *only* had the && form, then we could enforce only using it with moveable parameters, perhaps saving unnecessary copying along the way. It's probably not worth fixing the trouble that would arise.
(In reply to comment #17) > (In reply to comment #15) > > Comment on attachment 280052 [details] > > Patch > > > > View in context: > > https://bugs.webkit.org/attachment.cgi?id=280052&action=review > > > > >> Source/WTF/wtf/NoncopyableFunction.h:46 > > >> + Out operator()(In... in) const > > > > > > I believe this could be: > > > Out operator()(In&&... in) const > > > > my version matches std::function I believe. Since In is a template , it can > > match references or rvalue references. > > I guess what I was getting at was that if our NoncopyableFunction *only* had > the && form, then we could enforce only using it with moveable parameters, > perhaps saving unnecessary copying along the way. > > It's probably not worth fixing the trouble that would arise. Ah ok. I was trying to stay as close as possible to std::function, merely making it non copyable. For the record, using In&& by itself would not force the caller to pass an rvalue reference. it would require further restriction on In, similarly to what I did for the CallableType template parameter.