cryptol-3.0.0: Cryptol: The Language of Cryptography

Safe Haskell | Safe-Inferred
Language | Haskell2010

Cryptol.ModuleSystem.Names

Synopsis

- data Names
  - = One Name
  - | Ambig (Set Name)
- namesToList :: Names -> [Name]
- anyOne :: Names -> Name
- namesFromSet :: Set Name -> Names
- unionManyNames :: [Names] -> Maybe Names
- mapNames :: (Name -> Name) -> Names -> Names
- filterNames :: (Name -> Bool) -> Names -> Maybe Names
- travNames :: Applicative f => (Name -> f Name) -> Names -> f Names
- diffNames :: Names -> Names -> Maybe Names

# Documentation

data Names Source #

A non-empty collection of names used by the renamer.

Constructors

One Name |
Ambig (Set Name) | Non-empty

#### Instances

Instances details

Semigroup Names Source # |
Instance details Defined in Cryptol.ModuleSystem.Names Methods (<>) :: Names -> Names -> Names Source # sconcat :: NonEmpty Names -> Names Source # stimes :: Integral b => b -> Names -> Names Source #
Generic Names Source # |
Instance details Defined in Cryptol.ModuleSystem.Names Associated Types type Rep Names :: Type -> Type Source # Methods from :: Names -> Rep Names x Source # to :: Rep Names x -> Names Source #
Show Names Source # |
Instance details Defined in Cryptol.ModuleSystem.Names Methods showsPrec :: Int -> Names -> ShowS Source # show :: Names -> String Source # showList :: [Names] -> ShowS Source #
NFData Names Source # |
Instance details Defined in Cryptol.ModuleSystem.Names Methods rnf :: Names -> () Source #
type Rep Names Source # |

Instance details

Defined in Cryptol.ModuleSystem.Names

type Rep Names = D1 ('MetaData "Names" "Cryptol.ModuleSystem.Names" "cryptol-3.0.0-DBVDUAjB1JeD0WzkHH4ckn" 'False) (C1 ('MetaCons "One" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Name)) :+: C1 ('MetaCons "Ambig" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Set Name))))

namesToList :: Names -> [Name] Source #

anyOne :: Names -> Name Source #

namesFromSet Source #

Arguments

:: Set Name | Non-empty
-> Names |

unionManyNames :: [Names] -> Maybe Names Source #

mapNames :: (Name -> Name) -> Names -> Names Source #

filterNames :: (Name -> Bool) -> Names -> Maybe Names Source #

travNames :: Applicative f => (Name -> f Name) -> Names -> f Names Source #

diffNames :: Names -> Names -> Maybe Names Source #