Struct syntex_syntax::util::interner::StrInterner [] [src]

pub struct StrInterner {
    // some fields omitted
}

A StrInterner differs from Interner in that it accepts &str rather than RcStr, resulting in less allocation.

Methods

impl StrInterner
[src]

When traits can extend traits, we should extend index to get []

fn new() -> StrInterner

fn prefill(init: &[&str]) -> StrInterner

fn intern(&self, val: &str) -> Name

fn gensym(&self, val: &str) -> Name

fn gensym_copy(&self, idx: Name) -> Name

Create a gensym with the same name as an existing entry.

fn get(&self, idx: Name) -> RcStr

fn len(&self) -> usize

fn find<Q: ?Sized>(&self, val: &Q) -> Option<Name> where RcStr: Borrow<Q>, Q: Eq + Hash

fn clear(&self)

fn reset(&self, other: StrInterner)