We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents e6d196d + 1f1835b commit 7c0d750Copy full SHA for 7c0d750
src/cpp/parse.cpp
@@ -856,6 +856,20 @@ bool Parser::rNamespaceSpec(cpp_namespace_spect &namespace_spec)
856
namespace_spec.set_namespace(name);
857
namespace_spec.set_is_inline(is_inline);
858
859
+ // Tolerate constructs such as:
860
+ // inline namespace __cxx11 __attribute__((__abi_tag__ ("cxx11"))) { }
861
+ // which occurs in glibc. Obviously we need to better than just throw attribs
862
+ // away like this in the future.
863
+ if(lex.LookAhead(0)==TOK_GCC_ATTRIBUTE)
864
+ {
865
+ cpp_tokent tk;
866
+ lex.get_token(tk);
867
+
868
+ typet discard;
869
+ if(!rAttribute(discard))
870
+ return false;
871
+ }
872
873
switch(lex.LookAhead(0))
874
{
875
case '{':
0 commit comments