cryptol-3.0.0: Cryptol: The Language of Cryptography

Copyright | (c) 2013-2016 Galois Inc.
License | BSD3
Maintainer | cryptol@galois.com
Stability | provisional
Portability | portable
Safe Haskell | Safe
Language | Haskell2010

Cryptol.TypeCheck.TypeMap

Description

# Documentation

data TypeMap a Source #

Constructors

TM |

Fields

- tvar :: Map TVar a
- tcon :: Map TCon (List TypeMap a)
- trec :: Map [Ident] (List TypeMap a)
- tnewtype :: Map Newtype (List TypeMap a)

#### Instances

Instances details

Foldable TypeMap Source # |

Instance details

Defined in Cryptol.TypeCheck.TypeMap

Methods

fold :: Monoid m => TypeMap m -> m Source #

foldMap :: Monoid m => (a -> m) -> TypeMap a -> m Source #

foldMap' :: Monoid m => (a -> m) -> TypeMap a -> m Source #

foldr :: (a -> b -> b) -> b -> TypeMap a -> b Source #

foldr' :: (a -> b -> b) -> b -> TypeMap a -> b Source #

foldl :: (b -> a -> b) -> b -> TypeMap a -> b Source #

foldl' :: (b -> a -> b) -> b -> TypeMap a -> b Source #

foldr1 :: (a -> a -> a) -> TypeMap a -> a Source #

foldl1 :: (a -> a -> a) -> TypeMap a -> a Source #

toList :: TypeMap a -> [a] Source #

null :: TypeMap a -> Bool Source #

length :: TypeMap a -> Int Source #

elem :: Eq a => a -> TypeMap a -> Bool Source #

maximum :: Ord a => TypeMap a -> a Source #

minimum :: Ord a => TypeMap a -> a Source #

sum :: Num a => TypeMap a -> a Source #

product :: Num a => TypeMap a -> a Source #

Traversable TypeMap Source # |
Instance details Defined in Cryptol.TypeCheck.TypeMap Methods traverse :: Applicative f => (a -> f b) -> TypeMap a -> f (TypeMap b) Source # sequenceA :: Applicative f => TypeMap (f a) -> f (TypeMap a) Source # mapM :: Monad m => (a -> m b) -> TypeMap a -> m (TypeMap b) Source # sequence :: Monad m => TypeMap (m a) -> m (TypeMap a) Source #
Functor TypeMap Source # |
Instance details Defined in Cryptol.TypeCheck.TypeMap Methods fmap :: (a -> b) -> TypeMap a -> TypeMap b Source # (<$) :: a -> TypeMap b -> TypeMap a Source #
TrieMap TypeMap Type Source # |

Instance details

Defined in Cryptol.TypeCheck.TypeMap

Methods

emptyTM :: TypeMap a Source #

nullTM :: TypeMap a -> Bool Source #

lookupTM :: Type -> TypeMap a -> Maybe a Source #

alterTM :: Type -> (Maybe a -> Maybe a) -> TypeMap a -> TypeMap a Source #

unionTM :: (a -> a -> a) -> TypeMap a -> TypeMap a -> TypeMap a Source #

toListTM :: TypeMap a -> [(Type, a)] Source #

mapMaybeWithKeyTM :: (Type -> a -> Maybe b) -> TypeMap a -> TypeMap b Source #

Show a => Show (TypeMap a) Source # |
Instance details Defined in Cryptol.TypeCheck.TypeMap Methods showsPrec :: Int -> TypeMap a -> ShowS Source # show :: TypeMap a -> String Source # showList :: [TypeMap a] -> ShowS Source #
TVars a => TVars (TypeMap a) Source # |
Instance details Defined in Cryptol.TypeCheck.Subst Methods apSubst :: Subst -> TypeMap a -> TypeMap a Source #

type TypesMap = List TypeMap Source #

class TrieMap m k | m -> k where Source #

Methods

emptyTM :: m a Source #

nullTM :: m a -> Bool Source #

lookupTM :: k -> m a -> Maybe a Source #

alterTM :: k -> (Maybe a -> Maybe a) -> m a -> m a Source #

unionTM :: (a -> a -> a) -> m a -> m a -> m a Source #

toListTM :: m a -> [(k, a)] Source #

mapMaybeWithKeyTM :: (k -> a -> Maybe b) -> m a -> m b Source #

#### Instances

Instances details

TrieMap TypeMap Type Source # |

Instance details

Defined in Cryptol.TypeCheck.TypeMap

Methods

emptyTM :: TypeMap a Source #

nullTM :: TypeMap a -> Bool Source #

lookupTM :: Type -> TypeMap a -> Maybe a Source #

alterTM :: Type -> (Maybe a -> Maybe a) -> TypeMap a -> TypeMap a Source #

unionTM :: (a -> a -> a) -> TypeMap a -> TypeMap a -> TypeMap a Source #

toListTM :: TypeMap a -> [(Type, a)] Source #

