| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Language.Rzk.VSCode.ReferenceIndex
Synopsis
- data Uri = Uri {}
- data Position = Position {}
- data Range = Range {}
- data Location = Location {
- locationUri :: Uri
- locationRange :: Range
- data Binding = Binding {
- bindingName :: Text
- bindingDef :: Location
- bindingType :: Maybe Text
- bindingRefs :: [Location]
- data ReferenceIndex = ReferenceIndex {
- occurrences :: Map (FilePath, Int) [(Int, Int, Binding)]
- assumeSites :: Map Location AssumeScope
- indexModules :: [(FilePath, Module)] -> ReferenceIndex
- lookupAt :: ReferenceIndex -> Uri -> Position -> Maybe Binding
- bindingSites :: Binding -> [Location]
- locationPath :: Location -> FilePath
- fileOccurrences :: ReferenceIndex -> FilePath -> [(Binding, Int, Int, Int)]
- data AssumeScope
- assumeScopeAt :: ReferenceIndex -> Location -> Maybe AssumeScope
Documentation
Constructors
| Position | |
Fields
| |
Constructors
| Range | |
Fields
| |
Constructors
| Location | |
Fields
| |
Constructors
| Binding | |
Fields
| |
data ReferenceIndex Source #
Constructors
| ReferenceIndex | |
Fields
| |
Instances
| Show ReferenceIndex Source # | |
Defined in Language.Rzk.VSCode.ReferenceIndex Methods showsPrec :: Int -> ReferenceIndex -> ShowS # show :: ReferenceIndex -> String # showList :: [ReferenceIndex] -> ShowS # | |
indexModules :: [(FilePath, Module)] -> ReferenceIndex Source #
bindingSites :: Binding -> [Location] Source #
locationPath :: Location -> FilePath Source #
fileOccurrences :: ReferenceIndex -> FilePath -> [(Binding, Int, Int, Int)] Source #
Every occurrence recorded for a file, with the binding it resolves to: 0-based line and column span. Zero-width spans (the derived def entries of generated eliminators) are skipped; they occupy no characters.
data AssumeScope Source #
Where a name was #assumed.
Constructors
| AssumeTopLevel | outside any section: a file-wide axiom |
| AssumeInSection | inside a section: a hypothesis, discharged at |
Instances
| Show AssumeScope Source # | |
Defined in Language.Rzk.VSCode.ReferenceIndex Methods showsPrec :: Int -> AssumeScope -> ShowS # show :: AssumeScope -> String # showList :: [AssumeScope] -> ShowS # | |
| Eq AssumeScope Source # | |
Defined in Language.Rzk.VSCode.ReferenceIndex | |
assumeScopeAt :: ReferenceIndex -> Location -> Maybe AssumeScope Source #
The assume-scope of a definition site, if it is one of an #assumed
name. A local that shadows an assumption resolves to its own binder,
not to a site recorded here.