renamed inc_sstore_refund_count -> inc_sstore_clear_count
This commit is contained in:
parent
5171d566a3
commit
d128d1fccd
@ -87,5 +87,5 @@ pub trait Ext {
|
|||||||
fn depth(&self) -> usize;
|
fn depth(&self) -> usize;
|
||||||
|
|
||||||
/// Increments sstore refunds count by 1.
|
/// Increments sstore refunds count by 1.
|
||||||
fn inc_sstore_refund(&mut self);
|
fn inc_sstore_clear_count(&mut self);
|
||||||
}
|
}
|
||||||
|
@ -122,7 +122,7 @@ impl<'a> evmjit::Ext for ExtAdapter<'a> {
|
|||||||
let old_value = self.ext.storage_at(&key);
|
let old_value = self.ext.storage_at(&key);
|
||||||
// if SSTORE nonzero -> zero, increment refund count
|
// if SSTORE nonzero -> zero, increment refund count
|
||||||
if !old_value.is_zero() && value.is_zero() {
|
if !old_value.is_zero() && value.is_zero() {
|
||||||
self.ext.inc_sstore_refund();
|
self.ext.inc_sstore_clear_count();
|
||||||
}
|
}
|
||||||
self.ext.set_storage(key, value);
|
self.ext.set_storage(key, value);
|
||||||
}
|
}
|
||||||
|
@ -91,7 +91,7 @@ impl Ext for FakeExt {
|
|||||||
unimplemented!();
|
unimplemented!();
|
||||||
}
|
}
|
||||||
|
|
||||||
fn inc_sstore_refund(&mut self) {
|
fn inc_sstore_clear_count(&mut self) {
|
||||||
unimplemented!();
|
unimplemented!();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -220,7 +220,7 @@ impl<'a> Ext for Externalities<'a> {
|
|||||||
self.depth
|
self.depth
|
||||||
}
|
}
|
||||||
|
|
||||||
fn inc_sstore_refund(&mut self) {
|
fn inc_sstore_clear_count(&mut self) {
|
||||||
self.substate.sstore_clears_count = self.substate.sstore_clears_count + U256::one();
|
self.substate.sstore_clears_count = self.substate.sstore_clears_count + U256::one();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -140,8 +140,8 @@ impl<'a> Ext for TestExt<'a> {
|
|||||||
0
|
0
|
||||||
}
|
}
|
||||||
|
|
||||||
fn inc_sstore_refund(&mut self) {
|
fn inc_sstore_clear_count(&mut self) {
|
||||||
self.ext.inc_sstore_refund()
|
self.ext.inc_sstore_clear_count()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user