Expand description
§Impl-tools
#[autoimpl]
is an alternative to
#[derive]
with more features (also usable on traits).
#[impl_default]
is an alternative to
#[derive(Default)]
supporting field initializers.
#[impl_self]
provides impl Self
syntax, avoiding the
need to repeat generics when writing impls on a local type definition.
This supercedes impl_scope!
(except regarding impl_default
).
impl_anon!
is a function-like macro used to define and instantiate a
unique (single-use) type. It supports everything supported by impl_scope!
plus field initializers and (limited) automatic typing of fields.
User-extensions to both #[autoimpl]
and impl_self
are possible with a custom proc-macro crate depending on
impl-tools-lib.
Macros§
- impl_
anon - Construct an anonymous struct
- impl_
scope - Implement a type with
impl Self
syntax
Attribute Macros§
- autoimpl
- An alternative to the standard
derive
macro - impl_
default - Impl
Default
with given field or type initializers - impl_
self - Implement a type with
impl Self
syntax