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-Inferred
Language | Haskell2010

Cryptol.ModuleSystem

Contents

- Module System
- Interfaces
- Dependencies

Description

Synopsis

- data ModuleEnv = ModuleEnv {
  - meLoadedModules :: LoadedModules
  - meNameSeeds :: NameSeeds
  - meEvalEnv :: EvalEnv
  - meCoreLint :: CoreLint
  - meMonoBinds :: !Bool
  - meFocusedModule :: Maybe ModName
  - meSearchPath :: [FilePath]
  - meDynEnv :: DynamicEnv
  - meSupply :: !Supply
  }
- initialModuleEnv :: IO ModuleEnv
- data DynamicEnv = DEnv {
  - deNames :: NamingEnv
  - deDecls :: [DeclGroup]
  - deTySyns :: Map Name TySyn
  - deEnv :: EvalEnv
  }
- data ModuleError
  - = ModuleNotFound ModName [FilePath]
  - | CantFindFile FilePath
  - | BadUtf8 ModulePath UnicodeException
  - | OtherIOError FilePath IOException
  - | ModuleParseError ModulePath ParseError
  - | RecursiveModules [ImportSource]
  - | RenamerErrors ImportSource [RenamerError]
  - | NoPatErrors ImportSource [Error]
  - | ExpandPropGuardsError ImportSource Error
  - | NoIncludeErrors ImportSource [IncludeError]
  - | TypeCheckingFailed ImportSource NameMap [(Range, Error)]
  - | OtherFailure String
  - | ModuleNameMismatch ModName (Located ModName)
  - | DuplicateModuleName ModName FilePath FilePath
  - | FFILoadErrors ModName [FFILoadError]
  - | ErrorInFile ModulePath ModuleError
- data ModuleWarning
  - = TypeCheckWarnings NameMap [(Range, Warning)]
  - | RenamerWarnings [RenamerWarning]
- type ModuleCmd a = ModuleInput IO -> IO (ModuleRes a)
- type ModuleRes a = (Either ModuleError (a, ModuleEnv), [ModuleWarning])
- data ModuleInput m = ModuleInput {
  - minpCallStacks :: Bool
  - minpEvalOpts :: m EvalOpts
  - minpByteReader :: FilePath -> m ByteString
  - minpModuleEnv :: ModuleEnv
  - minpTCSolver :: Solver
  }
- findModule :: ModName -> ModuleCmd ModulePath
- loadModuleByPath :: FilePath -> ModuleCmd (ModulePath, TCTopEntity)
- loadModuleByName :: ModName -> ModuleCmd (ModulePath, TCTopEntity)
- checkModuleByPath :: FilePath -> ModuleCmd (ModulePath, TCTopEntity)
- checkExpr :: Expr PName -> ModuleCmd (Expr Name, Expr, Schema)
- evalExpr :: Expr -> ModuleCmd Value
- benchmarkExpr :: Double -> Expr -> ModuleCmd BenchmarkStats
- checkDecls :: [TopDecl PName] -> ModuleCmd (NamingEnv, [DeclGroup], Map Name TySyn)
- evalDecls :: [DeclGroup] -> ModuleCmd ()
- noPat :: RemovePatterns a => a -> ModuleCmd a
- focusedEnv :: ModuleEnv -> ModContext
- getPrimMap :: ModuleCmd PrimMap
- renameVar :: NamingEnv -> PName -> ModuleCmd Name
- renameType :: NamingEnv -> PName -> ModuleCmd Name
- type Iface = IfaceG ModName
- data IfaceG name = Iface {
  - ifNames :: IfaceNames name
  - ifParams :: FunctorParams
  - ifDefines :: IfaceDecls
  }
- data IfaceDecls = IfaceDecls {
  - ifTySyns :: Map Name TySyn
  - ifNewtypes :: Map Name Newtype
  - ifAbstractTypes :: Map Name AbstractType
  - ifDecls :: Map Name IfaceDecl
  - ifModules :: !(Map Name (IfaceNames Name))
  - ifSignatures :: !(Map Name ModParamNames)
  - ifFunctors :: !(Map Name (IfaceG Name))
  }
- genIface :: ModuleG name -> IfaceG name
- data IfaceDecl = IfaceDecl {
  - ifDeclName :: !Name
  - ifDeclSig :: Schema
  - ifDeclIsPrim :: !Bool
  - ifDeclPragmas :: [Pragma]
  - ifDeclInfix :: Bool
  - ifDeclFixity :: Maybe Fixity
  - ifDeclDoc :: Maybe Text
  }
