ghcide-1.6.0.0: The core of an IDE
Safe HaskellNone
LanguageHaskell2010

Development.IDE

Synopsis

Documentation

data ParseResult a #

The result of running a parser.

Constructors

POk

The parser has consumed a (possibly empty) prefix of the input and produced a result. Use getMessages to check for accumulated warnings and non-fatal errors.

Fields

  • PState

    The resulting parsing state. Can be used to resume parsing.

  • a

    The resulting value.

PFailed

The parser has consumed a (possibly empty) prefix of the input and failed.

Fields

action :: Action a -> Rules () #

type family RuleResult key #

The type mapping between the key or a rule and the resulting value. See addBuiltinRule and apply.

Instances

Instances details
type RuleResult NonLocalCompletions Source # 
Instance details

Defined in Development.IDE.Plugin.Completions.Types

type RuleResult LocalCompletions Source #

Produce completions info for a file

Instance details

Defined in Development.IDE.Plugin.Completions.Types

type RuleResult GhcSessionIO Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult AddWatchedFile Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetClientSettings Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetModSummary Source #

Generate a ModSummary that has enough information to be used to get .hi and .hie files. without needing to parse the entire source

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetModSummaryWithoutTimestamps Source #

Generate a ModSummary with the timestamps and preprocessed content elided, for more successful early cutoff

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult IsFileOfInterest Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetModIface Source #

Get a module interface details, either from an interface file or a typechecked module

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetModIfaceFromDiskAndIndex Source #

GetModIfaceFromDisk and index the `.hie` file into the database. This is an internal rule, use GetModIface instead.

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetModIfaceFromDisk Source #

Read the module interface file from disk. Throws an error for VFS files. This is an internal rule, use GetModIface instead.

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GhcSessionDeps Source #

A GHC session preloaded with all the dependencies This rule is also responsible for calling ReportImportCycles for the direct dependencies

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GhcSession Source #

A GHC session that we reuse.

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetBindings Source #

A IntervalMap telling us what is in scope at each point

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetHieAst Source #

The uncompressed HieAST

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetDocMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult TypeCheck Source #

The type checked version of this file, requires TypeCheck+

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult ReportImportCycles Source #

This rule is used to report import cycles. It depends on GetDependencyInformation. We cannot report the cycles directly from GetDependencyInformation since we can only report diagnostics for the current file.

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetModuleGraph Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetDependencyInformation Source #

The dependency information produced by following the imports recursively. This rule will succeed even if there is an error, e.g., a module could not be located, a module could not be parsed or an import cycle.

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult NeedsCompilation Source #

Does this module need to be compiled?

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetLocatedImports Source #

Resolve the imports in a module to the file path of a module in the same package

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetParsedModuleWithComments Source #

The parse tree for the file using GetFileContents, all comments included using Opt_KeepRawTokenStream

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetParsedModule Source #

The parse tree for the file using GetFileContents

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetFileExists Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetFileContents Source #

Get the contents of a file, either dirty (if the buffer is modified) or Nothing to mean use from disk.

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetModificationTime Source #

Get the modification time of a file.

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetImportMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GenerateCore Source #

Convert to Core, requires TypeCheck*

Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetKnownTargets Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type RuleResult GetAnnotatedParsedSource Source # 
Instance details

Defined in Development.IDE.GHC.ExactPrint

type RuleResult IsHiFileStable Source # 
Instance details

Defined in Development.IDE.Core.Rules

type RuleResult GetGlobalBindingTypeSigs Source # 
Instance details

Defined in Development.IDE.Plugin.TypeLenses

type RuleResult (Q k) Source # 
Instance details

Defined in Development.IDE.Types.Shake

type RuleResult (Q k) = A (RuleResult k)

data Rules a #

Instances

Instances details
Monad Rules 
Instance details

Defined in Development.IDE.Graph.Internal.Types

Methods

(>>=) :: Rules a -> (a -> Rules b) -> Rules b #

(>>) :: Rules a -> Rules b -> Rules b #

return :: a -> Rules a #

Functor Rules 
Instance details

Defined in Development.IDE.Graph.Internal.Types

Methods

fmap :: (a -> b) -> Rules a -> Rules b #

(<$) :: a -> Rules b -> Rules a #

MonadFail Rules 
Instance details

Defined in Development.IDE.Graph.Internal.Types

Methods

fail :: String -> Rules a #

Applicative Rules 
Instance details

Defined in Development.IDE.Graph.Internal.Types

Methods

pure :: a -> Rules a #

(<*>) :: Rules (a -> b) -> Rules a -> Rules b #

liftA2 :: (a -> b -> c) -> Rules a -> Rules b -> Rules c #

(*>) :: Rules a -> Rules b -> Rules b #

(<*) :: Rules a -> Rules b -> Rules a #

MonadIO Rules 
Instance details

Defined in Development.IDE.Graph.Internal.Types

Methods

liftIO :: IO a -> Rules a #

Semigroup a => Semigroup (Rules a) 
Instance details

Defined in Development.IDE.Graph.Internal.Types

Methods

(<>) :: Rules a -> Rules a -> Rules a #

sconcat :: NonEmpty (Rules a) -> Rules a #

stimes :: Integral b => b -> Rules a -> Rules a #

Monoid a => Monoid (Rules a) 
Instance details

Defined in Development.IDE.Graph.Internal.Types

Methods

mempty :: Rules a #

mappend :: Rules a -> Rules a -> Rules a #

mconcat :: [Rules a] -> Rules a #

data Action a #

Instances

Instances details
Monad Action 
Instance details

Defined in Development.IDE.Graph.Internal.Types

Methods

(>>=) :: Action a -> (a -> Action b) -> Action b #

(>>) :: Action a -> Action b -> Action b #

return :: a -> Action a #

Functor Action 
Instance details

Defined in Development.IDE.Graph.Internal.Types

Methods

fmap :: (a -> b) -> Action a -> Action b #

(<$) :: a -> Action b -> Action a #

MonadFail Action 
Instance details

Defined in Development.IDE.Graph.Internal.Types

Methods

fail :: String -> Action a #

Applicative Action 
Instance details

Defined in Development.IDE.Graph.Internal.Types

Methods

pure :: a -> Action a #

(<*>) :: Action (a -> b) -> Action a -> Action b #

liftA2 :: (a -> b -> c) -> Action a -> Action b -> Action c #

(*>) :: Action a -> Action b -> Action b #

(<*) :: Action a -> Action b -> Action a #

MonadIO Action 
Instance details

Defined in Development.IDE.Graph.Internal.Types

Methods

liftIO :: IO a -> Action a #

MonadThrow Action 
Instance details

Defined in Development.IDE.Graph.Internal.Types

Methods

throwM :: Exception e => e -> Action a #

MonadCatch Action 
Instance details

Defined in Development.IDE.Graph.Internal.Types

Methods

catch :: Exception e => Action a -> (e -> Action a) -> Action a #

MonadMask Action 
Instance details

Defined in Development.IDE.Graph.Internal.Types

Methods

mask :: ((forall a. Action a -> Action a) -> Action b) -> Action b #

uninterruptibleMask :: ((forall a. Action a -> Action a) -> Action b) -> Action b #

generalBracket :: Action a -> (a -> ExitCase b -> Action c) -> (a -> Action b) -> Action (b, c) #

getClientConfig :: MonadLsp Config m => m Config #

Returns the current client configuration. It is not wise to permanently cache the returned value of this function, as clients can at runitime change their configuration.

data NormalizedUri #

Instances

Instances details
Eq NormalizedUri 
Instance details

Defined in Language.LSP.Types.Uri

Ord NormalizedUri 
Instance details

Defined in Language.LSP.Types.Uri

Read NormalizedUri 
Instance details

Defined in Language.LSP.Types.Uri

Show NormalizedUri 
Instance details

Defined in Language.LSP.Types.Uri

Generic NormalizedUri 
Instance details

Defined in Language.LSP.Types.Uri

Associated Types

type Rep NormalizedUri :: Type -> Type #

Hashable NormalizedUri 
Instance details

Defined in Language.LSP.Types.Uri

NFData NormalizedUri 
Instance details

Defined in Language.LSP.Types.Uri

Methods

rnf :: NormalizedUri -> () #

type Rep NormalizedUri 
Instance details

Defined in Language.LSP.Types.Uri

