Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/extcodehash #2075

Merged
merged 42 commits into from Apr 16, 2019

Conversation

@llwslc
Copy link
Member

commented Mar 27, 2019

What does this PR do?
To provide a new opcode, which returns the keccak256 hash of a contract's code.

Why are these changes required?
Many contracts need to perform checks on a contract's bytecode, but do not necessarily need the bytecode itself.

This PR has been tested by:

  • Unit Tests
  • Manual Testing

Follow up

Extra details
tronprotocol/TIPs#30

ithinker1991 and others added some commits Mar 11, 2019

@codecov-io

This comment has been minimized.

Copy link

commented Mar 27, 2019

Codecov Report

Merging #2075 into develop will increase coverage by 1.45%.
The diff coverage is 62.2%.

Impacted file tree graph

@@              Coverage Diff              @@
##             develop    #2075      +/-   ##
=============================================
+ Coverage      43.46%   44.92%   +1.45%     
- Complexity      4036     4219     +183     
=============================================
  Files            510      503       -7     
  Lines          29596    29935     +339     
  Branches        3054     3119      +65     
=============================================
+ Hits           12863    13447     +584     
+ Misses         15569    15263     -306     
- Partials        1164     1225      +61
Impacted Files Coverage Δ Complexity Δ
...org/tron/core/actuator/ProposalCreateActuator.java 42.3% <0%> (-1.35%) 23 <0> (ø)
src/main/java/org/tron/core/db/Manager.java 43.02% <0%> (-0.25%) 120 <0> (+3)
...java/org/tron/core/witness/ProposalController.java 49.53% <0%> (-0.95%) 14 <0> (ø)
...g/tron/common/runtime/vm/PrecompiledContracts.java 7.11% <0%> (-0.07%) 2 <0> (ø)
...main/java/org/tron/common/runtime/RuntimeImpl.java 63.52% <100%> (+0.27%) 56 <0> (+2) ⬆️
...c/main/java/org/tron/common/runtime/vm/OpCode.java 98.48% <100%> (+0.54%) 17 <0> (ø) ⬇️
...in/java/org/tron/common/runtime/vm/EnergyCost.java 72.97% <100%> (+0.49%) 27 <1> (+1) ⬆️
src/main/java/org/tron/core/config/Parameter.java 100% <100%> (ø) 0 <0> (ø) ⬇️
src/main/java/org/tron/core/Wallet.java 14.77% <15.38%> (+0.57%) 45 <1> (+3) ⬆️
.../java/org/tron/common/runtime/config/VMConfig.java 71.42% <57.14%> (-2.49%) 13 <5> (+2)
... and 190 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b697169...512170b. Read the comment docs.

@ithinker1991 ithinker1991 merged commit 512170b into develop Apr 16, 2019

1 check passed

continuous-integration/travis-ci/push The Travis CI build passed
Details
@jeancky

This comment has been minimized.

Copy link
Contributor

commented May 24, 2019

refer to #2238 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants
You can’t perform that action at this time.