-
-
Notifications
You must be signed in to change notification settings - Fork 31.8k
gh-102654: Insert #line directives in generated_cases.c.h #102669
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
Conversation
This behavior is optional, because in some extreme cases it may just make debugging harder. The tool defaults it to off, but it is on in Makefile.pre.in. Also note that this makes diffs to generated_cases.c.h noisier, since whenever you insert or delete a line in bytecodes.c, all subsequent #line directives will change.
I learn a new thing from this PR. Looks good to me |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changes look fine, in the context of the current design.
Ideally the changes would have been restricted to the formatter, but the current design prevents that.
Notes for future PR:
Passing tokens instead of strings to the Formatter would mean that the rest of the code doesn't need to care about line numbers.
Using tokens mean that we can parse DEOPT_IF
, etc. in a more robust way than using a regex.
…on#102669) This behavior is optional, because in some extreme cases it may just make debugging harder. The tool defaults it to off, but it is on in Makefile.pre.in. Also note that this makes diffs to generated_cases.c.h noisier, since whenever you insert or delete a line in bytecodes.c, all subsequent #line directives will change.
…on#102669) This behavior is optional, because in some extreme cases it may just make debugging harder. The tool defaults it to off, but it is on in Makefile.pre.in. Also note that this makes diffs to generated_cases.c.h noisier, since whenever you insert or delete a line in bytecodes.c, all subsequent #line directives will change.
This behavior is optional, because in some extreme cases it may just make debugging harder. The tool defaults it to off, but it is on in Makefile.pre.in.
Also note that this makes diffs to generated_cases.c.h way noisier, since whenever you insert or delete a line in bytecodes.c, all subsequent #line directives will change.
Honestly I wonder if maybe we should keep it off and tell developers how to turn it on (maybe by environment variable) when they're developing instructions?
#line
directives to generated_cases.c.h #102654