diff options
author | chriseth <chris@ethereum.org> | 2018-10-01 19:20:38 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-10-01 19:20:38 +0800 |
commit | 5ae32b24a6b914a5940bb1bfb82304cb276431f4 (patch) | |
tree | 6b427c83b0623328e911706b91da9d09a63f663f /libsolidity | |
parent | e9f72212ee72312d264311bae37e44cd965798ab (diff) | |
parent | d71cc66ddeb3f6e91628c019966b5ea107df4a15 (diff) | |
download | dexon-solidity-5ae32b24a6b914a5940bb1bfb82304cb276431f4.tar dexon-solidity-5ae32b24a6b914a5940bb1bfb82304cb276431f4.tar.gz dexon-solidity-5ae32b24a6b914a5940bb1bfb82304cb276431f4.tar.bz2 dexon-solidity-5ae32b24a6b914a5940bb1bfb82304cb276431f4.tar.lz dexon-solidity-5ae32b24a6b914a5940bb1bfb82304cb276431f4.tar.xz dexon-solidity-5ae32b24a6b914a5940bb1bfb82304cb276431f4.tar.zst dexon-solidity-5ae32b24a6b914a5940bb1bfb82304cb276431f4.zip |
Merge pull request #5113 from ethereum/compilerstack-datagas
Use GasEstimator::dataGas in CompilerStack
Diffstat (limited to 'libsolidity')
-rw-r--r-- | libsolidity/interface/CompilerStack.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/libsolidity/interface/CompilerStack.cpp b/libsolidity/interface/CompilerStack.cpp index adf59a9c..d1001c80 100644 --- a/libsolidity/interface/CompilerStack.cpp +++ b/libsolidity/interface/CompilerStack.cpp @@ -988,8 +988,7 @@ Json::Value CompilerStack::gasEstimates(string const& _contractName) const if (eth::AssemblyItems const* items = assemblyItems(_contractName)) { Gas executionGas = gasEstimator.functionalEstimation(*items); - u256 bytecodeSize(runtimeObject(_contractName).bytecode.size()); - Gas codeDepositGas = bytecodeSize * eth::GasCosts::createDataGas; + Gas codeDepositGas{eth::GasMeter::dataGas(runtimeObject(_contractName).bytecode, false)}; Json::Value creation(Json::objectValue); creation["codeDepositCost"] = gasToJson(codeDepositGas); |