Skip to content

Version 0.0.4

Choose a tag to compare

@tintinweb tintinweb released this 13 Sep 18:04
· 79 commits to master since this release

v0.0.4

  • new: dynamic compiler selection via pragma directive
    • changing the solidity version pragma attempts to load the selected compiler version remotely. e.g. type pragma solidity 0.8.4 to switch to solidity v0.8.4.

example

playing with arithmetic underflows in solidity 0.8.7 (reverts) and 0.6.0 (underflows)

  node bin/main.js      
 
🚀 Entering interactive Solidity ^0.8.7 shell. '.help' and '.exit' are your friends.
 »  ℹ️  ganache-mgr: starting temp. ganache instance ...
 »
 »  
 »  uint(555)-uint(666)
Error: Returned error: VM Exception while processing transaction: revert
     {
  data: {
    '0xf56c7c173b51b91c89a49735fab75926b166e51a42b721a867d704612dcdd14b': {
      error: 'revert',
      program_counter: 232,
      return: '0x4e487b710000000000000000000000000000000000000000000000000000000000000011'
    },
    stack: 'c: VM Exception while processing transaction: revert\n' +
      '    at Function.c.fromResults (ganache-cli/build/ganache-core.node.cli.js:4:192416)\n' +
      '    at ganache-cli/build/ganache-core.node.cli.js:42:50402',
    name: 'c'
  }
}
 »  pragma solidity 0.6.0
 »  uint(555)-uint(666)
115792089237316195423570985008687907853269984665640564039457584007913129639825
 »