hinit-0.2.0: Generic project initialization tool
Safe HaskellNone
LanguageHaskell2010

Data.Algebra.Boolean

Description

Boolean expressions implemented using naive trees

Synopsis

Documentation

type CTX = Map Text Bool Source #

Context. Every variable not in context will be treated as False.

data Expr Source #

Instances

Instances details
Eq Expr Source # 
Instance details

Defined in Data.Algebra.Boolean

Methods

(==) :: Expr -> Expr -> Bool #

(/=) :: Expr -> Expr -> Bool #

Show Expr Source # 
Instance details

Defined in Data.Algebra.Boolean

Methods

showsPrec :: Int -> Expr -> ShowS #

show :: Expr -> String #

showList :: [Expr] -> ShowS #

eval :: CTX -> Expr -> Bool Source #

Evaluate an expression in a context.

expr :: Parser Expr Source #

Parse an expression