@hackage tlex-th0.2.0.0
TemplateHaskell plugin for Tlex
Categories
License
(Apache-2.0 OR MPL-2.0)
Maintainer
mizunashi-mana@noreply.git
Links
Versions
Installation
CustomDependencies (7)
- array >=0.5.3 && <0.6
- base >=4.12.0 && <4.15
- containers >=0.6.0 && <0.7
- ghc-prim >=0.5.3 && <0.7
- template-haskell >=2.14.0 && <2.17.0
- tlex >=0.1.0 && <0.3 Show all…
Dependents (0)
Package Flags
develop
(off by default)
Turn on some options for development
Tlex Plugin: Template Haskell
See also https://hackage.haskell.org/package/tlex
Usage
This plugin outputs from Scanner these APIs:
-- aliases of arguments of @buildTHScanner@
type TlexStartState :: Type
type TlexSemanticAction :: Type
type TlexCodeUnit :: Type
-- lexing API
tlexScan :: TlexContext s TlexCodeUnit m => TlexStartState -> m (TlexResult s TlexSemanticAction)
-- runner fields
thTlexInitial :: Int -> Int
thTlexTrans :: Int -> Int -> Int
thTlexAccept :: Int -> Maybe TlexSemanticAction