mirror of
https://github.com/fluencelabs/wasm-bindgen
synced 2025-07-26 17:41:56 +00:00
Forward attributes on type
declaration to definition
This'll allow things like `#[derive(Clone)]` or `#[derive(Debug)]` to control traits for these types.
This commit is contained in:
@@ -84,6 +84,7 @@ pub struct ImportStatic {
|
||||
pub struct ImportType {
|
||||
pub vis: syn::Visibility,
|
||||
pub name: Ident,
|
||||
pub attrs: Vec<syn::Attribute>,
|
||||
}
|
||||
|
||||
#[cfg_attr(feature = "extra-traits", derive(Debug, PartialEq, Eq))]
|
||||
@@ -469,6 +470,7 @@ impl Program {
|
||||
ImportKind::Type(ImportType {
|
||||
vis: f.vis,
|
||||
name: f.ident,
|
||||
attrs: f.attrs,
|
||||
})
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user