https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117805

anlauf at gcc dot gnu.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |anlauf at gcc dot gnu.org

--- Comment #12 from anlauf at gcc dot gnu.org ---
(In reply to kargls from comment #11)
> This is not processor-dependent behavior.  gfortran implements
> real*complex in accordance with the words of the Fortran standard.
> 
>     10.1.5.2.1 Interpretation of numeric intrinsic operations
> 
>     The two operands of numeric intrinsic binary operations may
>     be of different numeric types or different kind type parameters.
>     Except for a value of type real or complex raised to an integer
>     power, if the operands have different types or kind type parameters,
>     the effect is as if each operand that differs in type or kind type
>     parameter from those of the result is converted to the type and
>     kind type parameter of the result before the operation is performed.
> 
> If 'r' is of type REAL and 'z' is of type COMPLEX, the Fortran standard
> is clear that the interpretation is
> 
>     <result is complex> = r * z
>                         = (r, 0.) * z

Is that really clear from the standard?

In your quote I read "the effect is as if ... converted ...".

With IEEE arithmetic available, it seems to be not clear to me if the
imaginary part has to be +0.; couldn't its sign depend on the sign of
the real part?  Would that be a non-conforming implementation?

Reading the quoted text, I feel that the committee intentionally ignored the
the present issue.

Reply via email to