-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
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
designated initializer style #32
Comments
Yeah, that's the syntax I always found myself hard to grasp) Do you plan to work on it? |
I'll give it a try |
Awesome, I meantime, added more tests. With that said, could you please include tests in your next patch? It is easy with dune cram, just take the code you examples and put into
Then run
to accept this output. |
Fixes BinaryAnalysisPlatform#32. * frontc/cabs.ml: Add `DESIGNATED` expression type for struct initialization. * frontc/cparser.mly: Add rules for compounds (struct initialization). A compound contains a list of expressions or designated, but a standard initialization cannot be a designated outside a compound. * frontc/cprint.ml: Print new AST type. * frontc/ctoxml.ml: Print XML for new designated AST type. * ctoxml/test.t/c99-struct-initializers.c: New test. * ctoxml/test.t/run.t: Update expected output for new test.
Fixes BinaryAnalysisPlatform#32. * frontc/cabs.ml: Add `DESIGNATOR` expression type for struct initialization. * frontc/cparser.mly: Add rules for compounds (struct initialization). A compound contains a list of expressions or designated, but a standard initialization cannot be a designated outside a compound. * frontc/cprint.ml: Print new AST type. * frontc/ctoxml.ml: Print XML for new designated AST type. * ctoxml/test.t/c99-struct-initializers.c: New test. * ctoxml/test.t/run.t: Update expected output for new test.
Fixes BinaryAnalysisPlatform#32. * frontc/cabs.ml: Add `DESIGNATED` expression type for struct initialization. * frontc/cparser.mly: Add rules for compounds (struct initialization). A compound contains a list of expressions or designated, but a standard initialization cannot be a designated outside a compound. * frontc/cprint.ml: Print new AST type. * frontc/ctoxml.ml: Print XML for new designated AST type. * ctoxml/test.t/c99-struct-initializers.c: New test. * ctoxml/test.t/run.t: Update expected output for new test.
Fixes #32. * frontc/cabs.ml: Add `DESIGNATED` expression type for struct initialization. * frontc/cparser.mly: Add rules for compounds (struct initialization). A compound contains a list of expressions or designated, but a standard initialization cannot be a designated outside a compound. * frontc/cprint.ml: Print new AST type. * frontc/ctoxml.ml: Print XML for new designated AST type. * ctoxml/test.t/c99-struct-initializers.c: New test. * ctoxml/test.t/run.t: Update expected output for new test. Co-authored-by: Julien Lepiller <julien.lepiller@yale.edu>
Sorry, here's another one :D
fails to parse the initialization of variable p.
designated initializer style is a C99 feature.
The text was updated successfully, but these errors were encountered: