Re: integer overflow
- From: robert.corbett@xxxxxxx
- Date: 21 Sep 2006 18:05:22 -0700
glen herrmannsfeldt wrote:
I don't think so. I would say that any such rearrangements
are done only after the operations have the right type.
Another way to say it is that in that case they aren't
mathematically equivalent anymore.
Your interpretation is, I am sorry to say, incorrect.
Section 7.1.8.3 of the Fortran 2003 standard states
Each operand in a numeric intrinsic operation
has a type that may depend on the order of
evaluation used by the processor.
The note following that statement states
NOTE 7.20
For example, the evaluation of the expression
Z + R + I
where Z, R, and I represent objects of complex, real,
and integer type, respectively, the type of the operand
that is added to I may be either complex or real,
depending on which pair of operands (Z and R, R and
I, or Z and I) is added first.
Bob Corbett
.
- Follow-Ups:
- Re: integer overflow
- From: glen herrmannsfeldt
- Re: integer overflow
- References:
- integer overflow
- From: Gene Wagenbreth
- Re: integer overflow
- From: Richard E Maine
- Re: integer overflow
- From: Gene Wagenbreth
- Re: integer overflow
- From: Richard E Maine
- Re: integer overflow
- From: *** Hendrickson
- Re: integer overflow
- From: glen herrmannsfeldt
- integer overflow
- Prev by Date: Re: operation on module arguments
- Next by Date: Re: integer overflow
- Previous by thread: Re: integer overflow
- Next by thread: Re: integer overflow
- Index(es):