Skip to content

Commit

Permalink
WIP: new function signature
Browse files Browse the repository at this point in the history
  • Loading branch information
davidhewitt committed Apr 14, 2022
1 parent 3b45170 commit 5f82beb
Show file tree
Hide file tree
Showing 6 changed files with 253 additions and 85 deletions.
7 changes: 3 additions & 4 deletions pyo3-macros-backend/src/method.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@
use crate::attributes::TextSignatureAttribute;
use crate::deprecations::Deprecation;
use crate::params::{accept_args_kwargs, impl_arg_params};
use crate::pyfunction::PyFunctionOptions;
use crate::pyfunction::{PyFunctionArgPyO3Attributes, PyFunctionSignature};
use crate::pyfunction::{PyFunctionOptions, DeprecatedArgs, PyFunctionArgPyO3Attributes};
use crate::utils::{self, get_pyo3_crate, PythonDoc};
use crate::{deprecations::Deprecations, pyfunction::Argument};
use proc_macro2::{Span, TokenStream};
Expand Down Expand Up @@ -716,8 +715,8 @@ fn parse_method_attributes(
}
};
} else if path.is_ident("args") {
let attrs = PyFunctionSignature::from_meta(&nested)?;
args.extend(attrs.arguments)
let attrs = DeprecatedArgs::from_meta(&nested)?;
args.extend(attrs.0.arguments)
} else {
new_attrs.push(attr)
}
Expand Down
Loading

0 comments on commit 5f82beb

Please sign in to comment.