Safe Haskell | None |
---|---|
Language | Haskell2010 |
Language.Fortran.Repr.Value.Scalar.Logical.Machine
Description
Machine Fortran LOGICAL values.
Fortran compilers usually store LOGICALs as INTEGERs (they former is tied to the latter in the specifications). To more accurately simulate their behaviour, we represent them directly as integers, and simply provide a handful of definitions for using them as booleans.
Synopsis
- fLogicalToBool :: FInt -> Bool
- fLogicalNumericFromBool :: Num a => Bool -> a
- consumeFLogicalNumeric :: (Num a, Eq a) => r -> r -> a -> r
- fLogicalNot :: FInt -> FInt
Documentation
fLogicalToBool :: FInt -> Bool Source #
Retrieve the boolean value stored by a LOGICAL(x)
.
fLogicalNumericFromBool :: Num a => Bool -> a Source #
Convert a bool to its Fortran machine representation in any numeric type.
consumeFLogicalNumeric :: (Num a, Eq a) => r -> r -> a -> r Source #
Consume some Fortran logical stored using an integer.
fLogicalNot :: FInt -> FInt Source #