mapMaybeWithKeyTM :: (Type -> a -> Maybe b) -> TypeMap a -> TypeMap b Source #

Ord a => TrieMap (Map a) a Source # |

Instance details

Defined in Cryptol.TypeCheck.TypeMap

Methods

emptyTM :: Map a a0 Source #

nullTM :: Map a a0 -> Bool Source #

lookupTM :: a -> Map a a0 -> Maybe a0 Source #

alterTM :: a -> (Maybe a0 -> Maybe a0) -> Map a a0 -> Map a a0 Source #

unionTM :: (a0 -> a0 -> a0) -> Map a a0 -> Map a a0 -> Map a a0 Source #

toListTM :: Map a a0 -> [(a, a0)] Source #

mapMaybeWithKeyTM :: (a -> a0 -> Maybe b) -> Map a a0 -> Map a b Source #

TrieMap m a => TrieMap (List m) [a] Source # |

Instance details

Defined in Cryptol.TypeCheck.TypeMap

Methods

emptyTM :: List m a0 Source #

nullTM :: List m a0 -> Bool Source #

lookupTM :: [a] -> List m a0 -> Maybe a0 Source #

alterTM :: [a] -> (Maybe a0 -> Maybe a0) -> List m a0 -> List m a0 Source #

unionTM :: (a0 -> a0 -> a0) -> List m a0 -> List m a0 -> List m a0 Source #

toListTM :: List m a0 -> [([a], a0)] Source #

mapMaybeWithKeyTM :: ([a] -> a0 -> Maybe b) -> List m a0 -> List m b Source #

insertTM :: TrieMap m k => k -> a -> m a -> m a Source #

insertWithTM :: TrieMap m k => (a -> a -> a) -> k -> a -> m a -> m a Source #

membersTM :: TrieMap m k => m a -> [a] Source #

mapTM :: TrieMap m k => (a -> b) -> m a -> m b Source #

mapWithKeyTM :: TrieMap m k => (k -> a -> b) -> m a -> m b Source #

mapMaybeTM :: TrieMap m k => (a -> Maybe b) -> m a -> m b Source #

data List m a Source #

Constructors

L |

Fields

- nil :: Maybe a
- cons :: m (List m a)

#### Instances

Instances details

Foldable m => Foldable (List m) Source # |

Instance details

Defined in Cryptol.TypeCheck.TypeMap

Methods

fold :: Monoid m0 => List m m0 -> m0 Source #

foldMap :: Monoid m0 => (a -> m0) -> List m a -> m0 Source #

foldMap' :: Monoid m0 => (a -> m0) -> List m a -> m0 Source #

foldr :: (a -> b -> b) -> b -> List m a -> b Source #

foldr' :: (a -> b -> b) -> b -> List m a -> b Source #

foldl :: (b -> a -> b) -> b -> List m a -> b Source #

foldl' :: (b -> a -> b) -> b -> List m a -> b Source #

foldr1 :: (a -> a -> a) -> List m a -> a Source #

foldl1 :: (a -> a -> a) -> List m a -> a Source #

toList :: List m a -> [a] Source #

null :: List m a -> Bool Source #

length :: List m a -> Int Source #

elem :: Eq a => a -> List m a -> Bool Source #

maximum :: Ord a => List m a -> a Source #

minimum :: Ord a => List m a -> a Source #

sum :: Num a => List m a -> a Source #

product :: Num a => List m a -> a Source #

Traversable m => Traversable (List m) Source # |
Instance details Defined in Cryptol.TypeCheck.TypeMap Methods traverse :: Applicative f => (a -> f b) -> List m a -> f (List m b) Source # sequenceA :: Applicative f => List m (f a) -> f (List m a) Source # mapM :: Monad m0 => (a -> m0 b) -> List m a -> m0 (List m b) Source # sequence :: Monad m0 => List m (m0 a) -> m0 (List m a) Source #
Functor m => Functor (List m) Source # |
Instance details Defined in Cryptol.TypeCheck.TypeMap Methods fmap :: (a -> b) -> List m a -> List m b Source # (<$) :: a -> List m b -> List m a Source #
TrieMap m a => TrieMap (List m) [a] Source # |

Instance details

Defined in Cryptol.TypeCheck.TypeMap

Methods

emptyTM :: List m a0 Source #

nullTM :: List m a0 -> Bool Source #

lookupTM :: [a] -> List m a0 -> Maybe a0 Source #

alterTM :: [a] -> (Maybe a0 -> Maybe a0) -> List m a0 -> List m a0 Source #

unionTM :: (a0 -> a0 -> a0) -> List m a0 -> List m a0 -> List m a0 Source #

toListTM :: List m a0 -> [([a], a0)] Source #

mapMaybeWithKeyTM :: ([a] -> a0 -> Maybe b) -> List m a0 -> List m b Source #

(Traversable m, TVars a) => TVars (List m a) Source # |
Instance details Defined in Cryptol.TypeCheck.Subst Methods apSubst :: Subst -> List m a -> List m a Source #