12-27-2023, 04:32 PM
(12-27-2023, 01:35 PM)RhoSigma Wrote: It's implicit sign extension. If the highest bit in the hex variable is set, one should always EXPLICITLY tell the datatype by using type suffixes. The following works...You might be totally right, but it breaks 10 years of QB64 code that always accepted
Code: (Select All)CONST const_blue = &HFF0000FF&&
PRINT const_blue, HEX$(const_blue)
and this too...
Code: (Select All)CONST const_blue = &HFF0000FF~&
PRINT const_blue, HEX$(const_blue)
by the way, 32-bit colors should be unsigned values anyways, it's explicitly mentiond in the wiki in several places regarding image/color usage. Wish people would just once look there befor complaining, its rather sucking to maintain the wiki and knowing nobody use it when needed.
Code: (Select All)
Const BLUE = &hFF0000FF
45y and 2M lines of MBASIC>BASICA>QBASIC>QBX>QB64 experience