forked from orion/obsidian
1.5 KiB
1.5 KiB
Infix Operators used for Boolean algebra.
[!info]
&&
and||
become short-circuiting when used on functions, e.g.Unit -> Boolean
:a :: Unit -> Boolean a _ = false b :: Unit -> Boolean b _ = unsafeCrashWith "uh-oh!" c :: Unit -> Boolean c = a && b d :: Unit -> Boolean d = c unit
Operator | Description | Associativity | Precedence | Defined As |
---|---|---|---|---|
|| |
boolean OR | right | 2 | [Data.HeytingAlgrebra.disj ](https://pursuit.purescript.org/packages/purescript-prelude/docs/Data.HeytingAlgebra#v:( |
&& |
boolean AND | right | 3 | Data.HeytingAlgrebra.conj |
== |
equals | not | 4 | Data.Eq.eq |
/= |
not equals | Data.Eq.notEq |
||
> |
greater than | Data.Ord.greaterThan |
||
< |
less than | Data.Ord.lessThan |
||
>= |
greater than or equal | Data.Ord.greaterThanOrEq |
||
<= |
less than or equal | Data.Ord.lessThanOrEq |