mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Explicitly set coder to v1 for syntax tests.
This commit is contained in:
+1
@@ -1,3 +1,4 @@
|
||||
pragma abicoder v1;
|
||||
struct Item {
|
||||
uint x;
|
||||
uint y;
|
||||
|
||||
+3
-2
@@ -1,3 +1,4 @@
|
||||
pragma abicoder v1;
|
||||
struct Item {
|
||||
uint x;
|
||||
uint y;
|
||||
@@ -13,5 +14,5 @@ contract D {
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 7364: (202-240): Different number of components on the left hand side (1) than on the right hand side (2).
|
||||
// TypeError 9574: (202-240): Type uint256 is not implicitly convertible to expected type struct Item memory.
|
||||
// TypeError 7364: (222-260): Different number of components on the left hand side (1) than on the right hand side (2).
|
||||
// TypeError 9574: (222-260): Type uint256 is not implicitly convertible to expected type struct Item memory.
|
||||
|
||||
+1
@@ -9,6 +9,7 @@ library L {
|
||||
function set(Item storage _item) external view {}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract Test {
|
||||
|
||||
+2
-1
@@ -9,6 +9,7 @@ contract C {
|
||||
constructor(Item memory _item) {}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract Test {
|
||||
@@ -17,4 +18,4 @@ contract Test {
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 2443: (B:71-80): The type of this parameter, struct C.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
// TypeError 2443: (B:91-100): The type of this parameter, struct C.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
|
||||
+2
-1
@@ -9,6 +9,7 @@ contract C {
|
||||
function set(uint _x, string memory _y, Item memory _item, bool _z) external view {}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract Test {
|
||||
@@ -17,4 +18,4 @@ contract Test {
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 2443: (B:99-109): The type of this parameter, struct C.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
// TypeError 2443: (B:119-129): The type of this parameter, struct C.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
|
||||
+2
-1
@@ -9,6 +9,7 @@ contract C {
|
||||
function get(Item memory _item) external {}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract Test {
|
||||
@@ -19,4 +20,4 @@ contract Test {
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 2443: (B:146-155): The type of this parameter, struct C.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
// TypeError 2443: (B:166-175): The type of this parameter, struct C.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
|
||||
+2
-1
@@ -5,6 +5,7 @@ contract C {
|
||||
function f() external view returns (string[] memory) {}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract D {
|
||||
@@ -13,4 +14,4 @@ contract D {
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 2428: (B:65-85): The type of return parameter 1, string[], is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
// TypeError 2428: (B:85-105): The type of return parameter 1, string[], is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
|
||||
+2
-1
@@ -9,6 +9,7 @@ contract C {
|
||||
function get() external view returns(Item memory) {}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract Test {
|
||||
@@ -17,4 +18,4 @@ contract Test {
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 2428: (B:70-92): The type of return parameter 1, struct C.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
// TypeError 2428: (B:90-112): The type of return parameter 1, struct C.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
|
||||
+2
-1
@@ -9,6 +9,7 @@ contract C {
|
||||
function get() external view returns(Item memory) {}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract Test {
|
||||
@@ -17,4 +18,4 @@ contract Test {
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 2428: (B:70-92): The type of return parameter 1, struct C.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
// TypeError 2428: (B:90-112): The type of return parameter 1, struct C.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
|
||||
@@ -8,6 +8,7 @@ library L {
|
||||
event E(Item _value);
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract Test {
|
||||
@@ -16,4 +17,4 @@ contract Test {
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 2443: (B:74-84): The type of this parameter, struct L.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
// TypeError 2443: (B:94-104): The type of this parameter, struct L.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
|
||||
+2
-1
@@ -9,6 +9,7 @@ library L {
|
||||
function f(uint) external view returns (Item memory) {}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract D {
|
||||
@@ -19,4 +20,4 @@ contract D {
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 2428: (B:86-97): The type of return parameter 1, struct L.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
// TypeError 2428: (B:106-117): The type of return parameter 1, struct L.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
|
||||
+1
@@ -9,6 +9,7 @@ library L {
|
||||
function get(Item storage _item) external view {}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract Test {
|
||||
|
||||
+2
-1
@@ -9,6 +9,7 @@ library L {
|
||||
function get() external view returns(Item memory) {}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract Test {
|
||||
@@ -17,4 +18,4 @@ contract Test {
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 2428: (B:70-77): The type of return parameter 1, struct L.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
// TypeError 2428: (B:90-97): The type of return parameter 1, struct L.Item, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
|
||||
@@ -16,6 +16,7 @@ contract B {
|
||||
}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract C is B {
|
||||
|
||||
@@ -21,10 +21,12 @@ contract B {
|
||||
}
|
||||
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract C is B {}
|
||||
==== Source: C ====
|
||||
pragma abicoder v1;
|
||||
import "B";
|
||||
|
||||
contract D is C {
|
||||
|
||||
+1
@@ -19,6 +19,7 @@ contract B {
|
||||
}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract C is B {}
|
||||
|
||||
+1
@@ -9,6 +9,7 @@ contract C {
|
||||
event Ev(Item);
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract D is C {}
|
||||
|
||||
+2
-1
@@ -9,8 +9,9 @@ contract C {
|
||||
function get(Item memory) external view {}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract D is C {}
|
||||
// ----
|
||||
// TypeError 6594: (B:13-31): Contract "D" does not use ABI coder v2 but wants to inherit from a contract which uses types that require it. Use "pragma abicoder v2;" for the inheriting contract as well to enable the feature.
|
||||
// TypeError 6594: (B:33-51): Contract "D" does not use ABI coder v2 but wants to inherit from a contract which uses types that require it. Use "pragma abicoder v2;" for the inheriting contract as well to enable the feature.
|
||||
|
||||
+2
-1
@@ -9,8 +9,9 @@ contract C {
|
||||
function get() external view returns(Item memory) {}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract D is C {}
|
||||
// ----
|
||||
// TypeError 6594: (B:13-31): Contract "D" does not use ABI coder v2 but wants to inherit from a contract which uses types that require it. Use "pragma abicoder v2;" for the inheriting contract as well to enable the feature.
|
||||
// TypeError 6594: (B:33-51): Contract "D" does not use ABI coder v2 but wants to inherit from a contract which uses types that require it. Use "pragma abicoder v2;" for the inheriting contract as well to enable the feature.
|
||||
|
||||
+1
@@ -15,6 +15,7 @@ contract C {
|
||||
}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract D is C {}
|
||||
|
||||
@@ -17,6 +17,7 @@ contract B {
|
||||
}
|
||||
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract C is B {
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
==== Source: C ====
|
||||
pragma abicoder v1;
|
||||
import "X";
|
||||
import "V1A";
|
||||
import "V2A";
|
||||
@@ -14,6 +15,7 @@ contract C is V1A, V2A, V1B {
|
||||
}
|
||||
}
|
||||
==== Source: V1A ====
|
||||
pragma abicoder v1;
|
||||
import "X";
|
||||
|
||||
contract V1A {
|
||||
@@ -22,6 +24,7 @@ contract V1A {
|
||||
}
|
||||
}
|
||||
==== Source: V1B ====
|
||||
pragma abicoder v1;
|
||||
import "X";
|
||||
|
||||
contract V1B {
|
||||
|
||||
@@ -9,6 +9,7 @@ contract A {
|
||||
function get() public view returns (Data memory) {}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract B {
|
||||
@@ -18,6 +19,7 @@ contract B {
|
||||
}
|
||||
}
|
||||
==== Source: C ====
|
||||
pragma abicoder v1;
|
||||
import "B";
|
||||
|
||||
contract C is B {
|
||||
@@ -27,4 +29,4 @@ contract C is B {
|
||||
{}
|
||||
}
|
||||
// ----
|
||||
// TypeError 2428: (B:60-82): The type of return parameter 1, struct Data, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
// TypeError 2428: (B:80-102): The type of return parameter 1, struct Data, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
|
||||
@@ -9,6 +9,7 @@ contract A {
|
||||
function get() public view returns (Data memory) {}
|
||||
}
|
||||
==== Source: B ====
|
||||
pragma abicoder v1;
|
||||
import "A";
|
||||
|
||||
contract B {
|
||||
@@ -29,4 +30,4 @@ contract C is B {
|
||||
{}
|
||||
}
|
||||
// ----
|
||||
// TypeError 2428: (B:60-82): The type of return parameter 1, struct Data, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
// TypeError 2428: (B:80-102): The type of return parameter 1, struct Data, is only supported in ABI coder v2. Use "pragma abicoder v2;" to enable the feature.
|
||||
|
||||
Reference in New Issue
Block a user