-
-
Notifications
You must be signed in to change notification settings - Fork 172
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
allow defining local labels for another scope #1159
Conversation
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.
The change seems good, but I agree with Rangi that the #define
should be removed—I'm not sure there'd be value in letting this be toggled, especially at compile time?
Looks good! Thanks for bearing with my comments. Just needs CI to pass. |
Thank you. Every job except checkpatch is passing. Does checkpatch compare only the states of the tree before and after the combined effect of the patches, or does it compare each patch? If the latter, how would I go about rewriting history to get the job to pass? |
In your local repo, rebase this branch to |
fix gbdev#1157 for the following source code ``` section "hSAVE_locals",HRAM func3.hSpam: ds 1 ; no longer produces an error ;.hEggs: ds 1 ; uncomment this to see the new error section "demo",ROM0 func3: ldh a, [.hSpam] ret ``` Remove two errors: - `Not currently in the scope of 'func3'` - `Local label 'func3.hSpam' in main scope` Add one error: - `Relative local label '.hSpam' in main scope` Add a switch to restore previous behavior in `include/asm/symbol.h` ```c ``` update tests of local label definition failure now that local label definition is more lenient, fewer tests should fail begin removing issue number from test Co-authored-by: Rangi <[email protected]> treat ALLOW_LOCAL_LABEL_ANYWHERE as always on - don't gate the new lenient behavior behind a build-time condition - change "Relative local label" to "Unqualified local label" in an error message realign tests of local labels with wrong parent - repurpose test/asm/sym-scope from a test of producing correct errors to a successful test - remove test/asm/local-wrong-parent because it is now a redundant successful test based on suggestions by @Rangi42
d78fc21
to
4e9c4fa
Compare
Rangi42 suggested through Discord to bundle the zlib13 update (gbdev#1163) with this
- add missing "Closet" map name - stpcpy as an example of forward-declaring a member of a local scope - explain that forthcoming RGBDS 0.6.2 (or a master build allowing forward-declaring a member of a local scope) is required <gbdev/rgbds#1159> - explain how to get a master build on Windows until 0.6.2 is ready <gbdev/rgbds-www#49> - update URL of RGBDS - Catskull is out of business <https://catskullelectronics.com/pages/the-end-of-catskull-electronics>
- stpcpy and apustpcpy as examples of forward-declaring a member of a local scope - explain that forthcoming RGBDS 0.6.2 (or a master build allowing forward-declaring a member of a local scope) is required <gbdev/rgbds#1159> - explain how to get a master build on Windows until 0.6.2 is ready <gbdev/rgbds-www#49> - update URL of RGBDS - Catskull is out of business <https://catskullelectronics.com/pages/the-end-of-catskull-electronics>
fix #1157 for the following source code
Remove two errors:
Not currently in the scope of 'func3'
Local label 'func3.hSpam' in main scope
Add one error:
Relative local label '.hSpam' in main scope
Add a switch to restore previous behavior in
include/asm/symbol.h