module Text.Fixity
( Precedence
, Associativity (..)
, FixityOver (..)
, Fixity
, Direction (..)
, RenderContextOver (..)
, RenderContext
, encloseIn
, botFixity
, juxtFixity
, unitFixity
, topFixity
, botRenderContext
, topRenderContext
) where
import Text.Fixity.Internal
type Precedence = Double
type Fixity = FixityOver Precedence
type RenderContext = RenderContextOver Precedence
botFixity :: Fixity
botFixity :: Fixity
botFixity = Associativity -> Precedence -> Fixity
forall prec. Associativity -> prec -> FixityOver prec
Fixity Associativity
NonAssociative (-Precedence
20)
juxtFixity :: Fixity
juxtFixity :: Fixity
juxtFixity = Associativity -> Precedence -> Fixity
forall prec. Associativity -> prec -> FixityOver prec
Fixity Associativity
LeftAssociative Precedence
100
unitFixity :: Fixity
unitFixity :: Fixity
unitFixity = Associativity -> Precedence -> Fixity
forall prec. Associativity -> prec -> FixityOver prec
Fixity Associativity
NonAssociative Precedence
110
topFixity :: Fixity
topFixity :: Fixity
topFixity = Associativity -> Precedence -> Fixity
forall prec. Associativity -> prec -> FixityOver prec
Fixity Associativity
NonAssociative Precedence
120
botRenderContext :: RenderContext
botRenderContext :: RenderContext
botRenderContext = Direction -> Fixity -> RenderContext
forall prec. Direction -> FixityOver prec -> RenderContextOver prec
RenderContext Direction
ToTheRight Fixity
botFixity
topRenderContext :: RenderContext
topRenderContext :: RenderContext
topRenderContext = Direction -> Fixity -> RenderContext
forall prec. Direction -> FixityOver prec -> RenderContextOver prec
RenderContext Direction
ToTheRight Fixity
topFixity