-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Conversation
NikVolf
commented
Sep 5, 2017
•
edited
Loading
edited
- WASM contracts will be able to utilize various blockchain runtime externs (gas_limit, difficulty, coinbase, etc..)
- corresponding happy test
- also updates to use latest parity-wasm and corresponding refactoring
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, but I would replace exact gas_left
checks in tests with something like assert!(gas_left < params.gas)
or assert!(params.gas - gas_left < 5000)
.
Not sure that exact value is important - imho it depends on too many factors like compiler version (next version may generate slightly different wasm code), compiler flags (something like optimization/no optimization, etc), code itself.
@svyatonik |
@NikVolf I agree. Related: what made the gas costs for examples smaller? I was worried that they aren't remaining consistent. |
@rphmeier I am not sure about what exactly caused this particular change though, nor it does matter much |