c++ - Does -A90 switch supposed to work?
- Andrey (8/8) Aug 08 2008 It seems that dmc.exe uses C99 rules for default type of a decimal
- Walter Bright (2/12) Aug 15 2008 Sorry, -A90 is incompletely supported at best.
It seems that dmc.exe uses C99 rules for default type of a decimal literal, even if -A90 option is used. The assert(-1 == 4294967295); fails regardless of -A option, although it should pass on C90 compilers (assuming 32-bit long). The reason of different behavior is that C90 takes RHS as uint32, while C99 assume it int64. Besides, probably -A90 allows another C99 features (like initial declaration in a 'for' loop), so I wonder, does -A90 is supported?
Aug 08 2008
Andrey wrote:It seems that dmc.exe uses C99 rules for default type of a decimal literal, even if -A90 option is used. The assert(-1 == 4294967295); fails regardless of -A option, although it should pass on C90 compilers (assuming 32-bit long). The reason of different behavior is that C90 takes RHS as uint32, while C99 assume it int64. Besides, probably -A90 allows another C99 features (like initial declaration in a 'for' loop), so I wonder, does -A90 is supported?Sorry, -A90 is incompletely supported at best.
Aug 15 2008