| Copyright | (c) 2013-2016 Galois Inc. |
|---|---|
| License | BSD3 |
| Maintainer | cryptol@galois.com |
| Stability | provisional |
| Portability | portable |
| Safe Haskell | Safe-Inferred |
| Language | Haskell2010 |
Cryptol.ModuleSystem.Renamer.Error
Description
Synopsis
- data RenamerError
- = MultipleSyms (Located PName) [Name]
- | UnboundName Namespace (Located PName)
- | OverlappingSyms [Name]
- | WrongNamespace Namespace Namespace (Located PName)
- | FixityError (Located Name) Fixity (Located Name) Fixity
- | OverlappingRecordUpdate (Located [Selector]) (Located [Selector])
- | InvalidDependency [DepName]
- | MultipleModParams Ident [Range]
- | InvalidFunctorImport (ImpName Name)
- | UnexpectedNest Range PName
- | ModuleKindMismatch Range (ImpName Name) ModKind ModKind
- data DepName
- depNameLoc :: DepName -> Maybe Range
- data ModKind
- data RenamerWarning
- = SymbolShadowed PName Name [Name]
- | UnusedName Name
- | PrefixAssocChanged PrefixOp (Expr Name) (Located Name) Fixity (Expr Name)
Documentation
data RenamerError Source #
Constructors
| MultipleSyms (Located PName) [Name] | Multiple imported symbols contain this name |
| UnboundName Namespace (Located PName) | Some name not bound to any definition |
| OverlappingSyms [Name] | An environment has produced multiple overlapping symbols |
| WrongNamespace Namespace Namespace (Located PName) | expected, actual. When a name is missing from the expected namespace, but exists in another |
| FixityError (Located Name) Fixity (Located Name) Fixity | When the fixity of two operators conflict |
| OverlappingRecordUpdate (Located [Selector]) (Located [Selector]) | When record updates overlap (e.g., |
| InvalidDependency [DepName] | Things that can't depend on each other |
| MultipleModParams Ident [Range] | Module parameters with the same name |
| InvalidFunctorImport (ImpName Name) | Can't import functors directly |
| UnexpectedNest Range PName | Nested modules were not supposed to appear here |
| ModuleKindMismatch Range (ImpName Name) ModKind ModKind | Exepcted one kind (first one) but found the other (second one) |
Instances
We use this to name dependencies. In addition to normal names we have a way to refer to module parameters and top-level module constraints, which have no explicit names
Constructors
| NamedThing Name | Something with a name |
| ModPath ModPath | The module at this path |
| ModParamName Range Ident | Note that the range is important not just for error reporting but to distinguish module parameters with the same name (e.g., in nested functors) |
| ConstratintAt Range | Identifed by location in source |
Instances
Constructors
| AFunctor | |
| ASignature | |
| AModule |
Instances
| Generic ModKind Source # | |
| Show ModKind Source # | |
| PP ModKind Source # | |
| NFData ModKind Source # | |
Defined in Cryptol.ModuleSystem.Renamer.Error | |
| Eq ModKind Source # | |
| Ord ModKind Source # | |
Defined in Cryptol.ModuleSystem.Renamer.Error | |
| type Rep ModKind Source # | |
Defined in Cryptol.ModuleSystem.Renamer.Error type Rep ModKind = D1 ('MetaData "ModKind" "Cryptol.ModuleSystem.Renamer.Error" "cryptol-3.3.0-7OIQa8lMv7L2xoAlM9JEI6" 'False) (C1 ('MetaCons "AFunctor" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "ASignature" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "AModule" 'PrefixI 'False) (U1 :: Type -> Type))) | |
data RenamerWarning Source #
Constructors
| SymbolShadowed PName Name [Name] | |
| UnusedName Name | |
| PrefixAssocChanged PrefixOp (Expr Name) (Located Name) Fixity (Expr Name) |