Summary: | REGRESSION(r225769): Build errors with constexpr std::tie on older gcc | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Ms2ger (he/him; ⌚ UTC+1/+2) <Ms2ger> | ||||||||||
Component: | Layout and Rendering | Assignee: | Yusuke Suzuki <ysuzuki> | ||||||||||
Status: | RESOLVED FIXED | ||||||||||||
Severity: | Normal | CC: | benjamin, bfulgham, cdumez, cgarcia, clopez, cmarcelo, darin, dbates, ews-watchlist, mcatanzaro, mmaxfield, simon.fraser, webkit-bug-importer, ysuzuki, zalan | ||||||||||
Priority: | P2 | Keywords: | InRadar | ||||||||||
Version: | WebKit Nightly Build | ||||||||||||
Hardware: | Unspecified | ||||||||||||
OS: | Unspecified | ||||||||||||
See Also: | https://bugs.webkit.org/show_bug.cgi?id=181160 | ||||||||||||
Bug Depends on: | |||||||||||||
Bug Blocks: | 178894 | ||||||||||||
Attachments: |
|
Description
Ms2ger (he/him; ⌚ UTC+1/+2)
2017-12-12 02:33:37 PST
Created attachment 329104 [details]
Patch
Comment on attachment 329104 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=329104&action=review > Source/WTF/wtf/StdLibExtras.h:451 > +#if !GCC_VERSION_AT_LEAST(6, 0, 0) GCC_VERSION_AT_LEAST is only defined in COMPILER(GCC) environment. So, we cannot use `#if COMPILER(GCC) && !GCC_VERSION_AT_LEAST(6, 0, 0)`. Attachment 329104 [details] did not pass style-queue:
ERROR: Source/WTF/wtf/StdLibExtras.h:454: This { should be at the end of the previous line [whitespace/braces] [4]
ERROR: Source/WTF/wtf/StdLibExtras.h:458: Use 'using namespace std;' instead of 'using std::tie;'. [build/using_std] [4]
ERROR: Source/WTF/wtf/StdLibExtras.h:461: Use 'using namespace std;' instead of 'using std::tie;'. [build/using_std] [4]
ERROR: Source/WebCore/ChangeLog:8: You should remove the 'No new tests' and either add and list tests, or explain why no new tests were possible. [changelog/nonewtests] [5]
Total errors found: 4 in 4 files
If any of these errors are false positives, please file a bug against check-webkit-style.
Comment on attachment 329104 [details] Patch Seems to have failed the Windows EWS build: https://webkit-queues.webkit.org/results/5628920 C:\WebKit-EWS\WebKit\Source\WTF\wtf/StdLibExtras.h(461): error C2039: 'tie': is not a member of 'std' C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.12.25827\include\memory(17): note: see declaration of 'std' C:\WebKit-EWS\WebKit\Source\WTF\wtf/StdLibExtras.h(461): error C2873: 'tie': symbol cannot be used in a using-declaration [176/1795] Building CXX object Source\ThirdParty\ANGLE\CMakeFiles\libANGLE.dir\src\libANGLE\TransformFeedback.cpp.obj Created attachment 329190 [details]
Patch
Attachment 329190 [details] did not pass style-queue:
ERROR: Source/WTF/wtf/StdLibExtras.h:452: This { should be at the end of the previous line [whitespace/braces] [4]
ERROR: Source/WebCore/ChangeLog:8: You should remove the 'No new tests' and either add and list tests, or explain why no new tests were possible. [changelog/nonewtests] [5]
Total errors found: 2 in 4 files
If any of these errors are false positives, please file a bug against check-webkit-style.
Comment on attachment 329190 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=329190&action=review > Source/WTF/wtf/StdLibExtras.h:449 > +// GCC5 does not have constexpr std::tie. Since we cannot redefine std::tie with constexpr, we define WTF::tie instead. > +// https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65978 This is a bug on libstdc++ (not on GCC itself). So even if you build with Clang you will hit this problem if your Linux distribution ships a libstdc++ < 6 Created attachment 329208 [details]
Patch
Created attachment 329209 [details]
Patch
Attachment 329209 [details] did not pass style-queue:
ERROR: Source/WTF/wtf/StdLibExtras.h:452: This { should be at the end of the previous line [whitespace/braces] [4]
ERROR: Source/WebCore/ChangeLog:8: You should remove the 'No new tests' and either add and list tests, or explain why no new tests were possible. [changelog/nonewtests] [5]
Total errors found: 2 in 4 files
If any of these errors are false positives, please file a bug against check-webkit-style.
Comment on attachment 329209 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=329209&action=review Thanks! > Source/WebCore/ChangeLog:8 > + No new tests (OOPS!). Remove this line please, I think cq will reject the patch with this line in the changelog. Comment on attachment 329209 [details]
Patch
If we expect to keep WebKit compatible with the bugs in these older versions of GCC, I think we need to add an EWS instance for them. Otherwise, I, at least, will keep getting things like this wrong.
Comment on attachment 329209 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=329209&action=review Yeah, we should have EWS + GCC5.4, which is the lower bound of our supported compiler. >> Source/WebCore/ChangeLog:8 >> + No new tests (OOPS!). > > Remove this line please, I think cq will reject the patch with this line in the changelog. Oops, thanks! Committed r225896: <https://trac.webkit.org/changeset/225896> For the record, in r226299 <https://trac.webkit.org/changeset/226299> I updated the comment on wtf/StdLibExtras.h to note that this workaround of using WTF::tie for constexpr result can be removed after 2019-04 (one year after Ubuntu 18.04 LTS is released) according to https://trac.webkit.org/wiki/WebKitGTK/DependenciesPolicy |