Crate ethprim

source ·
Expand description

A meta-crate that aggregates various Ethereum primitive types.

Currently, this crate re-exports:

Modules

Re-export of all included crates.
256-bit integer re-exports.
Convenience re-export of core types and traits.

Macros

Procedural macro to create Ethereum public address values from string literals that get verified at compile time. A compiler error will be generated if an invalid address is specified.
Procedural macro to create Ethereum digest values from string literals that get parsed at compile time. A compiler error will be generated if an invalid digest is specified.
Macro for 256-bit signed integer literal.
Procedural macro to create Ethereum digest values from compile-time hashed input.
Macro for 256-bit unsigned integer literal.

Structs

An Ethereum public address.
A 32-byte digest.
A 256-bit signed integer type.
A Keccak-256 hasher.
A 256-bit unsigned integer type.

Enums

Represents an error parsing an address from a string.
Represents an error parsing a digest from a string.

Traits

This trait defines as conversions (casting) from primitive types to I256.
This trait defines as conversions (casting) from primitive types to U256.