You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Often you have fixed values that could already be parsed during compile time. Currently I am initializing those values using lazy_static. My proposal would be to have macros to parse ether, wei, etc. from a string to U256.
Currently you will write:
let val:U256 = parse_units("0.01","ether").unwrap().get_absolute();
Proposal:
let val:U256 = ether!("0.01");
If the parsing fails it will throw an error during compile time.
Additional context
No response
The text was updated successfully, but these errors were encountered:
Component
primitives
Describe the feature you would like
Often you have fixed values that could already be parsed during compile time. Currently I am initializing those values using lazy_static. My proposal would be to have macros to parse ether, wei, etc. from a string to U256.
Currently you will write:
Proposal:
If the parsing fails it will throw an error during compile time.
Additional context
No response
The text was updated successfully, but these errors were encountered: