fortran-src-0.15.1: Parsers and analyses for Fortran standards 66, 77, 90, 95 and 2003 (partial).
Safe HaskellSafe-Inferred
LanguageHaskell2010

Language.Fortran.Repr.Value.Scalar.String

Description

Fortran CHAR value representation.

Currently only CHARs of known length.

Synopsis

Documentation

data FString (l :: NaturalK) Source #

Constructors

KnownNat l => FString Text 

Instances

Instances details
KnownNat l => Data (FString l) Source # 
Instance details

Defined in Language.Fortran.Repr.Value.Scalar.String

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> FString l -> c (FString l) #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (FString l) #

toConstr :: FString l -> Constr #

dataTypeOf :: FString l -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c (FString l)) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (FString l)) #

gmapT :: (forall b. Data b => b -> b) -> FString l -> FString l #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> FString l -> r #

gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> FString l -> r #

gmapQ :: (forall d. Data d => d -> u) -> FString l -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> FString l -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> FString l -> m (FString l) #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> FString l -> m (FString l) #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> FString l -> m (FString l) #

Show (FString l) Source # 
Instance details

Defined in Language.Fortran.Repr.Value.Scalar.String

Methods

showsPrec :: Int -> FString l -> ShowS #

show :: FString l -> String #

showList :: [FString l] -> ShowS #

KnownNat l => Binary (FString l) Source #

This is a painful instance to define. We cheat by leveraging the instance of the length-hiding type SomeFString, then asserting length. It's CPU and memory inefficient and has backwards dependencies, but is comfortably safe.

Instance details

Defined in Language.Fortran.Repr.Value.Scalar.String

Methods

put :: FString l -> Put #

get :: Get (FString l) #

putList :: [FString l] -> Put #

Eq (FString l) Source # 
Instance details

Defined in Language.Fortran.Repr.Value.Scalar.String

Methods

(==) :: FString l -> FString l -> Bool #

(/=) :: FString l -> FString l -> Bool #

Ord (FString l) Source # 
Instance details

Defined in Language.Fortran.Repr.Value.Scalar.String

Methods

compare :: FString l -> FString l -> Ordering #

(<) :: FString l -> FString l -> Bool #

(<=) :: FString l -> FString l -> Bool #

(>) :: FString l -> FString l -> Bool #

(>=) :: FString l -> FString l -> Bool #

max :: FString l -> FString l -> FString l #

min :: FString l -> FString l -> FString l #

fString :: forall l. KnownNat l => Text -> Maybe (FString l) Source #

Attempt to a Text into an FString of the given length.

fStringLen :: forall l. KnownNat l => FString l -> Natural Source #

data SomeFString Source #

Constructors

forall (l :: NaturalK).KnownNat l => SomeFString (FString l) 

Instances

Instances details
Out SomeFString Source # 
Instance details

Defined in Language.Fortran.Repr.Value.Scalar.String

Data SomeFString Source # 
Instance details

Defined in Language.Fortran.Repr.Value.Scalar.String

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> SomeFString -> c SomeFString #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c SomeFString #

toConstr :: SomeFString -> Constr #

dataTypeOf :: SomeFString -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c SomeFString) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c SomeFString) #

gmapT :: (forall b. Data b => b -> b) -> SomeFString -> SomeFString #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> SomeFString -> r #

gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> SomeFString -> r #

gmapQ :: (forall d. Data d => d -> u) -> SomeFString -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> SomeFString -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> SomeFString -> m SomeFString #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> SomeFString -> m SomeFString #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> SomeFString -> m SomeFString #

Show SomeFString Source # 
Instance details

Defined in Language.Fortran.Repr.Value.Scalar.String

Binary SomeFString Source # 
Instance details

Defined in Language.Fortran.Repr.Value.Scalar.String

Eq SomeFString Source # 
Instance details

Defined in Language.Fortran.Repr.Value.Scalar.String

concatFString :: forall ll lr. (KnownNat ll, KnownNat lr) => FString ll -> FString lr -> FString (ll + lr) Source #

fStringBOp :: (Text -> Text -> r) -> FString ll -> FString lr -> r Source #