Merge remote-tracking branch 'origin/develop' into breaking

This commit is contained in:
chriseth
2020-05-04 18:46:45 +02:00
51 changed files with 720 additions and 140 deletions
@@ -0,0 +1,9 @@
contract C
{
function f() public
{
int x = ~(0,);
}
}
// ----
// TypeError: (60-64): Tuple component cannot be empty.
@@ -0,0 +1,9 @@
contract C
{
function f() public
{
int x = --(,);
}
}
// ----
// TypeError: (59-64): Unary operator -- cannot be applied to type tuple(,)
@@ -0,0 +1,10 @@
contract C
{
function f() public
{
int x = delete (,0);
}
}
// ----
// TypeError: (68-69): Expression has to be an lvalue.
// TypeError: (59-70): Unary operator delete cannot be applied to type tuple(,int_const 0)
@@ -0,0 +1,9 @@
contract C
{
function f() public
{
(int x) = ++(,);
}
}
// ----
// TypeError: (61-66): Unary operator ++ cannot be applied to type tuple(,)
@@ -0,0 +1,20 @@
contract C
{
function f() public
{
int x = +(0, 0);
int y = -(0, 0);
(int z) = ~(0, 0);
(int t) = !(0, 0);
}
}
// ----
// SyntaxError: (59-66): Use of unary + is disallowed.
// TypeError: (59-66): Unary operator + cannot be applied to type tuple(int_const 0,int_const 0)
// TypeError: (51-66): Different number of components on the left hand side (1) than on the right hand side (2).
// TypeError: (84-91): Unary operator - cannot be applied to type tuple(int_const 0,int_const 0)
// TypeError: (76-91): Different number of components on the left hand side (1) than on the right hand side (2).
// TypeError: (111-118): Unary operator ~ cannot be applied to type tuple(int_const 0,int_const 0)
// TypeError: (101-118): Different number of components on the left hand side (1) than on the right hand side (2).
// TypeError: (138-145): Unary operator ! cannot be applied to type tuple(int_const 0,int_const 0)
// TypeError: (128-145): Different number of components on the left hand side (1) than on the right hand side (2).
@@ -0,0 +1,11 @@
contract C {
function f() public pure {
assembly {
setimmutable("abc", 0)
loadimmutable("abc")
}
}
}
// ----
// DeclarationError: (63-75): Function not found.
// DeclarationError: (92-105): Function not found.