6 releases (breaking)

0.6.0 Jan 27, 2021
0.5.0 Jan 5, 2021
0.4.0 Mar 16, 2020
0.3.0 Oct 1, 2019
0.1.0 Aug 12, 2019

#14 in #ethereum-contract

Download history 3/week @ 2025-09-11 4/week @ 2025-10-16 14/week @ 2025-10-23

54 downloads per month

MIT/Apache

75KB
1.5K SLoC

Contract address

Provides a function to create an ethereum contract address.

Examples

Create an ethereum address from sender and nonce.

use contract_address::{
	Address, U256, ContractAddress
};
use std::str::FromStr;

let sender = Address::from_str("0f572e5295c57f15886f9b263e2f6d2d6c7b5ec6").unwrap();
let contract_address = ContractAddress::from_sender_and_nonce(&sender, &U256::zero());

Dependencies

~575KB