pub struct DeprecatedInfo {
pub since: Option<String>,
pub note: Option<String>,
}
Expand description
#[pyo3(...)]
style attributes appear in #[pyclass]
and #[pymethods]
proc-macros
As the reference of PyO3 says:
https://docs.rs/pyo3/latest/pyo3/attr.pyclass.html
All of these parameters can either be passed directly on the
#[pyclass(...)]
annotation, or as one or more accompanying#[pyo3(...)]
annotations,
#[pyclass(name = "MyClass", module = "MyModule")]
will be decomposed into
#[pyclass]
+ #[pyo3(name = "MyClass")]
+ #[pyo3(module = "MyModule")]
,
i.e. two Attr
s will be created for this case.
Fields§
§since: Option<String>
§note: Option<String>
Trait Implementations§
Source§impl Clone for DeprecatedInfo
impl Clone for DeprecatedInfo
Source§fn clone(&self) -> DeprecatedInfo
fn clone(&self) -> DeprecatedInfo
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for DeprecatedInfo
impl Debug for DeprecatedInfo
Source§impl PartialEq for DeprecatedInfo
impl PartialEq for DeprecatedInfo
Source§impl ToTokens for DeprecatedInfo
impl ToTokens for DeprecatedInfo
Source§fn to_tokens(&self, tokens: &mut TokenStream2)
fn to_tokens(&self, tokens: &mut TokenStream2)
Source§fn to_token_stream(&self) -> TokenStream
fn to_token_stream(&self) -> TokenStream
Source§fn into_token_stream(self) -> TokenStreamwhere
Self: Sized,
fn into_token_stream(self) -> TokenStreamwhere
Self: Sized,
impl StructuralPartialEq for DeprecatedInfo
Auto Trait Implementations§
impl Freeze for DeprecatedInfo
impl RefUnwindSafe for DeprecatedInfo
impl Send for DeprecatedInfo
impl Sync for DeprecatedInfo
impl Unpin for DeprecatedInfo
impl UnwindSafe for DeprecatedInfo
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Spanned for T
impl<T> Spanned for T
Source§fn span(&self) -> Span
fn span(&self) -> Span
Returns a
Span
covering the complete contents of this syntax tree
node, or Span::call_site()
if this node is empty.