From d128d1fccdc827e867c6acde8c4c674c5324ff2a Mon Sep 17 00:00:00 2001 From: debris Date: Sat, 16 Jan 2016 17:26:32 +0100 Subject: [PATCH] renamed inc_sstore_refund_count -> inc_sstore_clear_count --- src/evm/ext.rs | 2 +- src/evm/jit.rs | 2 +- src/evm/tests.rs | 2 +- src/externalities.rs | 2 +- src/tests/executive.rs | 4 ++-- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/evm/ext.rs b/src/evm/ext.rs index bc03b2fe1..88382293b 100644 --- a/src/evm/ext.rs +++ b/src/evm/ext.rs @@ -87,5 +87,5 @@ pub trait Ext { fn depth(&self) -> usize; /// Increments sstore refunds count by 1. - fn inc_sstore_refund(&mut self); + fn inc_sstore_clear_count(&mut self); } diff --git a/src/evm/jit.rs b/src/evm/jit.rs index af0aad040..d1e8bb797 100644 --- a/src/evm/jit.rs +++ b/src/evm/jit.rs @@ -122,7 +122,7 @@ impl<'a> evmjit::Ext for ExtAdapter<'a> { let old_value = self.ext.storage_at(&key); // if SSTORE nonzero -> zero, increment refund count 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); } diff --git a/src/evm/tests.rs b/src/evm/tests.rs index d53de01b3..5d9381442 100644 --- a/src/evm/tests.rs +++ b/src/evm/tests.rs @@ -91,7 +91,7 @@ impl Ext for FakeExt { unimplemented!(); } - fn inc_sstore_refund(&mut self) { + fn inc_sstore_clear_count(&mut self) { unimplemented!(); } } diff --git a/src/externalities.rs b/src/externalities.rs index b211f8ae8..b432f90d8 100644 --- a/src/externalities.rs +++ b/src/externalities.rs @@ -220,7 +220,7 @@ impl<'a> Ext for Externalities<'a> { 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(); } } diff --git a/src/tests/executive.rs b/src/tests/executive.rs index 7af8c91b5..79f57b1e6 100644 --- a/src/tests/executive.rs +++ b/src/tests/executive.rs @@ -140,8 +140,8 @@ impl<'a> Ext for TestExt<'a> { 0 } - fn inc_sstore_refund(&mut self) { - self.ext.inc_sstore_refund() + fn inc_sstore_clear_count(&mut self) { + self.ext.inc_sstore_clear_count() } }