| Safe Haskell | None |
|---|
DDC.Source.Tetra.Transform.Defix
- data FixTable a n = FixTable [FixDef a n]
- data FixDef a n
- = FixDefPrefix {
- fixDefSymbol :: String
- fixDefExp :: a -> Exp a n
- | FixDefInfix {
- fixDefSymbol :: String
- fixDefExp :: a -> Exp a n
- fixDefAssoc :: InfixAssoc
- fixDefPrec :: Int
- = FixDefPrefix {
- data InfixAssoc
- = InfixLeft
- | InfixRight
- | InfixNone
- defaultFixTable :: FixTable SourcePos Name
- data Error a n
- = ErrorNoInfixDef {
- errorAnnot :: a
- errorSymbol :: String
- | ErrorDefixNonAssoc {
- errorOp1 :: String
- errorAnnot1 :: a
- errorOp2 :: String
- errorAnnot2 :: a
- | ErrorDefixMixedAssoc {
- errorAnnot :: a
- errorOps :: [String]
- | ErrorMalformed {
- errorAnnot :: a
- errorExp :: Exp a n
- = ErrorNoInfixDef {
- class Defix c where
Documentation
Infix operator definition.
Constructors
| FixDefPrefix | |
Fields
| |
| FixDefInfix | |
Fields
| |
data InfixAssoc Source
Infix associativity.
Constructors
| InfixLeft | Left associative. |
| InfixRight | Right associative. |
| InfixNone | Non associative. |
Instances
defaultFixTable :: FixTable SourcePos NameSource
Default fixity table for infix operators.
Things that can go wrong when defixing code.
Constructors
| ErrorNoInfixDef | Infix operator symbol has no infix definition. |
Fields
| |
| ErrorDefixNonAssoc | Two non-associative operators with the same precedence. |
Fields
| |
| ErrorDefixMixedAssoc | Two operators of different associativies with same precedence. |
Fields
| |
| ErrorMalformed | |
Fields
| |