-
Notifications
You must be signed in to change notification settings - Fork 61
Open
Description
When activating warnings, i get
In file included from /home/sebilla/atari/Vanilla-Conquer/redalert/function.h:108,
from /home/sebilla/atari/Vanilla-Conquer/redalert/cell.cpp:79:
In member function ‘int HouseClass::QuantityB(int)’,
inlined from ‘bool CellClass::Goodie_Check(FootClass*)’ at /home/sebilla/atari/Vanilla-Conquer/redalert/cell.cpp:2367:62:
/home/sebilla/atari/Vanilla-Conquer/redalert/house.h:991:33: warning: iteration 84 invokes undefined behavior [-Waggressive-loop-optimizations]
991 | return (BQuantity[index]);
| ^
/home/sebilla/atari/Vanilla-Conquer/redalert/cell.cpp: In member function ‘bool CellClass::Goodie_Check(FootClass*)’:
/home/sebilla/atari/Vanilla-Conquer/redalert/cell.cpp:2366:47: note: within this loop
2366 | for (j = 0; j < STRUCT_COUNT; j++) {
| ~~^~~~~~~~~~~~~~
at
Vanilla-Conquer/redalert/cell.cpp
Line 2366 in ffd4077
| for (j = 0; j < STRUCT_COUNT; j++) { |
This is because that array has different sizes depending on FIXIT_ANTS/FIXIT_CSII being defined. Same may also be true for the other arrays.
Metadata
Metadata
Assignees
Labels
No labels