-
Notifications
You must be signed in to change notification settings - Fork 15.4k
Insert headers in global module fragment #151624
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
Changes from 2 commits
f7e79ed
973ace6
e044938
dc275e9
908392a
e56d504
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I like the test cases you wrote. I do think we should add at least one extra where we already had some includes in the source code. Such that we know this works in such case as well. (I don't expect failure based on your code)
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks for the explanation here! Should I combine all into the same test case, or are 3 separate ones okay? I just realized the other tests seem to combine multiple checks into one gtest test. Edit: Ah, it seems I was mistaken, kept them as 3 separate tests. Let me know if the naming looks okay! |
Uh oh!
There was an error while loading. Please reload this page.
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.
Technically, this function is no longer doing what its name says,
getOffsetAfterHeaderGuardsAndComments.Can we rename it to
getMinHeaderInsertionOffset, and adjust the comment above it to talk about the module declaration as well?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.
Thanks, done!
Does the comment look okay?
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.
If rather say something like:
Feel free to rephrase or ignore
Uh oh!
There was an error while loading. Please reload this page.
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.
This does read better, yeah. Will push after current CI run to prevent a restart.
Edit: done