Struct swc::PassBuilder [−][src]
Builder is used to create a high performance Compiler
.
Implementations
impl<'a, 'b, P: Fold> PassBuilder<'a, 'b, P>
[src]
pub fn new(
cm: &'a Arc<SourceMap>,
handler: &'b Handler,
loose: bool,
global_mark: Mark,
pass: P
) -> Self
[src]
cm: &'a Arc<SourceMap>,
handler: &'b Handler,
loose: bool,
global_mark: Mark,
pass: P
) -> Self
pub fn then<N>(self, next: N) -> PassBuilder<'a, 'b, AndThen<P, N>> where
N: Fold,
[src]
N: Fold,
pub fn skip_helper_injection(self, skip: bool) -> Self
[src]
pub fn fixer(self, enable: bool) -> Self
[src]
Note: fixer is enabled by default.
pub fn hygiene(self, config: Option<Config>) -> Self
[src]
Note: hygiene is enabled by default.
If you pass None to this method, the hygiene
pass will be disabled.
pub fn const_modules(
self,
globals: HashMap<JsWord, HashMap<JsWord, String>>
) -> PassBuilder<'a, 'b, impl Fold>
[src]
self,
globals: HashMap<JsWord, HashMap<JsWord, String>>
) -> PassBuilder<'a, 'b, impl Fold>
pub fn inline_globals(
self,
c: GlobalPassOption
) -> PassBuilder<'a, 'b, impl Fold>
[src]
self,
c: GlobalPassOption
) -> PassBuilder<'a, 'b, impl Fold>
pub fn target(self, target: JscTarget) -> Self
[src]
pub fn preset_env(self, env: Option<Config>) -> Self
[src]
pub fn finalize<'cmt>(
self,
syntax: Syntax,
module: Option<ModuleConfig>,
comments: Option<&'cmt dyn Comments>
) -> impl 'cmt + Fold where
P: 'cmt,
[src]
self,
syntax: Syntax,
module: Option<ModuleConfig>,
comments: Option<&'cmt dyn Comments>
) -> impl 'cmt + Fold where
P: 'cmt,
Auto Trait Implementations
impl<'a, 'b, P> !RefUnwindSafe for PassBuilder<'a, 'b, P>
impl<'a, 'b, P> Send for PassBuilder<'a, 'b, P> where
P: Send,
P: Send,
impl<'a, 'b, P> Sync for PassBuilder<'a, 'b, P> where
P: Sync,
P: Sync,
impl<'a, 'b, P> Unpin for PassBuilder<'a, 'b, P> where
P: Unpin,
P: Unpin,
impl<'a, 'b, P> !UnwindSafe for PassBuilder<'a, 'b, P>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Erased for T
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Node for T where
T: Any + ?Sized,
[src]
T: Any + ?Sized,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,