- getFileDependencies :: FilePath -> ModuleCmd (ModulePath, FileInfo)
- getModuleDependencies :: ModName -> ModuleCmd (ModulePath, FileInfo)

# Module System

data ModuleEnv Source #

This is the current state of the interpreter.

Constructors

ModuleEnv |

Fields

- meLoadedModules :: LoadedModules

  Information about all loaded modules. See `LoadedModuleG`. Contains information such as the file where the module was loaded from, as well as the module's interface, used for type checking.

- meNameSeeds :: NameSeeds

  A source of new names for the type checker.

- meEvalEnv :: EvalEnv

  The evaluation environment. Contains the values for all loaded modules, both public and private.

- meCoreLint :: CoreLint

  Should we run the linter to ensure sanity.

- meMonoBinds :: !Bool

  Are we assuming that local bindings are monomorphic. XXX: We should probably remove this flag, and set it to `True`.

- meFocusedModule :: Maybe ModName

  The "current" module. Used to decide how to print names, for example.

- meSearchPath :: [FilePath]

  Where we look for things.

- meDynEnv :: DynamicEnv

  This contains additional definitions that were made at the command line, and so they don't reside in any module.

- meSupply :: !Supply

  Name source for the renamer

#### Instances

Instances details

Generic ModuleEnv Source # |
Instance details Defined in Cryptol.ModuleSystem.Env Associated Types type Rep ModuleEnv :: Type -> Type Source # Methods from :: ModuleEnv -> Rep ModuleEnv x Source # to :: Rep ModuleEnv x -> ModuleEnv Source #
NFData ModuleEnv Source # |
Instance details Defined in Cryptol.ModuleSystem.Env Methods rnf :: ModuleEnv -> () Source #
type Rep ModuleEnv Source # |

Instance details

Defined in Cryptol.ModuleSystem.Env

