HaRe-0.7.0.6: the Haskell Refactorer.

Safe HaskellNone

Language.Haskell.Refact.Utils.TokenUtilsTypes

Contents

Description

This module contains types shared between TokenUtils and Monad, and exists to break import cycles

Synopsis

The cache of trees comprising the manipulated tokens

data TokenCache Source

Constructors

TK 

data TreeId Source

Constructors

TId !Int 

Instances

mainTid :: TreeIdSource

Identifies the tree carrying the main tokens, not any work in progress or deleted ones

Structure of each tree

data Entry Source

An entry in the data structure for a particular srcspan.

Constructors

Entry !ForestSpan ![PosToken]

The tokens for the SrcSpan if subtree is empty

Deleted !ForestSpan SimpPos

The gap between this span end and the start of the next in the fringe of the tree.

Instances

data ForestLine Source

Constructors

ForestLine 

Fields

flSpanLengthChanged :: !Bool

The length of the span may have changed due to updated tokens.

flTreeSelector :: !Int
 
flInsertVersion :: !Int
 
flLine :: !Int
 

type ForestSpan = (ForestPos, ForestPos)Source

Match a SrcSpan, using a ForestLine as the marker