We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Repro:
from pycparserext.ext_c_parser import GnuCParser repro = """ struct x { void (*(*__attribute__((whatever)) ret_fn_ptr_attr) (void)) (void); }; """ p = GnuCParser() p.parse(repro).show(attrnames=True, nodenames=True)
Expected->Actual:
FileAST: Decl <ext[0]>: name=None, quals=[], storage=[], funcspec=[] Struct <type>: name=x - Decl <decls[0]>: name=ret_fn_ptr_attr, quals=[], storage=[], funcspec=[] - PtrDecl <type>: quals=[] + Decl <decls[0]>: name=ret_fn_ptr_attr, quals=[], storage=[], funcspec=[] FuncDeclExt <type>: ParamList <args>: Typename <params[0]>: name=None, quals=[] TypeDecl <type>: declname=None, quals=[] IdentifierType <type>: names=['void'] PtrDecl <type>: quals=[] FuncDeclExt <type>: ParamList <args>: Typename <params[0]>: name=None, quals=[] TypeDecl <type>: declname=None, quals=[] IdentifierType <type>: names=['void'] TypeDeclExt <type>: declname=ret_fn_ptr_attr, quals=[] IdentifierType <type>: names=['void'] ExprList <attributes>: ExprList <attributes>: - ID <exprs[0]>: name=whatever
Seen in the real world here in the emacs dynamic module interface (ultimately included in emacs_module.h here, via templating).
emacs_module.h
The text was updated successfully, but these errors were encountered:
Thanks for the report! I'm unlikely to have time to dig into this anytime soon, but I'd be happy to look at a patch (ideally with a test).
Sorry, something went wrong.
Will look into it! It's been a while since I've poked at lex and yacc but I might be able to knock something out.
No branches or pull requests
Repro:
Expected->Actual:
Seen in the real world here in the emacs dynamic module interface (ultimately included in
emacs_module.h
here, via templating).The text was updated successfully, but these errors were encountered: