Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C++ > What's the meaning of this warning: this decimal constant is unsignedonly in ISO C90

Reply
Thread Tools

What's the meaning of this warning: this decimal constant is unsignedonly in ISO C90

 
 
Nan Li
Guest
Posts: n/a
 
      12-13-2008
Hello,

Can any one help me understand the meaning of this warning: this
decimal constant is unsigned only in ISO C90 ? I think -2147483648 is
the min number for 32 bit signed integer.

#include <stdint.h>

static const int32_t value = -2147483648;

warning: this decimal constant is unsigned only in ISO C90

gcc version 4.0.2 20051125


Thanks !
 
Reply With Quote
 
 
 
 
Juha Nieminen
Guest
Posts: n/a
 
      12-14-2008
Jack Klein wrote:
> It would be much better to use the macro INT32_MIN, from <stdint.h>,
> in the initialization.


For what it's worth, at least here INT32_MIN is defined as:
(-2147483647-1)

The reason is probably what you explained.
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Understanding search queries, semantics, and "Meaning" ...aren't weall looking for meaning? 5lvqbwl02@sneakemail.com Python 4 01-14-2009 02:28 PM
TypeError: unsupported operand type(s) for -: 'Decimal' and 'Decimal'. Why? Gilbert Fine Python 8 08-01-2007 01:58 AM
Decimal to Packed Decimal Conversion in C++ Ven C++ 3 08-01-2006 03:56 PM
=?ISO-8859-1?Q?What_new_relating_frames_exists_in_AS?==?ISO-8859-1?Q?P=2ENET_what_doesn=27t_exist_in_old_ASP=3F_?==?ISO-8859-1?Q?And_changing_another_frame=B4s_controls?= qwerty ASP .Net 3 09-29-2004 04:46 PM
=?iso-8859-1?Q?=22With_that_being_said=2C_its_time_to_turn_off_the_stov?==?iso-8859-1?Q?e=2C_so_if_you_can't_stand_the_heat_get_out_of_the_kitch?==?iso-8859-1?Q?en!=22?= =?iso-8859-1?Q?Frisbee=AE_MCNGP?= MCSE 32 01-13-2004 07:11 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57