Nested function calls in Fortran?

Yes, *8 is non standard, although a classical extension. REAL(8) or REAL(kind=8) is standard, but read that post for still better solutions: