this is working fine but it does produce a warning:
extern int const SCREEN_WIDTH;
Need I be concerned about doing this? It functions exactly as intended.
The warning I get is:
SCREEN_WIDTH initialized and declared extern
and
extern variable has an initializer
Sounds like where you set the SCREEN_WIDTH
constant's value, you still have the extern
keyword. Something like:
extern int const SCREEN_WIDTH = 1024;
If so, remove the extern
keyword. It should only be present where you declare the constant, not where you define it. :)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With