type Rep NormalizedUri = D1 ('MetaData "NormalizedUri" "Language.LSP.Types.Uri" "lsp-types-1.4.0.1-2rh5K3u4z9UBFaccFshq5a" 'False) (C1 ('MetaCons "NormalizedUri" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Int) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Text)))

data Diagnostic #

Instances

Instances details
Eq Diagnostic 
Instance details

Defined in Language.LSP.Types.Diagnostic

Ord Diagnostic 
Instance details

Defined in Language.LSP.Types.Diagnostic

Read Diagnostic 
Instance details

Defined in Language.LSP.Types.Diagnostic

Show Diagnostic 
Instance details

Defined in Language.LSP.Types.Diagnostic

Generic Diagnostic 
Instance details

Defined in Language.LSP.Types.Diagnostic

Associated Types

type Rep Diagnostic :: Type -> Type #

ToJSON Diagnostic 
Instance details

Defined in Language.LSP.Types.Diagnostic

FromJSON Diagnostic 
Instance details

Defined in Language.LSP.Types.Diagnostic

NFData Diagnostic 
Instance details

Defined in Language.LSP.Types.Diagnostic

Methods

rnf :: Diagnostic -> () #

HasMessage Diagnostic Text 
Instance details

Defined in Language.LSP.Types.Lens

HasRange Diagnostic Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRelatedInformation Diagnostic (Maybe (List DiagnosticRelatedInformation)) 
Instance details

Defined in Language.LSP.Types.Lens

HasSeverity Diagnostic (Maybe DiagnosticSeverity) 
Instance details

Defined in Language.LSP.Types.Lens

HasSource Diagnostic (Maybe DiagnosticSource) 
Instance details

Defined in Language.LSP.Types.Lens

HasCode Diagnostic (Maybe (Int32 |? Text)) 
Instance details

Defined in Language.LSP.Types.Lens

HasDiagnostics CodeAction (Maybe (List Diagnostic)) 
Instance details

Defined in Language.LSP.Types.Lens

HasDiagnostics CodeActionContext (List Diagnostic) 
Instance details

Defined in Language.LSP.Types.Lens

HasDiagnostics PublishDiagnosticsParams (List Diagnostic) 
Instance details

Defined in Language.LSP.Types.Lens

HasTags Diagnostic (Maybe (List DiagnosticTag)) 
Instance details

Defined in Language.LSP.Types.Lens

type Rep Diagnostic 
Instance details

Defined in Language.LSP.Types.Diagnostic

data DiagnosticSeverity #

Constructors

DsError

Error = 1,

DsWarning

Warning = 2,

DsInfo

Info = 3,

DsHint

Hint = 4

Instances

Instances details
Eq DiagnosticSeverity 
Instance details

Defined in Language.LSP.Types.Diagnostic

Ord DiagnosticSeverity 
Instance details

Defined in Language.LSP.Types.Diagnostic

Read DiagnosticSeverity 
Instance details

Defined in Language.LSP.Types.Diagnostic

Show DiagnosticSeverity 
Instance details

Defined in Language.LSP.Types.Diagnostic

Generic DiagnosticSeverity 
Instance details

Defined in Language.LSP.Types.Diagnostic

Associated Types

type Rep DiagnosticSeverity :: Type -> Type #

ToJSON DiagnosticSeverity 
Instance details

Defined in Language.LSP.Types.Diagnostic

FromJSON DiagnosticSeverity 
Instance details

Defined in Language.LSP.Types.Diagnostic

NFData DiagnosticSeverity 
Instance details

Defined in Language.LSP.Types.Diagnostic

Methods

rnf :: DiagnosticSeverity -> () #

HasSeverity Diagnostic (Maybe DiagnosticSeverity) 
Instance details

Defined in Language.LSP.Types.Lens

type Rep DiagnosticSeverity 
Instance details

Defined in Language.LSP.Types.Diagnostic

type Rep DiagnosticSeverity = D1 ('MetaData "DiagnosticSeverity" "Language.LSP.Types.Diagnostic" "lsp-types-1.4.0.1-2rh5K3u4z9UBFaccFshq5a" 'False) ((C1 ('MetaCons "DsError" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "DsWarning" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "DsInfo" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "DsHint" 'PrefixI 'False) (U1 :: Type -> Type)))

data Location #

Constructors

Location 

Fields

Instances

Instances details
Eq Location 
Instance details

Defined in Language.LSP.Types.Location

Ord Location 
Instance details

Defined in Language.LSP.Types.Location

Read Location 
Instance details

Defined in Language.LSP.Types.Location

Show Location 
Instance details

Defined in Language.LSP.Types.Location

Generic Location 
Instance details

Defined in Language.LSP.Types.Location

Associated Types

type Rep Location :: Type -> Type #

Methods

from :: Location -> Rep Location x #

to :: Rep Location x -> Location #

ToJSON Location 
Instance details

Defined in Language.LSP.Types.Location

FromJSON Location 
Instance details

Defined in Language.LSP.Types.Location

NFData Location 
Instance details

Defined in Language.LSP.Types.Location

Methods

rnf :: Location -> () #

HasLocation DiagnosticRelatedInformation Location 
Instance details

Defined in Language.LSP.Types.Lens

HasLocation SymbolInformation Location 
Instance details

Defined in Language.LSP.Types.Lens

HasRange Location Range 
Instance details

Defined in Language.LSP.Types.Lens

HasUri Location Uri 
Instance details

Defined in Language.LSP.Types.Lens

Methods

uri :: Lens' Location Uri #

type Rep Location 
Instance details

Defined in Language.LSP.Types.Location

type Rep Location = D1 ('MetaData "Location" "Language.LSP.Types.Location" "lsp-types-1.4.0.1-2rh5K3u4z9UBFaccFshq5a" 'False) (C1 ('MetaCons "Location" 'PrefixI 'True) (S1 ('MetaSel ('Just "_uri") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Uri) :*: S1 ('MetaSel ('Just "_range") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Range)))

data Range #

Constructors

Range 

Fields

Instances

Instances details
Eq Range 
Instance details

Defined in Language.LSP.Types.Location

Methods

(==) :: Range -> Range -> Bool #

(/=) :: Range -> Range -> Bool #

Ord Range 
Instance details

Defined in Language.LSP.Types.Location

Methods

compare :: Range -> Range -> Ordering #

(<) :: Range -> Range -> Bool #

(<=) :: Range -> Range -> Bool #

(>) :: Range -> Range -> Bool #

(>=) :: Range -> Range -> Bool #

max :: Range -> Range -> Range #

min :: Range -> Range -> Range #

Read Range 
Instance details

Defined in Language.LSP.Types.Location

Show Range 
Instance details

Defined in Language.LSP.Types.Location

Methods

showsPrec :: Int -> Range -> ShowS #

show :: Range -> String #

showList :: [Range] -> ShowS #

Generic Range 
Instance details

Defined in Language.LSP.Types.Location

Associated Types

type Rep Range :: Type -> Type #

Methods

from :: Range -> Rep Range x #

to :: Rep Range x -> Range #

ToJSON Range 
Instance details

Defined in Language.LSP.Types.Location

FromJSON Range 
Instance details

Defined in Language.LSP.Types.Location

NFData Range 
Instance details

Defined in Language.LSP.Types.Location

Methods

rnf :: Range -> () #

MapAge Range Source # 
Instance details

Defined in Development.IDE.Core.UseStale

Methods

mapAgeFrom :: forall (from :: Age) (to :: Age). PositionMap from to -> Tracked to Range -> Maybe (Tracked from Range) Source #

mapAgeTo :: forall (from :: Age) (to :: Age). PositionMap from to -> Tracked from Range -> Maybe (Tracked to Range) Source #

HasSelectionRange CallHierarchyItem Range 
Instance details

Defined in Language.LSP.Types.Lens

HasSelectionRange DocumentSymbol Range 
Instance details

Defined in Language.LSP.Types.Lens

HasInsert InsertReplaceEdit Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRepalce InsertReplaceEdit Range 
Instance details

Defined in Language.LSP.Types.Lens

HasTargetRange LocationLink Range 
Instance details

Defined in Language.LSP.Types.Lens

HasTargetSelectionRange LocationLink Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange CodeActionParams Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange ColorPresentationParams Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange ColorInformation Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange AnnotatedTextEdit Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange TextEdit Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange CallHierarchyItem Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange CodeLens Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange Diagnostic Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange DocumentHighlight Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange DocumentLink Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange DocumentSymbol Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange DocumentRangeFormattingParams Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange RangeWithPlaceholder Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange SelectionRange Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange SemanticTokensRangeParams Range 
Instance details

Defined in Language.LSP.Types.Lens

HasRange Location Range 
Instance details

Defined in Language.LSP.Types.Lens

HasEnd Range Position 
Instance details

Defined in Language.LSP.Types.Lens

HasStart Range Position 
Instance details

Defined in Language.LSP.Types.Lens

HasFromRanges CallHierarchyOutgoingCall (List Range) 
Instance details

Defined in Language.LSP.Types.Lens

HasFromRanges CallHierarchyIncomingCall (List Range) 
Instance details

Defined in Language.LSP.Types.Lens

HasSelection ShowDocumentParams (Maybe Range) 
Instance details

Defined in Language.LSP.Types.Lens

HasOriginSelectionRange LocationLink (Maybe Range) 
Instance details

Defined in Language.LSP.Types.Lens

HasRange Hover (Maybe Range) 
Instance details

Defined in Language.LSP.Types.Lens

HasRange TextDocumentContentChangeEvent (Maybe Range) 
Instance details

Defined in Language.LSP.Types.Lens

type Rep Range 
Instance details

Defined in Language.LSP.Types.Location

type Rep Range = D1 ('MetaData "Range" "Language.LSP.Types.Location" "lsp-types-1.4.0.1-2rh5K3u4z9UBFaccFshq5a" 'False) (C1 ('MetaCons "Range" 'PrefixI 'True) (S1 ('MetaSel ('Just "_start") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Position) :*: S1 ('MetaSel ('Just "_end") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Position)))

data Position #

Constructors

Position 

Fields

  • _line :: UInt

    Line position in a document (zero-based).

  • _character :: UInt

    Character offset on a line in a document (zero-based). Assuming that the line is represented as a string, the character value represents the gap between the character and character + 1.

Instances

Instances details
Eq Position 
Instance details

Defined in Language.LSP.Types.Location

Ord Position 
Instance details

Defined in Language.LSP.Types.Location

Read Position 
Instance details

Defined in Language.LSP.Types.Location

Show Position 
Instance details

Defined in Language.LSP.Types.Location

Generic Position 
Instance details

Defined in Language.LSP.Types.Location

Associated Types

type Rep Position :: Type -> Type #

Methods

from :: Position -> Rep Position x #

to :: Rep Position x -> Position #

ToJSON Position 
Instance details

Defined in Language.LSP.Types.Location

FromJSON Position 
Instance details

Defined in Language.LSP.Types.Location

NFData Position 
Instance details

Defined in Language.LSP.Types.Location

Methods

rnf :: Position -> () #

HasPosition CompletionParams Position 
Instance details

Defined in Language.LSP.Types.Lens

HasPosition CallHierarchyPrepareParams Position 
Instance details

Defined in Language.LSP.Types.Lens

HasPosition DeclarationParams Position 
Instance details

Defined in Language.LSP.Types.Lens

HasPosition DefinitionParams Position 
Instance details

Defined in Language.LSP.Types.Lens

HasPosition DocumentHighlightParams Position 
Instance details

Defined in Language.LSP.Types.Lens

HasPosition DocumentOnTypeFormattingParams Position 
Instance details

Defined in Language.LSP.Types.Lens

HasPosition HoverParams Position 
Instance details

Defined in Language.LSP.Types.Lens

HasPosition ImplementationParams Position 
Instance details

Defined in Language.LSP.Types.Lens

HasPosition ReferenceParams Position 
Instance details

Defined in Language.LSP.Types.Lens

HasPosition PrepareRenameParams Position 
Instance details

Defined in Language.LSP.Types.Lens

HasPosition RenameParams Position 
Instance details

Defined in Language.LSP.Types.Lens

HasPosition TypeDefinitionParams Position 
Instance details

Defined in Language.LSP.Types.Lens

HasPosition TextDocumentPositionParams Position 
Instance details

Defined in Language.LSP.Types.Lens

HasEnd Range Position 
Instance details

Defined in Language.LSP.Types.Lens

HasStart Range Position 
Instance details

Defined in Language.LSP.Types.Lens

HasCharacter Position UInt 
Instance details

Defined in Language.LSP.Types.Lens

HasLine Position UInt 
Instance details

Defined in Language.LSP.Types.Lens

HasPositions SelectionRangeParams (List Position) 
Instance details

Defined in Language.LSP.Types.Lens

type Rep Position 
Instance details

Defined in Language.LSP.Types.Location

type Rep Position = D1 ('MetaData "Position" "Language.LSP.Types.Location" "lsp-types-1.4.0.1-2rh5K3u4z9UBFaccFshq5a" 'False) (C1 ('MetaCons "Position" 'PrefixI 'True) (S1 ('MetaSel ('Just "_line") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 UInt) :*: S1 ('MetaSel ('Just "_character") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 UInt)))

newtype Uri #

Constructors

Uri 

Fields

Instances

Instances details
Eq Uri 
Instance details

Defined in Language.LSP.Types.Uri

Methods

(==) :: Uri -> Uri -> Bool #

(/=) :: Uri -> Uri -> Bool #

Ord Uri 
Instance details

Defined in Language.LSP.Types.Uri

Methods

compare :: Uri -> Uri -> Ordering #

(<) :: Uri -> Uri -> Bool #

(<=) :: Uri -> Uri -> Bool #

(>) :: Uri -> Uri -> Bool #

(>=) :: Uri -> Uri -> Bool #

max :: Uri -> Uri -> Uri #

min :: Uri -> Uri -> Uri #

Read Uri 
Instance details

Defined in Language.LSP.Types.Uri

Show Uri 
Instance details

Defined in Language.LSP.Types.Uri

Methods

showsPrec :: Int -> Uri -> ShowS #

show :: Uri -> String #

showList :: [Uri] -> ShowS #

Generic Uri 
Instance details

Defined in Language.LSP.Types.Uri

Associated Types

type Rep Uri :: Type -> Type #

Methods

from :: Uri -> Rep Uri x #

to :: Rep Uri x -> Uri #

Hashable Uri 
Instance details

Defined in Language.LSP.Types.Uri

Methods

hashWithSalt :: Int -> Uri -> Int #

hash :: Uri -> Int #

ToJSON Uri 
Instance details

Defined in Language.LSP.Types.Uri

ToJSONKey Uri 
Instance details

Defined in Language.LSP.Types.Uri

FromJSON Uri 
Instance details

Defined in Language.LSP.Types.Uri

FromJSONKey Uri 
Instance details

Defined in Language.LSP.Types.Uri

NFData Uri 
Instance details

Defined in Language.LSP.Types.Uri

Methods

rnf :: Uri -> () #

HasNewUri RenameFile Uri 
Instance details

Defined in Language.LSP.Types.Lens

HasOldUri RenameFile Uri 
Instance details

Defined in Language.LSP.Types.Lens

HasTargetUri LocationLink Uri 
Instance details

Defined in Language.LSP.Types.Lens

HasUri DeleteFile Uri 
Instance details

Defined in Language.LSP.Types.Lens

HasUri CreateFile Uri 
Instance details

Defined in Language.LSP.Types.Lens

HasUri ShowDocumentParams Uri 
Instance details

Defined in Language.LSP.Types.Lens

HasUri FileEvent Uri 
Instance details

Defined in Language.LSP.Types.Lens

Methods

uri :: Lens' FileEvent Uri #

HasUri CallHierarchyItem Uri 
Instance details

Defined in Language.LSP.Types.Lens

HasUri PublishDiagnosticsParams Uri 
Instance details

Defined in Language.LSP.Types.Lens

HasUri TextDocumentItem Uri 
Instance details

Defined in Language.LSP.Types.Lens

HasUri VersionedTextDocumentIdentifier Uri 
Instance details

Defined in Language.LSP.Types.Lens

HasUri TextDocumentIdentifier Uri 
Instance details

Defined in Language.LSP.Types.Lens

HasUri Location Uri 
Instance details

Defined in Language.LSP.Types.Lens

Methods

uri :: Lens' Location Uri #

HasTarget DocumentLink (Maybe Uri) 
Instance details

Defined in Language.LSP.Types.Lens

HasChanges WorkspaceEdit (Maybe WorkspaceEditMap) 
Instance details

Defined in Language.LSP.Types.Lens

HasRootUri InitializeParams (Maybe Uri) 
Instance details

Defined in Language.LSP.Types.Lens

type Rep Uri 
Instance details

Defined in Language.LSP.Types.Uri

type Rep Uri = D1 ('MetaData "Uri" "Language.LSP.Types.Uri" "lsp-types-1.4.0.1-2rh5K3u4z9UBFaccFshq5a" 'True) (C1 ('MetaCons "Uri" 'PrefixI 'True) (S1 ('MetaSel ('Just "getUri") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text)))

data NormalizedFilePath #

Newtype wrapper around FilePath that always has normalized slashes. The NormalizedUri and hash of the FilePath are cached to avoided repeated normalisation when we need to compute them (which is a lot).

This is one of the most performance critical parts of ghcide, do not modify it without profiling.

Instances

Instances details
Eq NormalizedFilePath 
Instance details

Defined in Language.LSP.Types.Uri

Ord NormalizedFilePath 
Instance details

Defined in Language.LSP.Types.Uri

Show NormalizedFilePath 
Instance details

Defined in Language.LSP.Types.Uri

IsString NormalizedFilePath 
Instance details

Defined in Language.LSP.Types.Uri

Generic NormalizedFilePath 
Instance details

Defined in Language.LSP.Types.Uri

Associated Types

type Rep NormalizedFilePath :: Type -> Type #

Hashable NormalizedFilePath 
Instance details

Defined in Language.LSP.Types.Uri

Binary NormalizedFilePath 
Instance details

Defined in Language.LSP.Types.Uri

NFData NormalizedFilePath 
Instance details

Defined in Language.LSP.Types.Uri

Methods

rnf :: NormalizedFilePath -> () #

type Rep NormalizedFilePath 
Instance details

Defined in Language.LSP.Types.Uri

type Rep NormalizedFilePath = D1 ('MetaData "NormalizedFilePath" "Language.LSP.Types.Uri" "lsp-types-1.4.0.1-2rh5K3u4z9UBFaccFshq5a" 'False) (C1 ('MetaCons "NormalizedFilePath" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 NormalizedUri) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 FilePath)))

newtype List a #

All LSP types representing a list **must** use this type rather than '[]'. In particular this is necessary to change the FromJSON instance to be compatible with Elisp (where empty lists show up as null)

Constructors

List [a] 

Instances

Instances details
Functor List 
Instance details

Defined in Language.LSP.Types.Common

Methods

fmap :: (a -> b) -> List a -> List b #

(<$) :: a -> List b -> List a #

Foldable List 
Instance details

Defined in Language.LSP.Types.Common

Methods

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

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

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

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

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

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

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

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

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

toList :: List a -> [a] #

null :: List a -> Bool #

length :: List a -> Int #

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

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

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

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

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

Traversable List 
Instance details

Defined in Language.LSP.Types.Common

Methods

traverse :: Applicative f => (a -> f b) -> List a -> f (List b) #

sequenceA :: Applicative f => List (f a) -> f (List a) #

mapM :: Monad m => (a -> m b) -> List a -> m (List b) #

sequence :: Monad m => List (m a) -> m (List a) #

HasFormats SemanticTokensClientCapabilities (List TokenFormat) 
Instance details

Defined in Language.LSP.Types.Lens

HasTokenModifiers SemanticTokensClientCapabilities (List SemanticTokenModifiers) 
Instance details

Defined in Language.LSP.Types.Lens

HasTokenModifiers SemanticTokensLegend (List SemanticTokenModifiers) 
Instance details

Defined in Language.LSP.Types.Lens

HasTokenTypes SemanticTokensClientCapabilities (List SemanticTokenTypes) 
Instance details

Defined in Language.LSP.Types.Lens

HasTokenTypes SemanticTokensLegend (List SemanticTokenTypes) 
Instance details

Defined in Language.LSP.Types.Lens

HasFromRanges CallHierarchyOutgoingCall (List Range) 
Instance details

Defined in Language.LSP.Types.Lens

HasFromRanges CallHierarchyIncomingCall (List Range) 
Instance details

Defined in Language.LSP.Types.Lens

HasSignatures SignatureHelp (List SignatureInformation) 
Instance details

Defined in Language.LSP.Types.Lens

HasRetriggerCharacters SignatureHelpRegistrationOptions (Maybe (List Text)) 
Instance details

Defined in Language.LSP.Types.Lens

HasRetriggerCharacters SignatureHelpOptions (Maybe (List Text)) 
Instance details

Defined in Language.LSP.Types.Lens

HasContentFormat HoverClientCapabilities (Maybe (List MarkupKind)) 
Instance details

Defined in Language.LSP.Types.Lens

HasRelatedInformation Diagnostic (Maybe (List DiagnosticRelatedInformation)) 
Instance details

Defined in Language.LSP.Types.Lens

HasCommands ExecuteCommandRegistrationOptions (List Text) 
Instance details

Defined in Language.LSP.Types.Lens

HasCommands ExecuteCommandOptions (List Text) 
Instance details

Defined in Language.LSP.Types.Lens

HasArguments Command (Maybe (List Value)) 
Instance details

Defined in Language.LSP.Types.Lens

HasArguments ExecuteCommandParams (Maybe (List Value)) 
Instance details

Defined in Language.LSP.Types.Lens

HasContentChanges DidChangeTextDocumentParams (List TextDocumentContentChangeEvent) 
Instance details

Defined in Language.LSP.Types.Lens

HasAdded WorkspaceFoldersChangeEvent (List WorkspaceFolder) 
Instance details

Defined in Language.LSP.Types.Lens

HasRemoved WorkspaceFoldersChangeEvent (List WorkspaceFolder) 
Instance details

Defined in Language.LSP.Types.Lens

HasResourceOperations WorkspaceEditClientCapabilities (Maybe (List ResourceOperationKind)) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentChanges WorkspaceEdit (Maybe (List DocumentChange)) 
Instance details

Defined in Language.LSP.Types.Lens

HasEdits TextDocumentEdit (List (TextEdit |? AnnotatedTextEdit)) 
Instance details

Defined in Language.LSP.Types.Lens

HasEdits SemanticTokensDeltaPartialResult (List SemanticTokensEdit) 
Instance details

Defined in Language.LSP.Types.Lens

HasEdits SemanticTokensDelta (List SemanticTokensEdit) 
Instance details

Defined in Language.LSP.Types.Lens

HasChildren DocumentSymbol (Maybe (List DocumentSymbol)) 
Instance details

Defined in Language.LSP.Types.Lens

HasPositions SelectionRangeParams (List Position) 
Instance details

Defined in Language.LSP.Types.Lens

HasDiagnostics CodeAction (Maybe (List Diagnostic)) 
Instance details

Defined in Language.LSP.Types.Lens

HasDiagnostics CodeActionContext (List Diagnostic) 
Instance details

Defined in Language.LSP.Types.Lens

HasDiagnostics PublishDiagnosticsParams (List Diagnostic) 
Instance details

Defined in Language.LSP.Types.Lens

HasOnly CodeActionContext (Maybe (List CodeActionKind)) 
Instance details

Defined in Language.LSP.Types.Lens

HasCodeActionKinds CodeActionRegistrationOptions (Maybe (List CodeActionKind)) 
Instance details

Defined in Language.LSP.Types.Lens

HasCodeActionKinds CodeActionOptions (Maybe (List CodeActionKind)) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentationFormat CompletionItemClientCapabilities (Maybe (List MarkupKind)) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentationFormat SignatureHelpSignatureInformation (Maybe (List MarkupKind)) 
Instance details

Defined in Language.LSP.Types.Lens

HasProperties CodeActionResolveClientCapabilities (List Text) 
Instance details

Defined in Language.LSP.Types.Lens

HasProperties CompletionItemResolveClientCapabilities (List Text) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector CodeActionRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector CompletionRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector DocumentColorRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector CallHierarchyRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector CodeLensRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector DeclarationRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector DefinitionRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector DocumentHighlightRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector DocumentLinkRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector DocumentSymbolRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector FoldingRangeRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector DocumentOnTypeFormattingRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector DocumentRangeFormattingRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector DocumentFormattingRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector HoverRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector ImplementationRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector ReferenceRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector RenameRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector SelectionRangeRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector SignatureHelpRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector TypeDefinitionRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector TextDocumentSaveRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector TextDocumentChangeRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasDocumentSelector TextDocumentRegistrationOptions (Maybe DocumentSelector) 
Instance details

Defined in Language.LSP.Types.Lens

HasTriggerCharacters SignatureHelpRegistrationOptions (Maybe (List Text)) 
Instance details

Defined in Language.LSP.Types.Lens

HasTriggerCharacters SignatureHelpOptions (Maybe (List Text)) 
Instance details

Defined in Language.LSP.Types.Lens

HasAdditionalTextEdits CompletionItem (Maybe (List TextEdit)) 
Instance details

Defined in Language.LSP.Types.Lens

HasAdditionalTextEdits ColorPresentation (Maybe (List TextEdit)) 
Instance details

Defined in Language.LSP.Types.Lens

HasCommitCharacters CompletionItem (Maybe (List Text)) 
Instance details

Defined in Language.LSP.Types.Lens

HasTags CompletionItem (Maybe (List CompletionItemTag)) 
Instance details

Defined in Language.LSP.Types.Lens

HasTags CallHierarchyItem (Maybe (List SymbolTag)) 
Instance details

Defined in Language.LSP.Types.Lens

HasTags Diagnostic (Maybe (List DiagnosticTag)) 
Instance details

Defined in Language.LSP.Types.Lens

HasTags SymbolInformation (Maybe (List SymbolTag)) 
Instance details

Defined in Language.LSP.Types.Lens

HasTags DocumentSymbol (Maybe (List SymbolTag)) 
Instance details

Defined in Language.LSP.Types.Lens

HasXdata SemanticTokensEdit (Maybe (List UInt)) 
Instance details

Defined in Language.LSP.Types.Lens

HasXdata SemanticTokensPartialResult (List UInt) 
Instance details

Defined in Language.LSP.Types.Lens

HasXdata SemanticTokens (List UInt) 
Instance details

Defined in Language.LSP.Types.Lens

HasValueSet WorkspaceSymbolKindClientCapabilities (Maybe (List SymbolKind)) 
Instance details

Defined in Language.LSP.Types.Lens

HasValueSet CodeActionKindClientCapabilities (List CodeActionKind) 
Instance details

Defined in Language.LSP.Types.Lens

HasValueSet CompletionItemKindClientCapabilities (Maybe (List CompletionItemKind)) 
Instance details

Defined in Language.LSP.Types.Lens

HasValueSet CompletionItemInsertTextModeClientCapabilities (List InsertTextMode) 
Instance details

Defined in Language.LSP.Types.Lens

HasValueSet CompletionItemTagsClientCapabilities (List CompletionItemTag) 
Instance details

Defined in Language.LSP.Types.Lens

HasValueSet PublishDiagnosticsTagsClientCapabilities (List DiagnosticTag) 
Instance details

Defined in Language.LSP.Types.Lens

HasValueSet DocumentSymbolKindClientCapabilities (Maybe (List SymbolKind)) 
Instance details

Defined in Language.LSP.Types.Lens

HasChanges WorkspaceEdit (Maybe WorkspaceEditMap) 
Instance details

Defined in Language.LSP.Types.Lens

HasChanges DidChangeWatchedFilesParams (List FileEvent) 
Instance details

Defined in Language.LSP.Types.Lens

HasWatchers DidChangeWatchedFilesRegistrationOptions (List FileSystemWatcher) 
Instance details

Defined in Language.LSP.Types.Lens

HasItems CompletionList (List CompletionItem) 
Instance details

Defined in Language.LSP.Types.Lens

HasItems ConfigurationParams (List ConfigurationItem) 
Instance details

Defined in Language.LSP.Types.Lens

HasParameters SignatureInformation (Maybe (List ParameterInformation)) 
Instance details

Defined in Language.LSP.Types.Lens

HasUnregisterations UnregistrationParams (List Unregistration) 
Instance details

Defined in Language.LSP.Types.Lens

HasRegistrations RegistrationParams (List SomeRegistration) 
Instance details

Defined in Language.LSP.Types.Lens

HasWorkspaceFolders InitializeParams (Maybe (List WorkspaceFolder)) 
Instance details

Defined in Language.LSP.Types.Lens

HasRetryOnContentModified StaleRequestClientCapabilities (List Text) 
Instance details

Defined in Language.LSP.Types.Lens

Eq a => Eq (List a) 
Instance details

Defined in Language.LSP.Types.Common

Methods

(==) :: List a -> List a -> Bool #

(/=) :: List a -> List a -> Bool #

Ord a => Ord (List a) 
Instance details

Defined in Language.LSP.Types.Common

Methods

compare :: List a -> List a -> Ordering #

(<) :: List a -> List a -> Bool #

(<=) :: List a -> List a -> Bool #

(>) :: List a -> List a -> Bool #

(>=) :: List a -> List a -> Bool #

max :: List a -> List a -> List a #

min :: List a -> List a -> List a #

Read a => Read (List a) 
Instance details

Defined in Language.LSP.Types.Common

Show a => Show (List a) 
Instance details

Defined in Language.LSP.Types.Common

Methods

showsPrec :: Int -> List a -> ShowS #

show :: List a -> String #

showList :: [List a] -> ShowS #

Generic (List a) 
Instance details

Defined in Language.LSP.Types.Common

Associated Types

type Rep (List a) :: Type -> Type #

Methods

from :: List a -> Rep (List a) x #

to :: Rep (List a) x -> List a #

Semigroup (List a) 
Instance details

Defined in Language.LSP.Types.Common

Methods

(<>) :: List a -> List a -> List a #

sconcat :: NonEmpty (List a) -> List a #

stimes :: Integral b => b -> List a -> List a #

Monoid (List a) 
Instance details

Defined in Language.LSP.Types.Common

Methods

mempty :: List a #

mappend :: List a -> List a -> List a #

mconcat :: [List a] -> List a #

ToJSON a => ToJSON (List a) 
Instance details

Defined in Language.LSP.Types.Common

FromJSON a => FromJSON (List a) 
Instance details

Defined in Language.LSP.Types.Common

NFData a => NFData (List a) 
Instance details

Defined in Language.LSP.Types.Common

Methods

rnf :: List a -> () #

type Rep (List a) 
Instance details

Defined in Language.LSP.Types.Common

type Rep (List a) = D1 ('MetaData "List" "Language.LSP.Types.Common" "lsp-types-1.4.0.1-2rh5K3u4z9UBFaccFshq5a" 'True) (C1 ('MetaCons "List" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [a])))

uriToFilePath' :: Uri -> Maybe FilePath Source #

We use an empty string as a filepath when we don’t have a file. However, haskell-lsp doesn’t support that in uriToFilePath and given that it is not a valid filepath it does not make sense to upstream a fix. So we have our own wrapper here that supports empty filepaths.

readSrcSpan :: ReadS RealSrcSpan Source #

Parser for the GHC output format

type FileDiagnostic = (NormalizedFilePath, ShowDiagnostic, Diagnostic) Source #

Human readable diagnostics for a specific file.

This type packages a pretty printed, human readable error message along with the related source location so that we can display the error on either the console or in the IDE at the right source location.

data ShowDiagnostic Source #

Defines whether a particular diagnostic should be reported back to the user.

One important use case is "missing signature" code lenses, for which we need to enable the corresponding warning during type checking. However, we do not want to show the warning unless the programmer asks for it (#261).

Constructors

ShowDiag

Report back to the user

HideDiag

Hide from user

type IdeResultNoDiagnosticsEarlyCutoff v = (Maybe ByteString, Maybe v) Source #

an IdeResult with a fingerprint

type IdeResult v = ([FileDiagnostic], Maybe v) Source #

The result of an IDE operation. Warnings and errors are in the Diagnostic, and a value is in the Maybe. For operations that throw an error you expect a non-empty list of diagnostics, at least one of which is an error, and a Nothing. For operations that succeed you expect perhaps some warnings and a Just. For operations that depend on other failing operations you may get empty diagnostics and a Nothing, to indicate this phase throws no fresh errors but still failed.

A rule on a file should only return diagnostics for that given file. It should not propagate diagnostic errors through multiple phases.

modifyDynFlags :: GhcMonad m => (DynFlags -> DynFlags) -> m () Source #

Used to modify dyn flags in preference to calling setSessionDynFlags, since that function also reloads packages (which is very slow).

lookupPackageConfig :: Unit -> HscEnv -> Maybe UnitInfo Source #

Given a Unit try and find the associated PackageConfig in the environment.

textToStringBuffer :: Text -> StringBuffer Source #

Convert from the text package to the GHC StringBuffer. Currently implemented somewhat inefficiently (if it ever comes up in a profile).

prettyPrint :: Outputable a => a -> String Source #

Pretty print a GHC value using 'unsafeGlobalDynFlags '.

printRdrName :: RdrName -> String Source #

Pretty print a RdrName wrapping operators in parens

printName :: Name -> String Source #

Pretty print a Name wrapping operators in parens

evalGhcEnv :: HscEnv -> Ghc b -> IO b Source #

Run a Ghc monad value using an existing HscEnv. Sets up and tears down all the required pieces, but designed to be more efficient than a standard runGhc.

moduleImportPath :: NormalizedFilePath -> ModuleName -> Maybe FilePath Source #

Given a module location, and its parse tree, figure out what is the include directory implied by it. For example, given the file /usr/Test/Foo/Bar.hs with the module name Foo.Bar the directory /usr/Test should be on the include path to find sibling modules.

readFileUtf8 :: FilePath -> IO Text Source #

Read a UTF8 file, with lenient decoding, so it will never raise a decoding error.

fingerprintToBS :: Fingerprint -> ByteString Source #

Convert a Fingerprint to a ByteString by copying the byte across. Will produce an 8 byte unreadable ByteString.

hDuplicateTo' :: Handle -> Handle -> IO () Source #

A slightly modified version of hDuplicateTo from GHC. Importantly, it avoids the bug listed in https://gitlab.haskell.org/ghc/ghc/merge_requests/2318.

traceAst :: (Data a, ExactPrint a, Outputable a, HasCallStack) => String -> a -> a Source #

Prints an Outputable value to stderr and to an HTML file for further inspection

diagFromErrMsg :: Text -> DynFlags -> MsgEnvelope DecoratedSDoc -> [FileDiagnostic] Source #

Produce a GHC-style error from a source span and a message.

srcSpanToRange :: SrcSpan -> Maybe Range Source #

Convert a GHC SrcSpan to a DAML compiler Range

srcSpanToFilename :: SrcSpan -> Maybe FilePath Source #

Extract a file name from a GHC SrcSpan (use message for unhelpful ones) FIXME This may not be an _absolute_ file name, needs fixing.

toDSeverity :: Severity -> Maybe DiagnosticSeverity Source #

Convert a GHC severity to a DAML compiler Severity. Severities below Warning level are dropped (returning Nothing).

diagFromStrings :: Text -> DiagnosticSeverity -> [(SrcSpan, String)] -> [FileDiagnostic] Source #

Produce a bag of GHC-style errors (ErrorMessages) from the given (optional) locations and message strings.

diagFromString :: Text -> DiagnosticSeverity -> SrcSpan -> String -> [FileDiagnostic] Source #

Produce a GHC-style error from a source span and a message.

noSpan :: String -> SrcSpan Source #

Produces an "unhelpful" source span with the given string.

zeroSpan Source #

Arguments

:: FastString

file path of span

-> RealSrcSpan 

creates a span with zero length in the filename of the argument passed

catchSrcErrors :: DynFlags -> Text -> IO a -> IO (Either [FileDiagnostic] a) Source #

Catch the errors thrown by GHC (SourceErrors and compiler-internal exceptions like Panic or InstallationError), and turn them into diagnostics

newtype Logger Source #

Note that this is logging actions _of the program_, not of the user. You shouldn't call warning/error if the user has caused an error, only if our code has gone wrong and is itself erroneous (e.g. we threw an exception).

Constructors

Logger 

Fields

Instances

Instances details
Semigroup Logger Source # 
Instance details

Defined in Development.IDE.Types.Logger

Monoid Logger Source # 
Instance details

Defined in Development.IDE.Types.Logger

data Priority Source #

Constructors

Telemetry

Events that are useful for gathering user metrics.

Debug

Verbose debug logging.

Info

Useful information in case an error has to be understood.

Warning

These error messages should not occur in a expected usage, and should be investigated.

Error

Such log messages must never occur in expected usage.

data HscEnvEq Source #

An HscEnv with equality. Two values are considered equal if they are created with the same call to newHscEnvEq.

Instances

Instances details
Eq HscEnvEq Source # 
Instance details

Defined in Development.IDE.Types.HscEnvEq

Show HscEnvEq Source # 
Instance details

Defined in Development.IDE.Types.HscEnvEq

Hashable HscEnvEq Source # 
Instance details

Defined in Development.IDE.Types.HscEnvEq

Methods

hashWithSalt :: Int -> HscEnvEq -> Int #

hash :: HscEnvEq -> Int #

NFData HscEnvEq Source # 
Instance details

Defined in Development.IDE.Types.HscEnvEq

Methods

rnf :: HscEnvEq -> () #

hscEnvWithImportPaths :: HscEnvEq -> HscEnv Source #

Unwrap the HscEnv with the original import paths. Used only for locating imports

data GhcSessionIO Source #

Constructors

GhcSessionIO 

Instances

Instances details
Eq GhcSessionIO Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GhcSessionIO Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GhcSessionIO Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GhcSessionIO :: Type -> Type #

Hashable GhcSessionIO Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GhcSessionIO Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GhcSessionIO -> () #

type Rep GhcSessionIO Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GhcSessionIO = D1 ('MetaData "GhcSessionIO" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GhcSessionIO" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GhcSessionIO Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

data IdeGhcSession Source #

Constructors

IdeGhcSession 

Fields

Instances

Instances details
Show IdeGhcSession Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData IdeGhcSession Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: IdeGhcSession -> () #

data AddWatchedFile Source #

Constructors

AddWatchedFile 

Instances

Instances details
Eq AddWatchedFile Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show AddWatchedFile Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic AddWatchedFile Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep AddWatchedFile :: Type -> Type #

Hashable AddWatchedFile Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData AddWatchedFile Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: AddWatchedFile -> () #

type Rep AddWatchedFile Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep AddWatchedFile = D1 ('MetaData "AddWatchedFile" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "AddWatchedFile" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult AddWatchedFile Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

data GetClientSettings Source #

Get the vscode client settings stored in the ide state

Constructors

GetClientSettings 

Instances

Instances details
Eq GetClientSettings Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetClientSettings Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetClientSettings Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetClientSettings :: Type -> Type #

Hashable GetClientSettings Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetClientSettings Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GetClientSettings -> () #

type Rep GetClientSettings Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetClientSettings = D1 ('MetaData "GetClientSettings" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetClientSettings" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetClientSettings Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

data GetModSummary Source #

Constructors

GetModSummary 

Instances

Instances details
Eq GetModSummary Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetModSummary Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetModSummary Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetModSummary :: Type -> Type #

Hashable GetModSummary Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetModSummary Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GetModSummary -> () #

type Rep GetModSummary Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetModSummary = D1 ('MetaData "GetModSummary" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetModSummary" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetModSummary Source #

Generate a ModSummary that has enough information to be used to get .hi and .hie files. without needing to parse the entire source

Instance details

Defined in Development.IDE.Core.RuleTypes

data GetModSummaryWithoutTimestamps Source #

Instances

Instances details
Eq GetModSummaryWithoutTimestamps Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetModSummaryWithoutTimestamps Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetModSummaryWithoutTimestamps Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetModSummaryWithoutTimestamps :: Type -> Type #

Hashable GetModSummaryWithoutTimestamps Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetModSummaryWithoutTimestamps Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetModSummaryWithoutTimestamps Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetModSummaryWithoutTimestamps = D1 ('MetaData "GetModSummaryWithoutTimestamps" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetModSummaryWithoutTimestamps" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetModSummaryWithoutTimestamps Source #

Generate a ModSummary with the timestamps and preprocessed content elided, for more successful early cutoff

Instance details

Defined in Development.IDE.Core.RuleTypes

data IsFileOfInterest Source #

Constructors

IsFileOfInterest 

Instances

Instances details
Eq IsFileOfInterest Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show IsFileOfInterest Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic IsFileOfInterest Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep IsFileOfInterest :: Type -> Type #

Hashable IsFileOfInterest Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData IsFileOfInterest Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: IsFileOfInterest -> () #

type Rep IsFileOfInterest Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep IsFileOfInterest = D1 ('MetaData "IsFileOfInterest" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "IsFileOfInterest" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult IsFileOfInterest Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

data GetModIface Source #

Constructors

GetModIface 

Instances

Instances details
Eq GetModIface Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetModIface Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetModIface Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetModIface :: Type -> Type #

Hashable GetModIface Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetModIface Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GetModIface -> () #

type Rep GetModIface Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetModIface = D1 ('MetaData "GetModIface" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetModIface" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetModIface Source #

Get a module interface details, either from an interface file or a typechecked module

Instance details

Defined in Development.IDE.Core.RuleTypes

data GetModIfaceFromDiskAndIndex Source #

Instances

Instances details
Eq GetModIfaceFromDiskAndIndex Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetModIfaceFromDiskAndIndex Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetModIfaceFromDiskAndIndex Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetModIfaceFromDiskAndIndex :: Type -> Type #

Hashable GetModIfaceFromDiskAndIndex Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetModIfaceFromDiskAndIndex Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetModIfaceFromDiskAndIndex Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetModIfaceFromDiskAndIndex = D1 ('MetaData "GetModIfaceFromDiskAndIndex" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetModIfaceFromDiskAndIndex" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetModIfaceFromDiskAndIndex Source #

GetModIfaceFromDisk and index the `.hie` file into the database. This is an internal rule, use GetModIface instead.

Instance details

Defined in Development.IDE.Core.RuleTypes

data GetModIfaceFromDisk Source #

Constructors

GetModIfaceFromDisk 

Instances

Instances details
Eq GetModIfaceFromDisk Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetModIfaceFromDisk Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetModIfaceFromDisk Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetModIfaceFromDisk :: Type -> Type #

Hashable GetModIfaceFromDisk Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetModIfaceFromDisk Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GetModIfaceFromDisk -> () #

type Rep GetModIfaceFromDisk Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetModIfaceFromDisk = D1 ('MetaData "GetModIfaceFromDisk" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetModIfaceFromDisk" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetModIfaceFromDisk Source #

Read the module interface file from disk. Throws an error for VFS files. This is an internal rule, use GetModIface instead.

Instance details

Defined in Development.IDE.Core.RuleTypes

newtype GhcSessionDeps Source #

Constructors

GhcSessionDeps_ 

Fields

  • fullModSummary :: Bool

    Load full ModSummary values in the GHC session. Required for interactive evaluation, but leads to more cache invalidations

Bundled Patterns

pattern GhcSessionDeps :: GhcSessionDeps 

Instances

Instances details
Eq GhcSessionDeps Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GhcSessionDeps Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Hashable GhcSessionDeps Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GhcSessionDeps Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GhcSessionDeps -> () #

type RuleResult GhcSessionDeps Source #

A GHC session preloaded with all the dependencies This rule is also responsible for calling ReportImportCycles for the direct dependencies

Instance details

Defined in Development.IDE.Core.RuleTypes

data GhcSession Source #

Constructors

GhcSession 

Instances

Instances details
Eq GhcSession Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GhcSession Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GhcSession Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GhcSession :: Type -> Type #

Hashable GhcSession Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GhcSession Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GhcSession -> () #

type Rep GhcSession Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GhcSession = D1 ('MetaData "GhcSession" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GhcSession" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GhcSession Source #

A GHC session that we reuse.

Instance details

Defined in Development.IDE.Core.RuleTypes

data GetBindings Source #

Constructors

GetBindings 

Instances

Instances details
Eq GetBindings Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetBindings Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetBindings Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetBindings :: Type -> Type #

Hashable GetBindings Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetBindings Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GetBindings -> () #

type Rep GetBindings Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetBindings = D1 ('MetaData "GetBindings" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetBindings" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetBindings Source #

A IntervalMap telling us what is in scope at each point

Instance details

Defined in Development.IDE.Core.RuleTypes

data GetHieAst Source #

Constructors

GetHieAst 

Instances

Instances details
Eq GetHieAst Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetHieAst Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetHieAst Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetHieAst :: Type -> Type #

Hashable GetHieAst Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetHieAst Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GetHieAst -> () #

type Rep GetHieAst Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetHieAst = D1 ('MetaData "GetHieAst" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetHieAst" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetHieAst Source #

The uncompressed HieAST

Instance details

Defined in Development.IDE.Core.RuleTypes

data GetDocMap Source #

Constructors

GetDocMap 

Instances

Instances details
Eq GetDocMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetDocMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetDocMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetDocMap :: Type -> Type #

Hashable GetDocMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetDocMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GetDocMap -> () #

type Rep GetDocMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetDocMap = D1 ('MetaData "GetDocMap" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetDocMap" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetDocMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

data TypeCheck Source #

Constructors

TypeCheck 

Instances

Instances details
Eq TypeCheck Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show TypeCheck Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic TypeCheck Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep TypeCheck :: Type -> Type #

Hashable TypeCheck Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData TypeCheck Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: TypeCheck -> () #

type Rep TypeCheck Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep TypeCheck = D1 ('MetaData "TypeCheck" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "TypeCheck" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult TypeCheck Source #

The type checked version of this file, requires TypeCheck+

Instance details

Defined in Development.IDE.Core.RuleTypes

data ReportImportCycles Source #

Constructors

ReportImportCycles 

Instances

Instances details
Eq ReportImportCycles Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show ReportImportCycles Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic ReportImportCycles Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep ReportImportCycles :: Type -> Type #

Hashable ReportImportCycles Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData ReportImportCycles Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: ReportImportCycles -> () #

type Rep ReportImportCycles Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep ReportImportCycles = D1 ('MetaData "ReportImportCycles" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "ReportImportCycles" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult ReportImportCycles Source #

This rule is used to report import cycles. It depends on GetDependencyInformation. We cannot report the cycles directly from GetDependencyInformation since we can only report diagnostics for the current file.

Instance details

Defined in Development.IDE.Core.RuleTypes

data GetModuleGraph Source #

Constructors

GetModuleGraph 

Instances

Instances details
Eq GetModuleGraph Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetModuleGraph Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetModuleGraph Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetModuleGraph :: Type -> Type #

Hashable GetModuleGraph Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetModuleGraph Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GetModuleGraph -> () #

type Rep GetModuleGraph Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetModuleGraph = D1 ('MetaData "GetModuleGraph" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetModuleGraph" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetModuleGraph Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

data GetDependencyInformation Source #

Instances

Instances details
Eq GetDependencyInformation Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetDependencyInformation Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetDependencyInformation Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetDependencyInformation :: Type -> Type #

Hashable GetDependencyInformation Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetDependencyInformation Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetDependencyInformation Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetDependencyInformation = D1 ('MetaData "GetDependencyInformation" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetDependencyInformation" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetDependencyInformation Source #

The dependency information produced by following the imports recursively. This rule will succeed even if there is an error, e.g., a module could not be located, a module could not be parsed or an import cycle.

Instance details

Defined in Development.IDE.Core.RuleTypes

data NeedsCompilation Source #

Constructors

NeedsCompilation 

Instances

Instances details
Eq NeedsCompilation Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show NeedsCompilation Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic NeedsCompilation Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep NeedsCompilation :: Type -> Type #

Hashable NeedsCompilation Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData NeedsCompilation Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: NeedsCompilation -> () #

type Rep NeedsCompilation Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep NeedsCompilation = D1 ('MetaData "NeedsCompilation" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "NeedsCompilation" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult NeedsCompilation Source #

Does this module need to be compiled?

Instance details

Defined in Development.IDE.Core.RuleTypes

data GetLocatedImports Source #

Constructors

GetLocatedImports 

Instances

Instances details
Eq GetLocatedImports Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetLocatedImports Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetLocatedImports Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetLocatedImports :: Type -> Type #

Hashable GetLocatedImports Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetLocatedImports Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GetLocatedImports -> () #

type Rep GetLocatedImports Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetLocatedImports = D1 ('MetaData "GetLocatedImports" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetLocatedImports" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetLocatedImports Source #

Resolve the imports in a module to the file path of a module in the same package

Instance details

Defined in Development.IDE.Core.RuleTypes

data GetParsedModuleWithComments Source #

Instances

Instances details
Eq GetParsedModuleWithComments Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetParsedModuleWithComments Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetParsedModuleWithComments Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetParsedModuleWithComments :: Type -> Type #

Hashable GetParsedModuleWithComments Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetParsedModuleWithComments Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetParsedModuleWithComments Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetParsedModuleWithComments = D1 ('MetaData "GetParsedModuleWithComments" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetParsedModuleWithComments" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetParsedModuleWithComments Source #

The parse tree for the file using GetFileContents, all comments included using Opt_KeepRawTokenStream

Instance details

Defined in Development.IDE.Core.RuleTypes

data GetParsedModule Source #

Constructors

GetParsedModule 

Instances

Instances details
Eq GetParsedModule Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetParsedModule Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetParsedModule Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetParsedModule :: Type -> Type #

Hashable GetParsedModule Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetParsedModule Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GetParsedModule -> () #

type Rep GetParsedModule Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetParsedModule = D1 ('MetaData "GetParsedModule" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetParsedModule" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetParsedModule Source #

The parse tree for the file using GetFileContents

Instance details

Defined in Development.IDE.Core.RuleTypes

data IsFileOfInterestResult Source #

Instances

Instances details
Eq IsFileOfInterestResult Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show IsFileOfInterestResult Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic IsFileOfInterestResult Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep IsFileOfInterestResult :: Type -> Type #

Hashable IsFileOfInterestResult Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData IsFileOfInterestResult Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: IsFileOfInterestResult -> () #

type Rep IsFileOfInterestResult Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep IsFileOfInterestResult = D1 ('MetaData "IsFileOfInterestResult" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "NotFOI" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "IsFOI" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 FileOfInterestStatus)))

data FileOfInterestStatus Source #

Constructors

OnDisk 
Modified 

Fields

Instances

Instances details
Eq FileOfInterestStatus Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show FileOfInterestStatus Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic FileOfInterestStatus Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep FileOfInterestStatus :: Type -> Type #

Hashable FileOfInterestStatus Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData FileOfInterestStatus Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: FileOfInterestStatus -> () #

type Rep FileOfInterestStatus Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep FileOfInterestStatus = D1 ('MetaData "FileOfInterestStatus" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "OnDisk" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Modified" 'PrefixI 'True) (S1 ('MetaSel ('Just "firstOpen") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Bool)))

data GetFileExists Source #

Constructors

GetFileExists 

Instances

Instances details
Eq GetFileExists Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetFileExists Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetFileExists Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetFileExists :: Type -> Type #

Hashable GetFileExists Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetFileExists Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GetFileExists -> () #

type Rep GetFileExists Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetFileExists = D1 ('MetaData "GetFileExists" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetFileExists" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetFileExists Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

data GetFileContents Source #

Constructors

GetFileContents 

Instances

Instances details
Eq GetFileContents Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetFileContents Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetFileContents Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetFileContents :: Type -> Type #

Hashable GetFileContents Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetFileContents Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GetFileContents -> () #

type Rep GetFileContents Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetFileContents = D1 ('MetaData "GetFileContents" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetFileContents" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetFileContents Source #

Get the contents of a file, either dirty (if the buffer is modified) or Nothing to mean use from disk.

Instance details

Defined in Development.IDE.Core.RuleTypes

data FileVersion Source #

Instances

Instances details
Show FileVersion Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic FileVersion Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep FileVersion :: Type -> Type #

NFData FileVersion Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: FileVersion -> () #

type Rep FileVersion Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep FileVersion = D1 ('MetaData "FileVersion" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "VFSVersion" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Int32)) :+: C1 ('MetaCons "ModificationTime" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 POSIXTime)))

newtype GetModificationTime Source #

Constructors

GetModificationTime_ 

Fields

Instances

Instances details
Eq GetModificationTime Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetModificationTime Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetModificationTime Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetModificationTime :: Type -> Type #

Hashable GetModificationTime Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetModificationTime Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GetModificationTime -> () #

type Rep GetModificationTime Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetModificationTime = D1 ('MetaData "GetModificationTime" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'True) (C1 ('MetaCons "GetModificationTime_" 'PrefixI 'True) (S1 ('MetaSel ('Just "missingFileDiagnostics") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Bool)))
type RuleResult GetModificationTime Source #

Get the modification time of a file.

Instance details

Defined in Development.IDE.Core.RuleTypes

data DocAndKindMap Source #

Constructors

DKMap 

Instances

Instances details
Show DocAndKindMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData DocAndKindMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: DocAndKindMap -> () #

data HieKind a where Source #

Instances

Instances details
NFData (HieKind a) Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: HieKind a -> () #

data HieAstResult Source #

Save the uncompressed AST here, we compress it just before writing to disk

Constructors

forall a. HAR 

Fields

Instances

Instances details
Show HieAstResult Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData HieAstResult Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: HieAstResult -> () #

data HiFileResult Source #

Constructors

HiFileResult 

Fields

Instances

Instances details
Show HiFileResult Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData HiFileResult Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: HiFileResult -> () #

data TcModuleResult Source #

Contains the typechecked module and the OrigNameCache entry for that module.

Constructors

TcModuleResult 

Fields

Instances

Instances details
Show TcModuleResult Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData TcModuleResult Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: TcModuleResult -> () #

newtype ImportMap Source #

Constructors

ImportMap 

Fields

Instances

Instances details
Show ImportMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData ImportMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: ImportMap -> () #

data GetImportMap Source #

Constructors

GetImportMap 

Instances

Instances details
Eq GetImportMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetImportMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetImportMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetImportMap :: Type -> Type #

Hashable GetImportMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetImportMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GetImportMap -> () #

type Rep GetImportMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetImportMap = D1 ('MetaData "GetImportMap" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetImportMap" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetImportMap Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

data GenerateCore Source #

Constructors

GenerateCore 

Instances

Instances details
Eq GenerateCore Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GenerateCore Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GenerateCore Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GenerateCore :: Type -> Type #

Hashable GenerateCore Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GenerateCore Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GenerateCore -> () #

type Rep GenerateCore Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GenerateCore = D1 ('MetaData "GenerateCore" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GenerateCore" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GenerateCore Source #

Convert to Core, requires TypeCheck*

Instance details

Defined in Development.IDE.Core.RuleTypes

data GetKnownTargets Source #

Constructors

GetKnownTargets 

Instances

Instances details
Eq GetKnownTargets Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Ord GetKnownTargets Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show GetKnownTargets Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic GetKnownTargets Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep GetKnownTargets :: Type -> Type #

Hashable GetKnownTargets Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData GetKnownTargets Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: GetKnownTargets -> () #

type Rep GetKnownTargets Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep GetKnownTargets = D1 ('MetaData "GetKnownTargets" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "GetKnownTargets" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetKnownTargets Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

data LinkableType Source #

Instances

Instances details
Eq LinkableType Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Ord LinkableType Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Show LinkableType Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Generic LinkableType Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Associated Types

type Rep LinkableType :: Type -> Type #

Hashable LinkableType Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

NFData LinkableType Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

Methods

rnf :: LinkableType -> () #

type Rep LinkableType Source # 
Instance details

Defined in Development.IDE.Core.RuleTypes

type Rep LinkableType = D1 ('MetaData "LinkableType" "Development.IDE.Core.RuleTypes" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "ObjectLinkable" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "BCOLinkable" 'PrefixI 'False) (U1 :: Type -> Type))

encodeLinkableType :: Maybe LinkableType -> ByteString Source #

Encode the linkable into an ordered bytestring. This is used to drive an ordered "newness" predicate in the NeedsCompilation build rule.

data FastResult a Source #

A (maybe) stale result now, and an up to date one later

Constructors

FastResult 

Fields

newtype IdeAction a Source #

IdeActions are used when we want to return a result immediately, even if it is stale Useful for UI actions like hover, completion where we don't want to block.

Run via runIdeAction.

Constructors

IdeAction 

Instances

Instances details
Monad IdeAction Source # 
Instance details

Defined in Development.IDE.Core.Shake

Methods

(>>=) :: IdeAction a -> (a -> IdeAction b) -> IdeAction b #

(>>) :: IdeAction a -> IdeAction b -> IdeAction b #

return :: a -> IdeAction a #

Functor IdeAction Source # 
Instance details

Defined in Development.IDE.Core.Shake

Methods

fmap :: (a -> b) -> IdeAction a -> IdeAction b #

(<$) :: a -> IdeAction b -> IdeAction a #

Applicative IdeAction Source # 
Instance details

Defined in Development.IDE.Core.Shake

Methods

pure :: a -> IdeAction a #

(<*>) :: IdeAction (a -> b) -> IdeAction a -> IdeAction b #

liftA2 :: (a -> b -> c) -> IdeAction a -> IdeAction b -> IdeAction c #

(*>) :: IdeAction a -> IdeAction b -> IdeAction b #

(<*) :: IdeAction a -> IdeAction b -> IdeAction a #

MonadIO IdeAction Source # 
Instance details

Defined in Development.IDE.Core.Shake

Methods

liftIO :: IO a -> IdeAction a #

MonadReader ShakeExtras IdeAction Source # 
Instance details

Defined in Development.IDE.Core.Shake

data IdeState Source #

A Shake database plus persistent store. Can be thought of as storing mappings from (FilePath, k) to RuleResult k.

type IdeRule k v = (RuleResult k ~ v, ShakeValue k, Show v, Typeable v, NFData v) Source #

data ShakeExtras Source #

Instances

Instances details
MonadReader ShakeExtras IdeAction Source # 
Instance details

Defined in Development.IDE.Core.Shake

define :: IdeRule k v => (k -> NormalizedFilePath -> Action (IdeResult v)) -> Rules () Source #

Define a new Rule without early cutoff

use :: IdeRule k v => k -> NormalizedFilePath -> Action (Maybe v) Source #

Request a Rule result if available

useWithStale :: IdeRule k v => k -> NormalizedFilePath -> Action (Maybe (v, PositionMapping)) Source #

Request a Rule result, it not available return the last computed result, if any, which may be stale

useWithStale_ :: IdeRule k v => k -> NormalizedFilePath -> Action (v, PositionMapping) Source #

Request a Rule result, it not available return the last computed result which may be stale. Errors out if none available.

useWithStaleFast :: IdeRule k v => k -> NormalizedFilePath -> IdeAction (Maybe (v, PositionMapping)) Source #

Lookup value in the database and return with the stale value immediately Will queue an action to refresh the value. Might block the first time the rule runs, but never blocks after that.

useWithStaleFast' :: IdeRule k v => k -> NormalizedFilePath -> IdeAction (FastResult v) Source #

Same as useWithStaleFast but lets you wait for an up to date result

useNoFile :: IdeRule k v => k -> Action (Maybe v) Source #

useNoFile_ :: IdeRule k v => k -> Action v Source #

uses_ :: IdeRule k v => k -> [NormalizedFilePath] -> Action [v] Source #

uses :: IdeRule k v => k -> [NormalizedFilePath] -> Action [Maybe v] Source #

Plural version of use

defineEarlyCutoff :: IdeRule k v => RuleBody k v -> Rules () Source #

Define a new Rule with early cutoff

data Plugin c Source #

Instances

Instances details
Semigroup (Plugin c) Source # 
Instance details

Defined in Development.IDE.Plugin

Methods

(<>) :: Plugin c -> Plugin c -> Plugin c #

sconcat :: NonEmpty (Plugin c) -> Plugin c #

stimes :: Integral b => b -> Plugin c -> Plugin c #

Monoid (Plugin c) Source # 
Instance details

Defined in Development.IDE.Plugin

Methods

mempty :: Plugin c #

mappend :: Plugin c -> Plugin c -> Plugin c #

mconcat :: [Plugin c] -> Plugin c #

Default (Plugin c) Source # 
Instance details

Defined in Development.IDE.Plugin

Methods

def :: Plugin c #

data IdeConfiguration Source #

Lsp client relevant configuration details

getFileContents :: NormalizedFilePath -> Action (UTCTime, Maybe Text) Source #

Returns the modification time and the contents. For VFS paths, the modification time is the current time.

getFileExists :: NormalizedFilePath -> Action Bool Source #

Returns True if the file exists Note that a file is not considered to exist unless it is saved to disk. In particular, VFS existence is not enough. Consider the following example: 1. The file A.hs containing the line import B is added to the files of interest Since B.hs is neither open nor exists, GetLocatedImports finds Nothing 2. The editor creates a new buffer B.hs Unless the editor also sends a DidChangeWatchedFile event, ghcide will not pick it up Most editors, e.g. VSCode, only send the event when the file is saved to disk.

getAtPoint :: NormalizedFilePath -> Position -> IdeAction (Maybe (Maybe Range, [Text])) Source #

Try to get hover text for the name under point.

useE :: IdeRule k v => k -> NormalizedFilePath -> MaybeT IdeAction (v, PositionMapping) Source #

useE is useful to implement functions that aren’t rules but need shortcircuiting e.g. getDefinition.

data IsHiFileStable Source #

Given the path to a module src file, this rule returns True if the corresponding `.hi` file is stable, that is, if it is newer than the src file, and all its dependencies are stable too.

Constructors

IsHiFileStable 

Instances

Instances details
Eq IsHiFileStable Source # 
Instance details

Defined in Development.IDE.Core.Rules

Show IsHiFileStable Source # 
Instance details

Defined in Development.IDE.Core.Rules

Generic IsHiFileStable Source # 
Instance details

Defined in Development.IDE.Core.Rules

Associated Types

type Rep IsHiFileStable :: Type -> Type #

Hashable IsHiFileStable Source # 
Instance details

Defined in Development.IDE.Core.Rules

NFData IsHiFileStable Source # 
Instance details

Defined in Development.IDE.Core.Rules

Methods

rnf :: IsHiFileStable -> () #

type Rep IsHiFileStable Source # 
Instance details

Defined in Development.IDE.Core.Rules

type Rep IsHiFileStable = D1 ('MetaData "IsHiFileStable" "Development.IDE.Core.Rules" "ghcide-1.6.0.0-6rn0EpOlTRZ4j4Z1t1BPzW" 'False) (C1 ('MetaCons "IsHiFileStable" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult IsHiFileStable Source # 
Instance details

Defined in Development.IDE.Core.Rules

getParsedModule :: NormalizedFilePath -> Action (Maybe ParsedModule) Source #

Parse the contents of a haskell file.

getClientConfigAction Source #

Arguments

:: Config

default value

-> Action Config 

Returns the client configurarion stored in the IdeState. You can use this function to access it from shake Rules