My favorites | Sign in
Project Home Wiki Issues Source
READ-ONLY: This project has been archived. For more information see this post.
Search
for
  Advanced search   Search tips   Subscriptions
Issue 231: this decimal constant is unsigned only in ISO C90
1 person starred this issue and may be notified of changes. Back to list
Status:  Done
Owner:  ----
Closed:  Apr 2013


 
Reported by michaelbaczynski@gmail.com, Mar 2, 2013
Compiling the value -2147483648 (0x80000000) outputs "warning: this decimal constant is unsigned only in ISO C90" when compiling to android. Is this a problem or can it be ignored?




Mar 2, 2013
#1 drem...@gmail.com
Almost certainly related to this: http://stackoverflow.com/questions/14695118/2147483648-0-returns-true-in-c/14695202#14695202

Basically, the value -2147483648 is actually (-(2147483648)). Since 2147483648 > INT_MAX, the behavior is undefined, but it sounds like there is a possibility it will simply convert to unsigned before negating.
Mar 3, 2013
#2 michaelbaczynski@gmail.com
thanks. I'm defining INT_MIN as -0x7fffffff now for cpp now to be on the safe side..
Apr 12, 2013
Project Member #3 si...@haxe.org
(No comment was entered for this change.)
Status: Done

Powered by Google Project Hosting