Re: INT_MIN and compiler diagnostic



In article <1172676891.968236.185190@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>,
bytebro <keith.willis@xxxxxxxxx> wrote:

The thing is, in the OP's code lines 7 and 8, it says:

7 int y = -2147483648;
8 int x = INT_MIN;

which are _completely_ equivalent (INT_MIN is _defined_ as
-2147483648)

According to the OP, on his system INT_MIN is defined as

# define INT_MIN (-INT_MAX - 1)

which produces the same result, but does not involve the literal 2147483648.
This seems to be a common trick; on my Mac it is defined as (-0x7fffffff - 1).

-- Richard
--
"Consideration shall be given to the need for as many as 32 characters
in some alphabets" - X3.4, 1963.
.



Relevant Pages

  • Apple Works on x86 Mac?
    ... Will Apple Works run on a new Mac if I transfer it from an old one? ... "Consideration shall be given to the need for as many as 32 characters ... in some alphabets" - X3.4, ...
    (uk.comp.sys.mac)
  • Re: Those clever people in Redmond.
    ... If you want one that uses a Mac or X window, ... "Consideration shall be given to the need for as many as 32 characters ... in some alphabets" - X3.4, ...
    (uk.misc)
  • Re: Symbol problems in Word 2004 for mac
    ... I see you're using ChrW in that macro. ... I am not sure it will work on the Mac (the results are not guaranteed: ... > Below is a macro to turn the characters from the "Symbol" font into Unicode ...
    (microsoft.public.mac.office.word)
  • Re: Spell checking
    ... It is a new spreadsheet in Office for Mac 2008 I purchased along with my MacBook 3 months ago. ... Are you sure you have applied all the most recent updates to Excel? ... times when XLM would not like a text string that exceeded 255 characters. ...
    (microsoft.public.mac.office.excel)
  • Re: National Language - question on alphabet/sort order
    ... are ok about using the English ASCII sequence for the moment. ... This only works for languages that have alphabets. ... what are universally "alphabetic characters" can therefore lead to these ... Is there a method of incrementing and wrapping non-English alphabets? ...
    (microsoft.public.vc.mfc)