Module

Type.Data.Symbol

Package
purescript-typelevel-prelude
Repository
purescript/purescript-typelevel-prelude

#append Source

append :: forall l r o. Append l r o => SProxy l -> SProxy r -> SProxy o

#compare Source

compare :: forall l r o. Compare l r o => SProxy l -> SProxy r -> OProxy o

#uncons Source

uncons :: forall h t s. Cons h t s => SProxy s -> { head :: SProxy h, tail :: SProxy t }

#Equals Source

class Equals (lhs :: Symbol) (rhs :: Symbol) (out :: Boolean) | lhs rhs -> out

Instances

#equals Source

equals :: forall l r o. Equals l r o => SProxy l -> SProxy r -> BProxy o

Re-exports from Data.Symbol

#SProxy Source

data SProxy (sym :: Symbol)

A value-level proxy for a type-level symbol.

Constructors

#IsSymbol Source

class IsSymbol (sym :: Symbol)  where

A class for known symbols

Members

#reifySymbol Source

reifySymbol :: forall r. String -> (forall sym. IsSymbol sym => SProxy sym -> r) -> r

Re-exports from Prim.Symbol

#Append

class Append (left :: Symbol) (right :: Symbol) (appended :: Symbol) | left right -> appended, right appended -> left, appended left -> right

Compiler solved type class for appending Symbols together.

#Compare

class Compare (left :: Symbol) (right :: Symbol) (ordering :: Ordering) | left right -> ordering

Compiler solved type class for comparing two Symbols. Produces an Ordering.

#Cons

class Cons (head :: Symbol) (tail :: Symbol) (symbol :: Symbol) | head tail -> symbol, symbol -> head tail

Compiler solved type class for either splitting up a symbol into its head and tail or for combining a head and tail into a new symbol. Requires the head to be a single character and the combined string cannot be empty.