Function format_gas
pub fn format_gas(gas: u64) -> String
Available on crate feature
node-api
only.Expand description
Returns a formatted gas log, showing either:
- “Kgas”, or 1,000 gas
- “Mgas”, or 1,000,000 gas
- “Ggas”, or 1,000,000,000 gas
Depending on the magnitude of gas.