[−][src]Struct swc_ecma_parser::Parser
EcmaScript parser.
Implementations
impl<'a, I: Tokens> Parser<I>
[src]
pub fn parse_expr(&mut self) -> PResult<Box<Expr>>
[src]
impl<I: Tokens> Parser<I>
[src]
impl<'a, I: Tokens> Parser<I>
[src]
pub fn parse_stmt(&mut self, top_level: bool) -> PResult<Stmt>
[src]
impl<I: Tokens> Parser<I>
[src]
pub fn parse_type(&mut self) -> PResult<Box<TsType>>
[src]
pub fn parse_ts_type_args(&mut self) -> PResult<TsTypeParamInstantiation>
[src]
tsParseTypeArguments
impl<'a, I: Input> Parser<Lexer<'a, I>>
[src]
impl<I: Tokens> Parser<I>
[src]
pub fn new_from(input: I) -> Self
[src]
pub fn take_errors(&mut self) -> Vec<Error>
[src]
pub fn parse_script(&mut self) -> PResult<Script>
[src]
pub fn parse_typescript_module(&mut self) -> PResult<Module>
[src]
pub fn parse_program(&mut self) -> PResult<Program>
[src]
Returns Module if it'a module and returns Script if it's not a module.
Note: This is not perfect yet. It means, some strict mode violations may not be reported even if the method returns Module.
pub fn parse_module(&mut self) -> PResult<Module>
[src]
Trait Implementations
Auto Trait Implementations
impl<I> RefUnwindSafe for Parser<I> where
I: RefUnwindSafe,
[src]
I: RefUnwindSafe,
impl<I> Send for Parser<I> where
I: Send,
[src]
I: Send,
impl<I> Sync for Parser<I> where
I: Sync,
[src]
I: Sync,
impl<I> Unpin for Parser<I> where
I: Unpin,
[src]
I: Unpin,
impl<I> UnwindSafe for Parser<I> where
I: UnwindSafe,
[src]
I: UnwindSafe,
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> 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> Send for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Sync for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
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>,