Add support for version specifications

This commit adds a `#[wasm_bindgen(version = "...")]` attribute support. This
information is eventually written into a `__wasm_pack_unstable` section.
Currently this is a strawman for the proposal in ashleygwilliams/wasm-pack#101
This commit is contained in:
Alex Crichton
2018-04-25 07:26:33 -07:00
parent d9a71b43db
commit 412bebca72
7 changed files with 183 additions and 0 deletions

View File

@ -22,6 +22,7 @@ pub struct Program {
#[derive(Deserialize, Serialize)]
pub struct Import {
pub module: Option<String>,
pub version: Option<String>,
pub js_namespace: Option<String>,
pub kind: ImportKind,
}