Struct lib_ruby_parser::token_rewriter::TokenRewriter[][src]

#[repr(C)]pub struct TokenRewriter { /* fields omitted */ }

Token rewriter struct, can be used to rewrite tokens on the fly

Implementations

impl TokenRewriter[src]

pub fn new(f: TokenRewriterFn) -> Self[src]

Constructs a rewriter based on a given function

pub fn none() -> Self[src]

Constructs a no-op token rewriter that has no side effect. Default value.

pub fn as_option(&self) -> Option<&TokenRewriterFn>[src]

Returns an optional reference to a function that rewrite tokens

Trait Implementations

impl Debug for TokenRewriter[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.