Skip to content

Latest commit

 

History

History
65 lines (41 loc) · 1.53 KB

0.9.0.md

File metadata and controls

65 lines (41 loc) · 1.53 KB

Release notes - version 0.9.0


Notes about new/updated Features

Native Smart Contracts <> EVM Smart Contracts Interoperability

It is now possible for an EVM Smart Contract to invoke a Native Smart Contract function and vice-versa. The EVM Smart Contract can invoke a Native Smart Contract function using the following low-level functions:

  • staticcall
  • call

delegatecall and callcode cannot be used instead, they will return an error in case they are used with Native Smart Contracts.

In addition, it is possible to use the Solidity interface describing the Native Smart Contract. Files with the Native Smart Contract Solidity interfaces can be found under: qa/SidechainTestFramework/account/smart_contract_resources/contracts/.

Example of Native Smart Contract invocation in Solidity using low-level staticcall function:

 // ...
address contractAddr = address(0x0000000000000000000022222222222222222222);
(bool success, bytes memory result) = contractAddr.staticcall{gas: 100000}(
    abi.encodeWithSignature("getAllForgersStakes()")
);

 // ...

Example using Solidity interface:

import "./ForgerStakes.sol";

    // ...
    ForgerStakes nativeContract = ForgerStakes(0x0000000000000000000022222222222222222222);
    nativeContract.getAllForgersStakes{gas: 100000}();

    // ...
    

Update instructions from previous version


Bug Fixes


Improvements


Update test instructions from previous version

  • Install Python version 3.10

Full Changelog file here