RESOLVED FIXED233040
Some C++ source files use #pragma once
https://bugs.webkit.org/show_bug.cgi?id=233040
Summary Some C++ source files use #pragma once
Adrian Perez
Reported 2021-11-12 06:08:52 PST
Given that “#pragma once” is intended to be used only in headers (or, more precisely, in files that get “#include”'d), it does not make sense to make use of it inside implementation .cpp files, yet it is present in a few: % rg --files-with-matches --glob '*.cpp' '^#pragma once' Source/ Source/WebKit/WebProcess/WebCoreSupport/WebCaptionPreferencesDelegate.cpp Source/WebCore/Modules/WebGPU/GPURenderPassEncoder.cpp Source/WebCore/Modules/WebGPU/GPURenderBundleEncoder.cpp Source/WebCore/Modules/WebGPU/GPUQueue.cpp Source/WebCore/Modules/WebGPU/GPUQuerySet.cpp Source/WebCore/Modules/WebGPU/GPUComputePassEncoder.cpp Source/WebCore/Modules/WebGPU/GPUCommandEncoder.cpp Source/WebCore/Modules/WebGPU/GPUBuffer.cpp Source/WebCore/page/PerformanceNavigationTiming.cpp % At least GCC 11.1 will warn about these spurious uses.
Attachments
Patch (5.93 KB, patch)
2021-11-12 06:11 PST, Adrian Perez
ews-feeder: commit-queue-
Adrian Perez
Comment 1 2021-11-12 06:11:56 PST
Adrian Perez
Comment 2 2021-11-12 08:28:39 PST
Thanks cdumez! The build failure from the mac-wk1 is unrelated, that queue seems to be having trouble lately, so I'll go ahead and mark this cq+ :)
Chris Dumez
Comment 3 2021-11-12 08:30:52 PST
(In reply to Adrian Perez from comment #2) > Thanks cdumez! The build failure from the mac-wk1 is unrelated, that > queue seems to be having trouble lately, so I'll go ahead and mark > this cq+ :) Yes, I filed https://bugs.webkit.org/show_bug.cgi?id=233043 and skipped that test due to all these ews mac-wk1 false positives.
EWS
Comment 4 2021-11-12 08:39:56 PST
Committed r285724 (244183@main): <https://commits.webkit.org/244183@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 444061 [details].
Radar WebKit Bug Importer
Comment 5 2021-11-12 08:40:24 PST
Myles C. Maxfield
Comment 6 2021-11-12 11:01:17 PST
Thanks for fixing this!!!
Adrian Perez
Comment 7 2021-11-14 14:39:55 PST
(In reply to Myles C. Maxfield from comment #6) > Thanks for fixing this!!! No problem at all :)
Note You need to log in before you can comment on or make changes to this bug.