4 releases (2 breaking)

0.3.1 Feb 17, 2020
0.3.0 Feb 4, 2020
0.2.0 Oct 27, 2018
0.1.0 Sep 29, 2018

#5 in #eos

Download history 3/week @ 2023-11-20 6/week @ 2023-11-27 1/week @ 2023-12-11 4/week @ 2023-12-18 5/week @ 2024-01-08 6/week @ 2024-02-12 19/week @ 2024-02-19 25/week @ 2024-02-26 14/week @ 2024-03-04

64 downloads per month
Used in 4 crates (via eosio)

MIT/Apache

12KB
129 lines

Build Status

eosio_macros

Macros for creating compile-time EOSIO names and symbols.

Creating EOSIO names:

use eosio_macros::n;
assert_eq!(n!("test"), 14_605_613_396_213_628_928);
assert_eq!(n!("1234"), 614_248_767_926_829_056);
assert_eq!(n!("123451234512"), 614_251_535_012_020_768);
assert_eq!(n!("eosio.token"), 6_138_663_591_592_764_928);

Creating EOSIO symbols:

use eosio_macros::s;
assert_eq!(s!(4, "EOS"), 1162826500);

License: MIT OR Apache-2.0


lib.rs:

Macros for creating compile-time EOSIO names and symbols.

Creating EOSIO names:

use eosio_macros::n;
assert_eq!(n!("test"), 14_605_613_396_213_628_928);
assert_eq!(n!("1234"), 614_248_767_926_829_056);
assert_eq!(n!("123451234512"), 614_251_535_012_020_768);
assert_eq!(n!("eosio.token"), 6_138_663_591_592_764_928);

Creating EOSIO symbols:

use eosio_macros::s;
assert_eq!(s!(4, "EOS"), 1162826500);

Dependencies

~2MB
~42K SLoC