Fortran and Complex Numbers
Fortran has supported complex numbers since Fortran 66 (1966) and before. Perhaps surprisingly, early standards contained single precision complex only. The first standard to contain double precision complex was Fortran 90, although double precision complex was supported as an extension by almost every Fortran 77 compiler.
This is the easiest page to write, thanks to a comment made in 2024 by J3, the Fortran Standards Committee.
Fortran does not specify the method of rounding, approximating, or computing numeric values except by reference to [IEEE-754]. [IEEE-754] contains no specification of complex arithmetic. [...] The Fortran standard itself contains no specification or requirement on the algorithm used to calculate complex multiplication. [...] As the standard contains no specification or requirement, it thus contains no requirement that the same algorithm be used at all times. [...] It is thus valid for the processor to use a different algorithm for complex multiply when the operation is on an odd-numbered line of the source file, the operation involves a real value promoted to complex, or on alternate Tuesdays.
The particular question was whether when evaluating real times complex, the real had to be promoted to a complex and full complex-complex multiplication performed. My interpretation of the answer is that the Standard makes it clear that the real does have to be promoted to a complex, but that, if the compiler is aware that the imaginary part of a complex number is zero, then it can take short-cuts when multiplying by it. IEEE-754 does not apply to components of a complex number. IEEE-754 is meaningless in the absence of a precise definition of an algorithm, and Fortran does not define an algorithm for complex multiplication. (Historically some Fortran compilers have used the three-multiply five-add version of complex-complex multiplication, for instance.)
So in Fortran the signs of zeros in components of complex numbers cannot be relied upon, nor can anything about the behaviour of complex numbers with NaNs or Infs in their components.
The result is potentially fast, but if one does care about NaNs, Infs and signed zeros, potentially vexing.
However, the GCC Fortran compiler takes a very different approach, albeit one which conforms with the above.