Crate solders_macros

Crate solders_macros 

Source
Expand description

A collection of attribute macros to reduce boilerplate in the solders project.

These macros make some very specific assumptions about the structs they’re applied to, so they’re unlikely to be useful for other projects.

Attribute Macros§

common_methods
Add __bytes__, __str__, __repr__ and __reduce__, to_json and from_json using the CommonMethods trait.
common_methods_core
Add __bytes__, __str__, __repr__ and __reduce__ using the CommonMethodsCore trait.
common_methods_rpc_resp
Add __bytes__, __str__, __repr__, __reduce__, to_json, from_json, from_bytes and __richcmp__ using the CommonMethodsRpcResp trait.
enum_original_mapping
Add mappings to and from another enum that has the exact same fields.
pyhash
Add a __hash__ to the impl using the PyHash trait.
richcmp_eq_only
Add a __richcmp__ to the impl using the RichcmpEqualityOnly trait.
richcmp_full
Add a __richcmp__ to the impl using the RichcmpFull trait.
richcmp_signer
Add a __richcmp__ to the impl using the RichcmpSigner trait.
rpc_id_getter
Add an id getter to an RPC request object.

Derive Macros§

EnumIntoPy
Impl IntoPy for an ADT where each variant is a newtype.