# Kleene logic within Rust's type system [![Build Status](https://travis-ci.org/llogiq/ternary.svg)](https://travis-ci.org/llogiq/ternary) [![Current Version](http://meritbadge.herokuapp.com/ternary)](https://crates.io/crates/ternary) [![License: MIT](https://img.shields.io/dub/l/vibe-d.svg)](LICENSE) Values are `True`, `False` and `Unknown`. Operations are `Not`, `BitAnd` and `BitOr` from `std::ops`. There is also the `Ternary` enum which represents the values at runtime and the `ToTernary` trait that adds the `to_ternary()` methods to our value types. For more information read the [API documentation](http://llogiq.github.io/ternary) Examples: `Same` and `Not` ``` use ternary::{True, False, Unknown, Same}; use std::ops::Not; type NotTrue = <::Output as Same>::Output; type NotFalse = <::Output as Same>::Output; type NotUnknown = <::Output as Same>::Output; ``` Transforming Values to Runtime, `BitAnd` and `BitOr` ``` assert_eq!(Ternary::T, >::Output>>::Output::to_ternary()); ``` To use it, add `ternary = "0.1.0"` to your dependencies.