ghc-9.6.3: The GHC API

Safe Haskell | Safe-Inferred
Language | Haskell2010

GHC.Core.UsageEnv

Synopsis

- data Usage
  - = Zero
  - | Bottom
  - | MUsage Mult
- data UsageEnv
- addUE :: UsageEnv -> UsageEnv -> UsageEnv
- addUsage :: Usage -> Usage -> Usage
- bottomUE :: UsageEnv
- deleteUE :: NamedThing n => UsageEnv -> n -> UsageEnv
- lookupUE :: NamedThing n => UsageEnv -> n -> Usage
- scaleUE :: Mult -> UsageEnv -> UsageEnv
- scaleUsage :: Mult -> Usage -> Usage
- supUE :: UsageEnv -> UsageEnv -> UsageEnv
- supUEs :: [UsageEnv] -> UsageEnv
- unitUE :: NamedThing n => n -> Mult -> UsageEnv
- zeroUE :: UsageEnv

# Documentation

data Usage Source #

Constructors

Zero |
Bottom |
MUsage Mult |

#### Instances

Instances details

Outputable Usage Source # |
Instance details Defined in GHC.Core.UsageEnv Methods ppr :: Usage -> SDoc Source #

data UsageEnv Source #

#### Instances

Instances details

Outputable UsageEnv Source # |
Instance details Defined in GHC.Core.UsageEnv Methods ppr :: UsageEnv -> SDoc Source #

addUE :: UsageEnv -> UsageEnv -> UsageEnv Source #

addUsage :: Usage -> Usage -> Usage Source #

bottomUE :: UsageEnv Source #

deleteUE :: NamedThing n => UsageEnv -> n -> UsageEnv Source #

lookupUE :: NamedThing n => UsageEnv -> n -> Usage Source #

|lookupUE x env| returns the multiplicity assigned to |x| in |env|, if |x| is not bound in |env|, then returns |Zero| or |Bottom|.

scaleUE :: Mult -> UsageEnv -> UsageEnv Source #

scaleUsage :: Mult -> Usage -> Usage Source #

supUE :: UsageEnv -> UsageEnv -> UsageEnv Source #

supUEs :: [UsageEnv] -> UsageEnv Source #

unitUE :: NamedThing n => n -> Mult -> UsageEnv Source #

zeroUE :: UsageEnv Source #