ghcide-2.4.0.0: The core of an IDE
Safe HaskellSafe-Inferred
LanguageHaskell2010

Development.IDE.Spans.LocalBindings

Synopsis

Documentation

data Bindings #

The available bindings at every point in a Haskell tree.

Instances

Instances details
Monoid Bindings # 
Instance details

Defined in Development.IDE.Spans.LocalBindings

Semigroup Bindings # 
Instance details

Defined in Development.IDE.Spans.LocalBindings

Methods

(<>) :: Bindings -> Bindings -> Bindings #

sconcat :: NonEmpty Bindings -> Bindings #

stimes :: Integral b => b -> Bindings -> Bindings #

Show Bindings # 
Instance details

Defined in Development.IDE.Spans.LocalBindings

Methods

showsPrec :: Int -> Bindings -> ShowS #

show :: Bindings -> String #

showList :: [Bindings] -> ShowS #

NFData Bindings # 
Instance details

Defined in Development.IDE.Spans.LocalBindings

Methods

rnf :: Bindings -> () #

getLocalScope :: Bindings -> RealSrcSpan -> [(Name, Maybe Type)] #

Given a Bindings get every identifier in scope at the given RealSrcSpan,

getFuzzyScope :: Bindings -> Position -> Position -> [(Name, Maybe Type)] #

Lookup all names in scope in any span that intersects the interval defined by the two positions. This is meant for use with the fuzzy PositionRange returned by PositionMapping

getDefiningBindings :: Bindings -> RealSrcSpan -> [(Name, Maybe Type)] #

Given a Bindings, get every binding currently active at a given RealSrcSpan,

getFuzzyDefiningBindings :: Bindings -> Position -> Position -> [(Name, Maybe Type)] #

Given a Bindings, get every binding that intersects the interval defined by the two positions. This is meant for use with the fuzzy PositionRange returned by PositionMapping

bindings :: RefMap Type -> Bindings #