Fix module init function name in py2_init

This commit is contained in:
Martin Larralde 2018-05-14 03:19:29 +02:00
parent d1ec82d4a7
commit d5efc40445

View file

@ -59,7 +59,7 @@ pub fn py3_init(fnname: &syn::Ident, name: &syn::Ident, doc: syn::Lit) -> Tokens
pub fn py2_init(fnname: &syn::Ident, name: &syn::Ident, doc: syn::Lit) -> Tokens {
let cb_name: syn::Ident = syn::parse_str(&format!("PyInit_{}", name)).unwrap();
let cb_name: syn::Ident = syn::parse_str(&format!("init{}", name)).unwrap();
quote! {
#[no_mangle]