pub struct DisplayExpr<'a, M: Marker>(/* private fields */);
Expand description
Display a Simplicity expression as a linear string.
The linear string has no sharing and may be exponentially larger than the underlying shared expression.
There are some basic transformations to increase readability:
§Infix notation
pair s t
→ s & t
comp s t
→ s; t
§Booleans
injl unit
→ false
injr unit
→ true
§Selectors
take drop iden
→ OIH
Sequences of take
and drop
that end in iden
are transformed as follows:
take
→ O
(looks like zero)
drop
→ I
(looks like one)
iden
→ H
Trait Implementations§
Source§impl<'a, M: Marker> Debug for DisplayExpr<'a, M>
impl<'a, M: Marker> Debug for DisplayExpr<'a, M>
Source§impl<'a, M: Marker> Display for DisplayExpr<'a, M>
impl<'a, M: Marker> Display for DisplayExpr<'a, M>
Auto Trait Implementations§
impl<'a, M> Freeze for DisplayExpr<'a, M>
impl<'a, M> RefUnwindSafe for DisplayExpr<'a, M>where
<M as Marker>::CachedData: RefUnwindSafe,
<M as Marker>::Disconnect: RefUnwindSafe,
<M as Marker>::Witness: RefUnwindSafe,
<M as Marker>::Jet: RefUnwindSafe,
impl<'a, M> Send for DisplayExpr<'a, M>
impl<'a, M> Sync for DisplayExpr<'a, M>
impl<'a, M> Unpin for DisplayExpr<'a, M>
impl<'a, M> UnwindSafe for DisplayExpr<'a, M>where
<M as Marker>::CachedData: RefUnwindSafe,
<M as Marker>::Disconnect: RefUnwindSafe,
<M as Marker>::Witness: RefUnwindSafe,
<M as Marker>::Jet: RefUnwindSafe,
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