pub enum ConsumerKind {
StringJoin,
}Expand description
What the matched builder feeds into. Different consumers compile to different buffer types and finalizers, but all share the same underlying deforestation: skip the intermediate List, write elements straight to the consumer’s storage.
Phase 2 implements StringJoin only — the canonical case from the
fractal demo. Future variants land as separate phases:
VectorFromList (already half-fused via Vector.set owned-mutate
in 0.14.0; deforestation closes the cons-cell side), and ListFold
for stream-fusion-style consumer rewrites.
Variants§
StringJoin
String.join(builder(...), sep) — write each element + sep
directly into a Vec<u8>-shaped buffer in linear memory.
Trait Implementations§
Source§impl Clone for ConsumerKind
impl Clone for ConsumerKind
Source§fn clone(&self) -> ConsumerKind
fn clone(&self) -> ConsumerKind
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ConsumerKind
impl Debug for ConsumerKind
Source§impl PartialEq for ConsumerKind
impl PartialEq for ConsumerKind
Source§fn eq(&self, other: &ConsumerKind) -> bool
fn eq(&self, other: &ConsumerKind) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for ConsumerKind
impl StructuralPartialEq for ConsumerKind
Auto Trait Implementations§
impl Freeze for ConsumerKind
impl RefUnwindSafe for ConsumerKind
impl Send for ConsumerKind
impl Sync for ConsumerKind
impl Unpin for ConsumerKind
impl UnsafeUnpin for ConsumerKind
impl UnwindSafe for ConsumerKind
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.