Summary: | [WTF] Debug build fails due conflicting abort() method | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Adrian Perez <aperez> | ||||||
Component: | Web Template Framework | Assignee: | Adrian Perez <aperez> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Normal | CC: | ap, benjamin, cdumez, cmarcelo, commit-queue, dbates, ews-watchlist, mcatanzaro, thorton, webkit-bug-importer | ||||||
Priority: | P2 | Keywords: | InRadar | ||||||
Version: | Other | ||||||||
Hardware: | Unspecified | ||||||||
OS: | Unspecified | ||||||||
Attachments: |
|
Description
Adrian Perez
2018-12-07 02:05:18 PST
Created attachment 356789 [details]
Patch
Comment on attachment 356789 [details]
Patch
I wonder why none of the bots noticed this. Or why it doesn't affect me locally. I've done many debug builds.
This was good thinking, but unfortunately this is one of a very few headers that get included in C (and Objective C) so we can't use namespaces here. E.g. from EWS:
/home/buildbot/ews/WebKit/Source/JavaScriptCore/API/tests/testapi.c: In function ‘createStringWithContentsOfFile’:
DerivedSources/ForwardingHeaders/wtf/Assertions.h:244:21: error: expected expression before ‘:’ token
#define CRASH() std::abort()
^
I was going to suggest renaming XMLHttpRequest::abort instead, but there are more abort()s in the codebase... NetworkResourceLoader.cpp, testbmalloc.cpp....
We could add a new conditional to check #if __cplusplus? But that would be messier.
(In reply to Michael Catanzaro from comment #2) > Comment on attachment 356789 [details] > Patch > > I wonder why none of the bots noticed this. Or why it doesn't affect me > locally. I've done many debug builds. > > This was good thinking, but unfortunately this is one of a very few headers > that get included in C (and Objective C) so we can't use namespaces here. > E.g. from EWS: > > /home/buildbot/ews/WebKit/Source/JavaScriptCore/API/tests/testapi.c: In > function ‘createStringWithContentsOfFile’: > DerivedSources/ForwardingHeaders/wtf/Assertions.h:244:21: error: expected > expression before ‘:’ token > #define CRASH() std::abort() > ^ > > I was going to suggest renaming XMLHttpRequest::abort instead, but there are > more abort()s in the codebase... NetworkResourceLoader.cpp, > testbmalloc.cpp.... > > We could add a new conditional to check #if __cplusplus? But that would be > messier. I think checking for __cplusplus is reasonable, I'll update the patch. Created attachment 356878 [details]
Patch
Comment on attachment 356878 [details]
Patch
:/
Comment on attachment 356878 [details] Patch Clearing flags on attachment: 356878 Committed r239012: <https://trac.webkit.org/changeset/239012> All reviewed patches have been landed. Closing bug. |