[][src]Struct swc_ecma_codegen::Emitter

pub struct Emitter<'a> {
    pub cfg: Config,
    pub cm: Arc<SourceMap>,
    pub comments: Option<&'a Comments>,
    pub wr: Box<dyn WriteJs + 'a>,
    pub handlers: Box<dyn Handlers + 'a>,
}

Fields

cfg: Configcm: Arc<SourceMap>comments: Option<&'a Comments>wr: Box<dyn WriteJs + 'a>handlers: Box<dyn Handlers + 'a>

Implementations

impl<'a> Emitter<'a>[src]

pub fn emit_program(&mut self, node: &Program) -> Result[src]

pub fn emit_module(&mut self, node: &Module) -> Result[src]

pub fn emit_script(&mut self, node: &Script) -> Result[src]

pub fn needs_2dots_for_property_access(&self, expr: &ExprOrSuper) -> bool[src]

1..toString is a valid property access, emit a dot after the literal

Auto Trait Implementations

impl<'a> !RefUnwindSafe for Emitter<'a>

impl<'a> !Send for Emitter<'a>

impl<'a> !Sync for Emitter<'a>

impl<'a> Unpin for Emitter<'a>

impl<'a> !UnwindSafe for Emitter<'a>

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> Erased for T

impl<T, F> Fold<T> for F where
    T: FoldWith<F>, 
[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.

impl<T, F> Visit<T> for F where
    T: VisitWith<F> + ?Sized
[src]

impl<T, F> VisitMut<T> for F where
    T: VisitMutWith<F> + ?Sized
[src]