Skip to content

Enable -Wall and "fix" warnings#2474

Merged
fenhl merged 2 commits intoOoTRandomizer:Devfrom
flagrama:Wall
Oct 25, 2025
Merged

Enable -Wall and "fix" warnings#2474
fenhl merged 2 commits intoOoTRandomizer:Devfrom
flagrama:Wall

Conversation

@flagrama
Copy link

@flagrama flagrama commented Oct 5, 2025

I enabled -Wall in CFLAGS and then "fixed" all of the warnings. The code should be functionally the same, but a lot of unused code was removed. Some of this may have been for reference purposes, in which case I can restore it most likely commented out instead of unused.

Also, if this isn't to be merged, code like uint8_t nbOverlays, currentOverlayTabIndex = 0; should probably be disallowed in code style as only the last variable gets the initialized. (thanks C)

Testing

Ensured the game still boots. Shirosoluna helped testing to make sure I didn't make any functional changes to the code related to equip swap.

@GSKirox GSKirox added Component: ASM/C Changes some internals of the ASM/C libraries Status: Needs Review Someone should be looking at it Status: Under Consideration Developers are considering whether to accept or decline the feature described Type: Maintenance Code style, infrastructure, updating dependencies labels Oct 6, 2025
@flagrama
Copy link
Author

flagrama commented Oct 7, 2025

Also, -Wall doesn't actually mean "enable all warnings". There is also -Wextra and -Wpedantic and there might even be some that need to explicitly be enabled when using gcc.

@fenhl fenhl removed the Status: Needs Review Someone should be looking at it label Oct 12, 2025
@cjohnson57 cjohnson57 removed the Status: Under Consideration Developers are considering whether to accept or decline the feature described label Oct 12, 2025
@fenhl fenhl added this to the next milestone Oct 25, 2025
@fenhl fenhl merged commit 4563781 into OoTRandomizer:Dev Oct 25, 2025
6 checks passed
fenhl added a commit to fenhl/OoT-Randomizer that referenced this pull request Nov 21, 2025
fenhl added a commit that referenced this pull request Nov 25, 2025
# Conflicts:
#	ASM/build/asm_symbols.txt
#	ASM/build/bundle.o
#	ASM/build/c_symbols.txt
#	data/generated/patch_symbols.json
#	data/generated/rom_patch.txt
#	data/generated/symbols.json
@fenhl fenhl mentioned this pull request Nov 25, 2025
jdunn596 pushed a commit to jdunn596/OoT-Randomizer that referenced this pull request Nov 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Component: ASM/C Changes some internals of the ASM/C libraries Type: Maintenance Code style, infrastructure, updating dependencies

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants