Commit 40a7dfe2 authored by Alina's avatar Alina Committed by GitHub

update solidity version to ^0.7.0 (#122)

* update solc version to ^0.7.0

* interfaces back to solidity >0.6.0 <0.8.0

* update solc to 0.7.6

* back to 0.7.4

* upgrade to 0.7.6, fix EXTCODESIZE check

* versions >0.5.0 <0.8.0 for xdomain msgers
parent fab8c869
......@@ -22,7 +22,7 @@ const config: BuidlerConfig = {
timeout: 50000,
},
solc: {
version: '0.7.4',
version: '0.7.6',
optimizer: { enabled: true, runs: 200 },
},
typechain: {
......
// SPDX-License-Identifier: MIT
// +build ovm
pragma solidity >0.6.0 <0.8.0;
pragma solidity >0.5.0 <0.8.0;
pragma experimental ABIEncoderV2;
/* Interface Imports */
......
// SPDX-License-Identifier: MIT
pragma solidity ^0.7.0;
pragma solidity >0.5.0 <0.8.0;
pragma experimental ABIEncoderV2;
/* Library Imports */
......
// SPDX-License-Identifier: MIT
// +build ovm
pragma solidity >0.6.0 <0.8.0;
pragma solidity >0.5.0 <0.8.0;
pragma experimental ABIEncoderV2;
/* Library Imports */
......@@ -23,7 +23,7 @@ contract OVM_L2CrossDomainMessenger is iOVM_L2CrossDomainMessenger, OVM_BaseCros
/***************
* Constructor *
***************/
/**
* @param _libAddressManager Address of the Address Manager.
*/
......
// SPDX-License-Identifier: MIT
// +build ovm
pragma solidity >0.6.0 <0.8.0;
pragma solidity >0.5.0 <0.8.0;
/* Interface Imports */
import { iOVM_ERC20 } from "../../iOVM/precompiles/iOVM_ERC20.sol";
......
// SPDX-License-Identifier: MIT
// +build ovm
pragma solidity >0.6.0 <0.8.0;
pragma solidity >0.5.0 <0.8.0;
/* Interface Imports */
import { iOVM_L2ToL1MessagePasser } from "../../iOVM/precompiles/iOVM_L2ToL1MessagePasser.sol";
......
// SPDX-License-Identifier: MIT
// +build ovm
pragma solidity >0.6.0 <0.8.0;
pragma solidity >0.5.0 <0.8.0;
pragma experimental ABIEncoderV2;
/**
......
......@@ -16,7 +16,7 @@ interface iOVM_L1CrossDomainMessenger is iOVM_BaseCrossDomainMessenger {
/*******************
* Data Structures *
*******************/
struct L2MessageInclusionProof {
bytes32 stateRoot;
Lib_OVMCodec.ChainBatchHeader stateRootBatchHeader;
......@@ -27,9 +27,9 @@ interface iOVM_L1CrossDomainMessenger is iOVM_BaseCrossDomainMessenger {
/********************
* Public Functions *
* Public Functions *
********************/
/**
* Relays a cross domain message to a contract.
* @param _target Target contract address.
......
// SPDX-License-Identifier: MIT
// +build ovm
pragma solidity >0.6.0 <0.8.0;
pragma solidity >0.5.0 <0.8.0;
pragma experimental ABIEncoderV2;
/* Interface Imports */
......@@ -12,7 +12,7 @@ import { iOVM_BaseCrossDomainMessenger } from "./iOVM_BaseCrossDomainMessenger.s
interface iOVM_L2CrossDomainMessenger is iOVM_BaseCrossDomainMessenger {
/********************
* Public Functions *
* Public Functions *
********************/
/**
......
......@@ -119,7 +119,7 @@ interface iOVM_StateCommitmentChain {
returns (
bool _inside
);
/**
* Sets the last batch index that can be deleted.
* @param _stateBatchHeader Proposed batch header that can be deleted.
......
......@@ -31,8 +31,8 @@ interface iOVM_StateManager {
* Public Functions: Setup *
***************************/
function owner() external view returns (address _owner);
function ovmExecutionManager() external view returns (address _ovmExecutionManager);
function owner() external view returns (address _owner);
function ovmExecutionManager() external view returns (address _ovmExecutionManager);
function setExecutionManager(address _ovmExecutionManager) external;
......@@ -59,7 +59,7 @@ interface iOVM_StateManager {
function wasAccountChanged(address _address) external view returns (bool);
function wasAccountCommitted(address _address) external view returns (bool);
/************************************
* Public Functions: Storage Access *
************************************/
......
......@@ -5,11 +5,11 @@ pragma solidity >0.5.0 <0.8.0;
* @title iOVM_DeployerWhitelist
*/
interface iOVM_DeployerWhitelist {
/********************
* Public Functions *
********************/
function initialize(address _owner, bool _allowArbitraryDeployment) external;
function setWhitelistedDeployer(address _deployer, bool _isWhitelisted) external;
function setOwner(address _newOwner) external;
......
// SPDX-License-Identifier: MIT
// +build ovm
pragma solidity >0.6.0 <0.8.0;
pragma solidity >0.5.0 <0.8.0;
/**
* @title iOVM_ERC20
......
// SPDX-License-Identifier: MIT
// +build ovm
pragma solidity >0.6.0 <0.8.0;
pragma solidity >0.5.0 <0.8.0;
/**
* @title iOVM_L1MessageSender
*/
interface iOVM_L1MessageSender {
/********************
* Public Functions *
********************/
function getL1MessageSender() external returns (address _l1MessageSender);
}
// SPDX-License-Identifier: MIT
// +build ovm
pragma solidity >0.6.0 <0.8.0;
pragma solidity >0.5.0 <0.8.0;
/**
* @title iOVM_L2ToL1MessagePasser
......
......@@ -64,7 +64,7 @@ interface iOVM_BondManager {
bool canClaim;
// Total number of `recordGasSpent` calls made
uint256 total;
// The gas spent by each user to provide witness data. The sum of all
// The gas spent by each user to provide witness data. The sum of all
// values inside this map MUST be equal to the value of `total`
mapping(address => uint256) gasSpent;
}
......@@ -73,7 +73,7 @@ interface iOVM_BondManager {
/********************
* Public Functions *
********************/
function recordGasSpent(
bytes32 _preStateRoot,
bytes32 _txHash,
......
......@@ -13,7 +13,7 @@ interface iOVM_StateTransitioner {
/**********
* Events *
**********/
event AccountCommitted(
address _address
);
......@@ -32,7 +32,7 @@ interface iOVM_StateTransitioner {
function getPostStateRoot() external view returns (bytes32 _postStateRoot);
function isComplete() external view returns (bool _complete);
/***********************************
* Public Functions: Pre-Execution *
***********************************/
......
// SPDX-License-Identifier: MIT
pragma solidity ^0.7.0;
pragma solidity >0.5.0 <0.8.0;
pragma experimental ABIEncoderV2;
/* Library Imports */
......
// SPDX-License-Identifier: MIT
// +build ovm
pragma solidity >0.6.0 <0.8.0;
pragma solidity >0.5.0 <0.8.0;
/* Contract Imports */
import { Ownable } from "./Lib_Ownable.sol";
......
// SPDX-License-Identifier: MIT
// +build ovm
pragma solidity >0.6.0 <0.8.0;
pragma solidity >0.5.0 <0.8.0;
/* Library Imports */
import { Lib_AddressManager } from "./Lib_AddressManager.sol";
......
// SPDX-License-Identifier: MIT
// +build ovm
pragma solidity >0.6.0 <0.8.0;
pragma solidity >0.5.0 <0.8.0;
/**
* @title Ownable
......@@ -55,7 +55,7 @@ abstract contract Ownable {
function renounceOwnership()
public
virtual
onlyOwner
onlyOwner
{
emit OwnershipTransferred(owner, address(0));
owner = address(0);
......
// SPDX-License-Identifier: MIT
pragma solidity ^0.7.0;
pragma solidity >0.5.0 <0.8.0;
pragma experimental ABIEncoderV2;
/* Library Imports */
......
// SPDX-License-Identifier: MIT
// +build ovm
pragma solidity >0.6.0 <0.8.0;
pragma solidity >0.5.0 <0.8.0;
/**
* @dev Contract module that helps prevent reentrant calls to a function.
......
......@@ -69,7 +69,7 @@ const test_ovmCREATEEOA: TestDefinition = {
address: '0x17ec8597ff92C3F44523bDc65BF0f1bE632917ff',
},
expectedReturnStatus: true,
expectedReturnValue: 1682,
expectedReturnValue: 1678,
},
],
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment