Is it possible to make the accuracy of a variable the variable itself, which will be determined at run time? Say, if I try to compile:
SUBROUTINE FOO( VARIABLE, PRECISION_VALUE ) IMPLICIT NONE INTEGER(4) :: PRECISION_VALUE INTEGER(PRECISION_VALUE) :: VARIABLE RETURN END
compiler output:
error
Anyway around? I understand that no arbitrary value can be used for KIND , but this is not my problem in this matter.
fortran precision
Puchatek
source share