SCALE-RM
scale_precision.F90
Go to the documentation of this file.
1 !-------------------------------------------------------------------------------
14  !-----------------------------------------------------------------------------
15  !
16  !++ used modules
17  !
18  use dc_types, only: &
19  dc_sp => sp, &
20  dc_dp => dp
21  !-----------------------------------------------------------------------------
22  implicit none
23  private
24  !-----------------------------------------------------------------------------
25  !
26  !++ Public procedure
27  !
28  !-----------------------------------------------------------------------------
29  !
30  !++ Public parameters & variables
31  !
32  !-----------------------------------------------------------------------------
33  integer, public, parameter :: sp = dc_sp ! Single Precision: kind(0.E0)
34  integer, public, parameter :: dp = dc_dp ! Double Precision: kind(0.D0)
35 
36  integer, public, parameter :: sp_prec = precision(0.e0)
37  integer, public, parameter :: dp_prec = precision(0.d0)
38 
39 #ifdef SINGLE
40  integer, public, parameter :: rp = sp ! single precision
41  integer, public, parameter :: rp_prec = sp_prec
42 #else
43  integer, public, parameter :: rp = dp ! double precision
44  integer, public, parameter :: rp_prec = dp_prec
45 #endif
46 
47  !-----------------------------------------------------------------------------
48  !
49  !++ Private procedure
50  !
51  !-----------------------------------------------------------------------------
52  !
53  !++ Private parameters & variables
54  !
55  !-----------------------------------------------------------------------------
56 end module scale_precision
integer, parameter, public sp_prec
integer, parameter, public dp_prec
integer, parameter, public dp
Definition: dc_types.f90:27
integer, parameter, public rp_prec
integer, parameter, public sp
Definition: dc_types.f90:30
module PRECISION
integer, parameter, public rp