style: clippy fix
This commit is contained in:
parent
0ef482c6ca
commit
528b1d21cb
3 changed files with 4 additions and 3 deletions
|
@ -54,7 +54,7 @@ pub enum NapiFnArgKind {
|
||||||
Callback(Box<CallbackArg>),
|
Callback(Box<CallbackArg>),
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug, Clone, PartialEq)]
|
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||||
pub enum FnKind {
|
pub enum FnKind {
|
||||||
Normal,
|
Normal,
|
||||||
Constructor,
|
Constructor,
|
||||||
|
@ -84,7 +84,7 @@ pub struct NapiStruct {
|
||||||
pub use_custom_finalize: bool,
|
pub use_custom_finalize: bool,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug, Clone, PartialEq)]
|
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||||
pub enum NapiStructKind {
|
pub enum NapiStructKind {
|
||||||
None,
|
None,
|
||||||
Constructor,
|
Constructor,
|
||||||
|
|
|
@ -153,7 +153,7 @@ impl NapiFn {
|
||||||
}
|
}
|
||||||
if ident == "This" {
|
if ident == "This" {
|
||||||
if let Some(syn::GenericArgument::Type(ty)) = angle_bracketed_args.first() {
|
if let Some(syn::GenericArgument::Type(ty)) = angle_bracketed_args.first() {
|
||||||
let (ts_type, _) = ty_to_ts_type(&ty, false, false);
|
let (ts_type, _) = ty_to_ts_type(ty, false, false);
|
||||||
return Some(FnArg {
|
return Some(FnArg {
|
||||||
arg: "this".to_owned(),
|
arg: "this".to_owned(),
|
||||||
ts_type,
|
ts_type,
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
#![allow(dead_code)]
|
#![allow(dead_code)]
|
||||||
#![allow(unreachable_code)]
|
#![allow(unreachable_code)]
|
||||||
|
#![allow(clippy::blacklisted_name)]
|
||||||
|
|
||||||
#[macro_use]
|
#[macro_use]
|
||||||
extern crate napi_derive;
|
extern crate napi_derive;
|
||||||
|
|
Loading…
Reference in a new issue