mirror of
https://github.com/fluencelabs/wasm-bindgen
synced 2025-06-28 12:11:34 +00:00
Add a raw_module
attribute to #[wasm_bindgen]
This allows subverting the checks and resolution performed by the `module` attribute added as part of [RFC 6] and has been discussed in #1343. Closes #1343 [RFC 6]: https://github.com/rustwasm/rfcs/pull/6
This commit is contained in:
@ -79,6 +79,7 @@ pub struct Import {
|
||||
pub enum ImportModule {
|
||||
None,
|
||||
Named(String, Span),
|
||||
RawNamed(String, Span),
|
||||
Inline(usize, Span),
|
||||
}
|
||||
|
||||
@ -96,6 +97,10 @@ impl Hash for ImportModule {
|
||||
2u8.hash(h);
|
||||
idx.hash(h);
|
||||
}
|
||||
ImportModule::RawNamed(name, _) => {
|
||||
3u8.hash(h);
|
||||
name.hash(h);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user