| Copyright | (c) Edward Kmett 2017 | 
|---|---|
| License | BSD2 | 
| Maintainer | Edward Kmett <ekmett@gmail.com> | 
| Stability | experimental | 
| Portability | non-portable | 
| Safe Haskell | None | 
| Language | Haskell2010 | 
Coda.Syntax.Dyck
Description
- data Dyck = Dyck !(Cat Closing) !(Cat Token) !(Rev Cat Opening) !(Cat Token) !LayoutMode !(Cat MismatchError)
- data Opening = Opening !LocatedPair !(Cat Token)
- data Closing = Closing !(Cat Token) !LocatedPair
- type LocatedPair = Located Pair
- data MismatchError = MismatchError !LocatedPair !LocatedPair
- token :: Dyck -> Token -> Dyck
- layoutToken :: Dyck -> LayoutMode -> Token -> Dyck
- close :: Dyck -> Located Pair -> Dyck
- open :: Dyck -> Located Pair -> Dyck
- spine :: Dyck -> Cat Token
Documentation
Dyck l ms r s k e
k indicates if the last token was a layout keyword, and if so can provide a
 numerical indicator as to which one. 0 means either no it wasn't or that we
 haven't seen a
Constructors
| Dyck !(Cat Closing) !(Cat Token) !(Rev Cat Opening) !(Cat Token) !LayoutMode !(Cat MismatchError) | 
Instances
| Eq Dyck Source # | |
| Ord Dyck Source # | |
| Read Dyck Source # | |
| Show Dyck Source # | |
| Generic Dyck Source # | |
| Semigroup Dyck Source # | O(k) in the number of canceled contexts Note: positions are not shifted, so you'll need to use this inside a semi-direct product with Delta. | 
| Monoid Dyck Source # | |
| Default Dyck Source # | |
| RelativeMonoid Dyck Source # | |
| Relative Dyck Source # | |
| type Rep Dyck Source # | |
Constructors
| Opening !LocatedPair !(Cat Token) | 
Constructors
| Closing !(Cat Token) !LocatedPair | 
type LocatedPair = Located Pair Source #
data MismatchError Source #
Constructors
| MismatchError !LocatedPair !LocatedPair | 
layoutToken :: Dyck -> LayoutMode -> Token -> Dyck Source #