pub enum Program {
Module(Vec<ProgramPart>),
Script(Vec<ProgramPart>),
}
Expand description
A fully parsed javascript program.
It is essentially a collection of ProgramPart
s
with a flag denoting if the representation is
a ES6 Module or a Script.
Variants
Implementations
sourceimpl Program
impl Program
pub fn module(parts: Vec<ProgramPart>) -> Self
pub fn script(parts: Vec<ProgramPart>) -> Self
Trait Implementations
impl StructuralPartialEq for Program
Auto Trait Implementations
impl RefUnwindSafe for Program
impl Send for Program
impl Sync for Program
impl Unpin for Program
impl UnwindSafe for Program
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more