Help language development. Donate to The Perl Foundation

Slang::Predicate cpan:SAMGWISE last updated on 2017-12-21

Slang-Predicate-0.0.1/

NAME

Slang::Predicate - Predicates in perl6

SYNOPSIS

use Slang::Predicate;

my (\α, \β) = (T, F);

say ((α → β) ∧ α) → β;

DESCRIPTION

Slang::Predicate adds operators common to predicate logic directly to perl6.

Exported terms and operators are:

Terms Term Example
True T T ~~ True
False F F ~~ False
Infix operator Example
True T T ~~ True
False F F ~~ False
Disjunction T ∨ F ~~ True
Conjunction T ∧ F ~~ False
Exclusive disjunction ⊻ or ⊕ T ⊻ F ~~ True
Conditional → or ⇒ or ⊃ T → F ~~ False
Biconditional ↔ or ⇔ or ≡ T ↔ F ~~ False
Prefix operator Example
Negation ¬ ¬T ~~ False
Verum ⊤F ~~ True
Falsum ⊥T ~~ False

AUTHOR

Sam Gillespie samgwise@gmail.com

COPYRIGHT AND LICENSE

Copyright 2017 Sam Gillespie

This library is free software; you can redistribute it and/or modify it under the Artistic License 2.0.