pub struct ScottEncoding;Expand description
Scott encoding of algebraic data types.
Implementations§
Source§impl ScottEncoding
impl ScottEncoding
Sourcepub fn scott_true_desc() -> &'static str
pub fn scott_true_desc() -> &'static str
Scott-encoded Boolean: True = λt. λf. t; False = λt. λf. f.
pub fn scott_false_desc() -> &'static str
Sourcepub fn scott_pair_desc() -> &'static str
pub fn scott_pair_desc() -> &'static str
Scott-encoded pair: Pair a b = λs. s a b.
Sourcepub fn scott_fst_desc() -> &'static str
pub fn scott_fst_desc() -> &'static str
Scott-encoded fst: fst p = p (λa. λb. a).
Sourcepub fn scott_nil_desc() -> &'static str
pub fn scott_nil_desc() -> &'static str
Scott-encoded List: Nil = λn. λc. n; Cons h t = λn. λc. c h t.
pub fn scott_cons_desc() -> &'static str
Auto Trait Implementations§
impl Freeze for ScottEncoding
impl RefUnwindSafe for ScottEncoding
impl Send for ScottEncoding
impl Sync for ScottEncoding
impl Unpin for ScottEncoding
impl UnsafeUnpin for ScottEncoding
impl UnwindSafe for ScottEncoding
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more