Allow js_name attribute to accept a string

This commit is contained in:
Michael Hoffmann
2018-08-05 00:17:30 +02:00
committed by Alex Crichton
parent 63ee9a024d
commit 21c36d3902
4 changed files with 114 additions and 18 deletions

View File

@ -116,7 +116,7 @@ pub struct ImportStatic {
pub ty: syn::Type,
pub shim: Ident,
pub rust_name: Ident,
pub js_name: Ident,
pub js_name: String,
}
#[cfg_attr(feature = "extra-traits", derive(Debug, PartialEq, Eq))]
@ -143,7 +143,7 @@ pub struct ImportEnum {
#[cfg_attr(feature = "extra-traits", derive(Debug, PartialEq, Eq))]
pub struct Function {
pub name: Ident,
pub name: String,
pub arguments: Vec<syn::ArgCaptured>,
pub ret: Option<syn::Type>,
pub rust_attrs: Vec<syn::Attribute>,