This is the mail archive of the fortran@gcc.gnu.org mailing list for the GNU Fortran project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: ARGH. Who wrote intrinsic_set_exponent.f90?


I am curious.  Would this be legal, aka standard conforming?

subroutine test_real4()
  real x,y
  integer i,n
  equivalence(x,i)
  x = 1.0   ! <-- Set this to some dummy value so that x is defined.
  n = 128
  i = o'00037777777' ! <-- This doesn't do what you think.
  y = set_exponent (x, n) ! <-- This is nonconforming.
  if (exponent (y) .ne. n) call abort()
end subroutine 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]