Safe Haskell | None |
---|---|
Language | GHC2021 |
Synopsis
- type Avails = [AvailInfo]
- data AvailInfo
- availsToNameSet :: [AvailInfo] -> NameSet
- availsToNameEnv :: [AvailInfo] -> NameEnv AvailInfo
- availExportsDecl :: AvailInfo -> Bool
- availName :: AvailInfo -> Name
- availNames :: AvailInfo -> [Name]
- availSubordinateNames :: AvailInfo -> [Name]
- stableAvailCmp :: AvailInfo -> AvailInfo -> Ordering
- plusAvail :: AvailInfo -> AvailInfo -> AvailInfo
- trimAvail :: AvailInfo -> Name -> AvailInfo
- filterAvail :: (Name -> Bool) -> AvailInfo -> [AvailInfo] -> [AvailInfo]
- filterAvails :: (Name -> Bool) -> [AvailInfo] -> [AvailInfo]
- nubAvails :: [AvailInfo] -> [AvailInfo]
Documentation
Records what things are "available", i.e. in scope
Avail Name | An ordinary identifier in scope, or a field label without a parent type (see Note [Representing pattern synonym fields in AvailInfo]). |
AvailTC | A type or class in scope The AvailTC Invariant: If the type or class is itself to be in scope, it must be first in this list. Thus, typically: AvailTC Eq [Eq, ==, \/=] |
Instances
NFData AvailInfo Source # | |
Defined in GHC.Types.Avail | |
Binary AvailInfo Source # | |
Outputable AvailInfo Source # | |
Data AvailInfo Source # | |
Defined in GHC.Types.Avail gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> AvailInfo -> c AvailInfo # gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c AvailInfo # toConstr :: AvailInfo -> Constr # dataTypeOf :: AvailInfo -> DataType # dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c AvailInfo) # dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c AvailInfo) # gmapT :: (forall b. Data b => b -> b) -> AvailInfo -> AvailInfo # gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> AvailInfo -> r # gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> AvailInfo -> r # gmapQ :: (forall d. Data d => d -> u) -> AvailInfo -> [u] # gmapQi :: Int -> (forall d. Data d => d -> u) -> AvailInfo -> u # gmapM :: Monad m => (forall d. Data d => d -> m d) -> AvailInfo -> m AvailInfo # gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> AvailInfo -> m AvailInfo # gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> AvailInfo -> m AvailInfo # |
availsToNameSet :: [AvailInfo] -> NameSet Source #
availExportsDecl :: AvailInfo -> Bool Source #
Does this AvailInfo
export the parent decl? This depends on the
invariant that the parent is first if it appears at all.
availName :: AvailInfo -> Name Source #
Just the main name made available, i.e. not the available pieces
of type or class brought into scope by the AvailInfo
availNames :: AvailInfo -> [Name] Source #
Names and fields made available by the availability information.
availSubordinateNames :: AvailInfo -> [Name] Source #
Names and fields made available by the availability information, other than the main decl itself.
filterAvail :: (Name -> Bool) -> AvailInfo -> [AvailInfo] -> [AvailInfo] Source #
filters an AvailInfo
by the given predicate