[][src]Struct wasm_bindgen_backend::ast::Program

pub struct Program {
    pub exports: Vec<Export>,
    pub imports: Vec<Import>,
    pub enums: Vec<Enum>,
    pub structs: Vec<Struct>,
    pub consts: Vec<Const>,
    pub dictionaries: Vec<Dictionary>,
    pub typescript_custom_sections: Vec<String>,
    pub inline_js: Vec<String>,
}

An abstract syntax tree representing a rust program. Contains extra information for joining up this rust code with javascript.

Fields

exports: Vec<Export>

rust -> js interfaces

imports: Vec<Import>

js -> rust interfaces

enums: Vec<Enum>

rust enums

structs: Vec<Struct>

rust structs

consts: Vec<Const>

rust consts

dictionaries: Vec<Dictionary>

"dictionaries", generated for WebIDL, which are basically just "typed objects" in the sense that they represent a JS object with a particular shape in JIT parlance.

typescript_custom_sections: Vec<String>

custom typescript sections to be included in the definition file

inline_js: Vec<String>

Inline JS snippets

Trait Implementations

impl TryToTokens for Program[src]

impl ImportedTypes for Program[src]

impl RemoveUndefinedImports for Program[src]

impl Default for Program[src]

impl Clone for Program[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl !Send for Program

impl Unpin for Program

impl !Sync for Program

impl UnwindSafe for Program

impl !RefUnwindSafe for Program

Blanket Implementations

impl<T> ImportedTypeDefinitions for T where
    T: ImportedTypes
[src]

impl<T> ImportedTypeReferences for T where
    T: ImportedTypes
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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> BorrowMut<T> for T where
    T: ?Sized
[src]

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

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