Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

specify real kind via preprocessor directive #34

Merged
merged 2 commits into from
Mar 6, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
specify real kind via preprocessor directive
jacobwilliams committed Mar 6, 2024
commit d6d05e435f3ffed5e0c0807d931bf9160d4af25c
25 changes: 25 additions & 0 deletions src/kind_module.F90
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
!*****************************************************************************************
!> author: Jacob Williams
!
! Define the numeric kinds.

module kind_module

use, intrinsic :: iso_fortran_env, only: real32,real64,real128

implicit none

private

#ifdef REAL32
integer,parameter,public :: wp = real32 !! real kind used by this module [4 bytes]
#elif REAL64
integer,parameter,public :: wp = real64 !! real kind used by this module [8 bytes]
#elif REAL128
integer,parameter,public :: wp = real128 !! real kind used by this module [16 bytes]
#else
integer,parameter,public :: wp = real64 !! real kind used by this module [8 bytes]
#endif

end module kind_module
!*****************************************************************************************
19 changes: 0 additions & 19 deletions src/kind_module.f90

This file was deleted.