type Rep ModuleEnv = D1 ('MetaData "ModuleEnv" "Cryptol.ModuleSystem.Env" "cryptol-3.0.0-DBVDUAjB1JeD0WzkHH4ckn" 'False) (C1 ('MetaCons "ModuleEnv" 'PrefixI 'True) (((S1 ('MetaSel ('Just "meLoadedModules") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 LoadedModules) :*: S1 ('MetaSel ('Just "meNameSeeds") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 NameSeeds)) :*: (S1 ('MetaSel ('Just "meEvalEnv") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 EvalEnv) :*: S1 ('MetaSel ('Just "meCoreLint") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 CoreLint))) :*: ((S1 ('MetaSel ('Just "meMonoBinds") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Bool) :*: S1 ('MetaSel ('Just "meFocusedModule") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe ModName))) :*: (S1 ('MetaSel ('Just "meSearchPath") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [FilePath]) :*: (S1 ('MetaSel ('Just "meDynEnv") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 DynamicEnv) :*: S1 ('MetaSel ('Just "meSupply") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Supply))))))

initialModuleEnv :: IO ModuleEnv Source #

data DynamicEnv Source #

Extra information we need to carry around to dynamically extend an environment outside the context of a single module. Particularly useful when dealing with interactive declarations as in `let` or `it`.

Constructors

DEnv |

Fields

- deNames :: NamingEnv
- deDecls :: [DeclGroup]
- deTySyns :: Map Name TySyn
- deEnv :: EvalEnv

#### Instances

Instances details

Monoid DynamicEnv Source # |
Instance details Defined in Cryptol.ModuleSystem.Env Methods mempty :: DynamicEnv Source # mappend :: DynamicEnv -> DynamicEnv -> DynamicEnv Source # mconcat :: [DynamicEnv] -> DynamicEnv Source #
Semigroup DynamicEnv Source # |
Instance details Defined in Cryptol.ModuleSystem.Env Methods (<>) :: DynamicEnv -> DynamicEnv -> DynamicEnv Source # sconcat :: NonEmpty DynamicEnv -> DynamicEnv Source # stimes :: Integral b => b -> DynamicEnv -> DynamicEnv Source #
Generic DynamicEnv Source # |
Instance details Defined in Cryptol.ModuleSystem.Env Associated Types type Rep DynamicEnv :: Type -> Type Source # Methods from :: DynamicEnv -> Rep DynamicEnv x Source # to :: Rep DynamicEnv x -> DynamicEnv Source #
type Rep DynamicEnv Source # |

Instance details

Defined in Cryptol.ModuleSystem.Env

type Rep DynamicEnv = D1 ('MetaData "DynamicEnv" "Cryptol.ModuleSystem.Env" "cryptol-3.0.0-DBVDUAjB1JeD0WzkHH4ckn" 'False) (C1 ('MetaCons "DEnv" 'PrefixI 'True) ((S1 ('MetaSel ('Just "deNames") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 NamingEnv) :*: S1 ('MetaSel ('Just "deDecls") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [DeclGroup])) :*: (S1 ('MetaSel ('Just "deTySyns") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Map Name TySyn)) :*: S1 ('MetaSel ('Just "deEnv") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 EvalEnv))))

data ModuleError Source #

Constructors

ModuleNotFound ModName [FilePath] | Unable to find the module given, tried looking in these paths
CantFindFile FilePath | Unable to open a file
BadUtf8 ModulePath UnicodeException | Bad UTF-8 encoding in while decoding this file
OtherIOError FilePath IOException | Some other IO error occurred while reading this file
ModuleParseError ModulePath ParseError | Generated this parse error when parsing the file for module m
RecursiveModules [ImportSource] | Recursive module group discovered
RenamerErrors ImportSource [RenamerError] | Problems during the renaming phase
NoPatErrors ImportSource [Error] | Problems during the NoPat phase
ExpandPropGuardsError ImportSource Error | Problems during the ExpandPropGuards phase
NoIncludeErrors ImportSource [IncludeError] | Problems during the NoInclude phase
TypeCheckingFailed ImportSource NameMap [(Range, Error)] | Problems during type checking
OtherFailure String | Problems after type checking, eg. specialization
ModuleNameMismatch ModName (Located ModName) | Module loaded by 'import' statement has the wrong module name
DuplicateModuleName ModName FilePath FilePath | Two modules loaded from different files have the same module name
FFILoadErrors ModName [FFILoadError] | Errors loading foreign function implementations
ErrorInFile ModulePath ModuleError | This is just a tag on the error, indicating the file containing it. It is convenient when we had to look for the module, and we'd like to communicate the location of pthe problematic module to the handler.

#### Instances

Instances details

Show ModuleError Source # |
Instance details Defined in Cryptol.ModuleSystem.Monad Methods showsPrec :: Int -> ModuleError -> ShowS Source # show :: ModuleError -> String Source # showList :: [ModuleError] -> ShowS Source #
PP ModuleError Source # |
Instance details Defined in Cryptol.ModuleSystem.Monad Methods ppPrec :: Int -> ModuleError -> Doc Source #
NFData ModuleError Source # |
Instance details Defined in Cryptol.ModuleSystem.Monad Methods rnf :: ModuleError -> () Source #

data ModuleWarning Source #

Constructors

TypeCheckWarnings NameMap [(Range, Warning)] |
RenamerWarnings [RenamerWarning] |

#### Instances

Instances details

Generic ModuleWarning Source # |
Instance details Defined in Cryptol.ModuleSystem.Monad Associated Types type Rep ModuleWarning :: Type -> Type Source # Methods from :: ModuleWarning -> Rep ModuleWarning x Source # to :: Rep ModuleWarning x -> ModuleWarning Source #
Show ModuleWarning Source # |
Instance details Defined in Cryptol.ModuleSystem.Monad Methods showsPrec :: Int -> ModuleWarning -> ShowS Source # show :: ModuleWarning -> String Source # showList :: [ModuleWarning] -> ShowS Source #
PP ModuleWarning Source # |
Instance details Defined in Cryptol.ModuleSystem.Monad Methods ppPrec :: Int -> ModuleWarning -> Doc Source #
NFData ModuleWarning Source # |
Instance details Defined in Cryptol.ModuleSystem.Monad Methods rnf :: ModuleWarning -> () Source #
type Rep ModuleWarning Source # |

Instance details

Defined in Cryptol.ModuleSystem.Monad

type Rep ModuleWarning = D1 ('MetaData "ModuleWarning" "Cryptol.ModuleSystem.Monad" "cryptol-3.0.0-DBVDUAjB1JeD0WzkHH4ckn" 'False) (C1 ('MetaCons "TypeCheckWarnings" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 NameMap) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [(Range, Warning)])) :+: C1 ('MetaCons "RenamerWarnings" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [RenamerWarning])))

type ModuleCmd a = ModuleInput IO -> IO (ModuleRes a) Source #

type ModuleRes a = (Either ModuleError (a, ModuleEnv), [ModuleWarning]) Source #

data ModuleInput m Source #

Constructors

ModuleInput |

Fields

- minpCallStacks :: Bool
- minpEvalOpts :: m EvalOpts
- minpByteReader :: FilePath -> m ByteString
- minpModuleEnv :: ModuleEnv
- minpTCSolver :: Solver

findModule :: ModName -> ModuleCmd ModulePath Source #

Find the file associated with a module name in the module search path.

loadModuleByPath :: FilePath -> ModuleCmd (ModulePath, TCTopEntity) Source #

Load the module contained in the given file.

loadModuleByName :: ModName -> ModuleCmd (ModulePath, TCTopEntity) Source #

Load the given parsed module.

checkModuleByPath :: FilePath -> ModuleCmd (ModulePath, TCTopEntity) Source #

Parse and typecheck a module, but don't evaluate or change the environment.

checkExpr :: Expr PName -> ModuleCmd (Expr Name, Expr, Schema) Source #

Check the type of an expression. Give back the renamed expression, the core expression, and its type schema.

evalExpr :: Expr -> ModuleCmd Value Source #

Evaluate an expression.

benchmarkExpr :: Double -> Expr -> ModuleCmd BenchmarkStats Source #

Benchmark an expression.

checkDecls :: [TopDecl PName] -> ModuleCmd (NamingEnv, [DeclGroup], Map Name TySyn) Source #

Typecheck top-level declarations.

evalDecls :: [DeclGroup] -> ModuleCmd () Source #

Evaluate declarations and add them to the extended environment.

noPat :: RemovePatterns a => a -> ModuleCmd a Source #

focusedEnv :: ModuleEnv -> ModContext Source #

Given the state of the environment, compute information about what's in scope on the REPL. This includes what's in the focused module, plus any additional definitions from the REPL (e.g., let bound names, and `it`).

getPrimMap :: ModuleCmd PrimMap Source #

renameVar :: NamingEnv -> PName -> ModuleCmd Name Source #

Rename a *use* of a value name. The distinction between uses and binding is used to keep track of dependencies.

renameType :: NamingEnv -> PName -> ModuleCmd Name Source #

Rename a *use* of a type name. The distinction between uses and binding is used to keep track of dependencies.

# Interfaces

type Iface = IfaceG ModName Source #

data IfaceG name Source #

The interface repersenting a typecheck top-level module.

Constructors

Iface |

Fields

- ifNames :: IfaceNames name

  Info about names in this module

- ifParams :: FunctorParams

  Module parameters, if any

- ifDefines :: IfaceDecls

  All things defines in the module (includes nested definitions)

#### Instances

Instances details

Generic (IfaceG name) Source # |
Instance details Defined in Cryptol.ModuleSystem.Interface Associated Types type Rep (IfaceG name) :: Type -> Type Source # Methods from :: IfaceG name -> Rep (IfaceG name) x Source # to :: Rep (IfaceG name) x -> IfaceG name Source #
Show name => Show (IfaceG name) Source # |
Instance details Defined in Cryptol.ModuleSystem.Interface Methods showsPrec :: Int -> IfaceG name -> ShowS Source # show :: IfaceG name -> String Source # showList :: [IfaceG name] -> ShowS Source #
NFData name => NFData (IfaceG name) Source # |
Instance details Defined in Cryptol.ModuleSystem.Interface Methods rnf :: IfaceG name -> () Source #
type Rep (IfaceG name) Source # |

Instance details

Defined in Cryptol.ModuleSystem.Interface

type Rep (IfaceG name) = D1 ('MetaData "IfaceG" "Cryptol.ModuleSystem.Interface" "cryptol-3.0.0-DBVDUAjB1JeD0WzkHH4ckn" 'False) (C1 ('MetaCons "Iface" 'PrefixI 'True) (S1 ('MetaSel ('Just "ifNames") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (IfaceNames name)) :*: (S1 ('MetaSel ('Just "ifParams") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 FunctorParams) :*: S1 ('MetaSel ('Just "ifDefines") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 IfaceDecls))))

data IfaceDecls Source #

Declarations in a module. Note that this includes things from nested modules, but not things from nested functors, which are in `ifFunctors`.

Constructors

IfaceDecls |

Fields

- ifTySyns :: Map Name TySyn
- ifNewtypes :: Map Name Newtype
- ifAbstractTypes :: Map Name AbstractType
- ifDecls :: Map Name IfaceDecl
- ifModules :: !(Map Name (IfaceNames Name))
- ifSignatures :: !(Map Name ModParamNames)
- ifFunctors :: !(Map Name (IfaceG Name))

  XXX: Maybe arg info? Also, with the current implementation we aim to complete remove functors by essentially inlining them. To achieve this with just interfaces we'd have to store here the entire module, not just its interface. At the moment we work around this by passing all loaded modules to the type checker, so it looks up functors there, instead of in the interfaces, but we'd need to change this if we want better support for separate compilation.

#### Instances

Instances details

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

Instance details

Defined in Cryptol.ModuleSystem.Interface

type Rep IfaceDecls = D1 ('MetaData "IfaceDecls" "Cryptol.ModuleSystem.Interface" "cryptol-3.0.0-DBVDUAjB1JeD0WzkHH4ckn" 'False) (C1 ('MetaCons "IfaceDecls" 'PrefixI 'True) ((S1 ('MetaSel ('Just "ifTySyns") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Map Name TySyn)) :*: (S1 ('MetaSel ('Just "ifNewtypes") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Map Name Newtype)) :*: S1 ('MetaSel ('Just "ifAbstractTypes") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Map Name AbstractType)))) :*: ((S1 ('MetaSel ('Just "ifDecls") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Map Name IfaceDecl)) :*: S1 ('MetaSel ('Just "ifModules") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (Map Name (IfaceNames Name)))) :*: (S1 ('MetaSel ('Just "ifSignatures") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (Map Name ModParamNames)) :*: S1 ('MetaSel ('Just "ifFunctors") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (Map Name (IfaceG Name)))))))

genIface :: ModuleG name -> IfaceG name Source #

data IfaceDecl Source #

Constructors

IfaceDecl |

Fields

- ifDeclName :: !Name

  Name of thing

- ifDeclSig :: Schema

  Type

- ifDeclIsPrim :: !Bool
- ifDeclPragmas :: [Pragma]

  Pragmas

- ifDeclInfix :: Bool

  Is this an infix thing

- ifDeclFixity :: Maybe Fixity

  Fixity information

- ifDeclDoc :: Maybe Text

  Documentation

#### Instances

Instances details

Generic IfaceDecl Source # |
Instance details Defined in Cryptol.ModuleSystem.Interface Associated Types type Rep IfaceDecl :: Type -> Type Source # Methods from :: IfaceDecl -> Rep IfaceDecl x Source # to :: Rep IfaceDecl x -> IfaceDecl Source #
Show IfaceDecl Source # |
Instance details Defined in Cryptol.ModuleSystem.Interface Methods showsPrec :: Int -> IfaceDecl -> ShowS Source # show :: IfaceDecl -> String Source # showList :: [IfaceDecl] -> ShowS Source #
NFData IfaceDecl Source # |
Instance details Defined in Cryptol.ModuleSystem.Interface Methods rnf :: IfaceDecl -> () Source #
type Rep IfaceDecl Source # |

Instance details

Defined in Cryptol.ModuleSystem.Interface

type Rep IfaceDecl = D1 ('MetaData "IfaceDecl" "Cryptol.ModuleSystem.Interface" "cryptol-3.0.0-DBVDUAjB1JeD0WzkHH4ckn" 'False) (C1 ('MetaCons "IfaceDecl" 'PrefixI 'True) ((S1 ('MetaSel ('Just "ifDeclName") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Name) :*: (S1 ('MetaSel ('Just "ifDeclSig") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Schema) :*: S1 ('MetaSel ('Just "ifDeclIsPrim") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Bool))) :*: ((S1 ('MetaSel ('Just "ifDeclPragmas") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Pragma]) :*: S1 ('MetaSel ('Just "ifDeclInfix") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Bool)) :*: (S1 ('MetaSel ('Just "ifDeclFixity") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Fixity)) :*: S1 ('MetaSel ('Just "ifDeclDoc") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Text))))))

# Dependencies

getFileDependencies :: FilePath -> ModuleCmd (ModulePath, FileInfo) Source #

Get information about the dependencies of a file.

getModuleDependencies :: ModName -> ModuleCmd (ModulePath, FileInfo) Source #

Get information about the dependencies of a module.