mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Code adjustment after review
This commit is contained in:
@@ -7,5 +7,5 @@ function f() pure {
|
||||
}
|
||||
|
||||
// ----
|
||||
// TypeError 2271: (70-75): Binary operator + not compatible with types Int and Int. No matching user-defined operator found.
|
||||
// TypeError 2271: (81-88): Binary operator >>> not compatible with types Int and Int.
|
||||
// TypeError 2271: (70-75): Built-in binary operator + cannot be applied to types Int and Int. No matching user-defined operator found.
|
||||
// TypeError 2271: (81-88): Built-in binary operator >>> cannot be applied to types Int and Int.
|
||||
|
||||
+1
-1
@@ -21,4 +21,4 @@ function test() pure returns (Int) {
|
||||
}
|
||||
|
||||
// ----
|
||||
// TypeError 2271: (test.sol:181-206): Binary operator + not compatible with types Int and Int. Multiple user-defined functions provided for this operator.
|
||||
// TypeError 2271: (test.sol:181-206): Built-in binary operator + cannot be applied to types Int and Int. Multiple user-defined functions provided for this operator.
|
||||
|
||||
+6
-6
@@ -34,9 +34,9 @@ contract C {
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 2271: (421-426): Binary operator + not compatible with types struct S calldata and struct S calldata. No matching user-defined operator found.
|
||||
// TypeError 2271: (458-463): Binary operator + not compatible with types struct S storage ref and struct S storage ref. No matching user-defined operator found.
|
||||
// TypeError 2271: (495-500): Binary operator - not compatible with types struct S memory and struct S memory. No matching user-defined operator found.
|
||||
// TypeError 2271: (532-537): Binary operator - not compatible with types struct S storage ref and struct S storage ref. No matching user-defined operator found.
|
||||
// TypeError 2271: (571-576): Binary operator * not compatible with types struct S calldata and struct S calldata. No matching user-defined operator found.
|
||||
// TypeError 2271: (609-614): Binary operator * not compatible with types struct S memory and struct S memory. No matching user-defined operator found.
|
||||
// TypeError 2271: (421-426): Built-in binary operator + cannot be applied to types struct S calldata and struct S calldata. No matching user-defined operator found.
|
||||
// TypeError 2271: (458-463): Built-in binary operator + cannot be applied to types struct S storage ref and struct S storage ref. No matching user-defined operator found.
|
||||
// TypeError 2271: (495-500): Built-in binary operator - cannot be applied to types struct S memory and struct S memory. No matching user-defined operator found.
|
||||
// TypeError 2271: (532-537): Built-in binary operator - cannot be applied to types struct S storage ref and struct S storage ref. No matching user-defined operator found.
|
||||
// TypeError 2271: (571-576): Built-in binary operator * cannot be applied to types struct S calldata and struct S calldata. No matching user-defined operator found.
|
||||
// TypeError 2271: (609-614): Built-in binary operator * cannot be applied to types struct S memory and struct S memory. No matching user-defined operator found.
|
||||
|
||||
@@ -28,9 +28,9 @@ contract C {
|
||||
}
|
||||
|
||||
// ----
|
||||
// TypeError 2271: (311-316): Binary operator + not compatible with types struct S storage ref and struct S storage ref. No matching user-defined operator found.
|
||||
// TypeError 2271: (311-316): Built-in binary operator + cannot be applied to types struct S storage ref and struct S storage ref. No matching user-defined operator found.
|
||||
// TypeError 5653: (326-336): User defined binary operator + not compatible with types struct S memory and bool.
|
||||
// TypeError 2271: (346-354): Binary operator + not compatible with types bool and struct S storage ref.
|
||||
// TypeError 2271: (346-354): Built-in binary operator + cannot be applied to types bool and struct S storage ref.
|
||||
// TypeError 4907: (364-369): Built-in unary operator - cannot be applied to type struct S storage pointer. No matching user-defined operator found.
|
||||
// TypeError 4907: (379-381): Built-in unary operator - cannot be applied to type struct S storage ref. No matching user-defined operator found.
|
||||
// TypeError 4907: (391-396): Built-in unary operator - cannot be applied to type bool.
|
||||
|
||||
@@ -31,4 +31,4 @@ contract D is B {
|
||||
}
|
||||
|
||||
// ----
|
||||
// TypeError 2271: (542-567): Binary operator + not compatible with types Int and Int. No matching user-defined operator found.
|
||||
// TypeError 2271: (542-567): Built-in binary operator + cannot be applied to types Int and Int. No matching user-defined operator found.
|
||||
|
||||
+1
-1
@@ -25,4 +25,4 @@ contract C is B {
|
||||
}
|
||||
|
||||
// ----
|
||||
// TypeError 2271: (281-306): Binary operator + not compatible with types Int and Int. Multiple user-defined functions provided for this operator.
|
||||
// TypeError 2271: (281-306): Built-in binary operator + cannot be applied to types Int and Int. Multiple user-defined functions provided for this operator.
|
||||
|
||||
+1
-1
@@ -27,4 +27,4 @@ contract C {
|
||||
}
|
||||
|
||||
// ----
|
||||
// TypeError 2271: (s3.sol:81-106): Binary operator + not compatible with types Int and Int. No matching user-defined operator found.
|
||||
// TypeError 2271: (s3.sol:81-106): Built-in binary operator + cannot be applied to types Int and Int. No matching user-defined operator found.
|
||||
|
||||
@@ -29,6 +29,6 @@ function f() pure {
|
||||
// TypeError 8112: (47-50): The function "sub" needs to have one or two parameters of type Int and the same data location to be used for the operator -.
|
||||
// TypeError 7617: (61-64): The function "div" needs to have one or two parameters of type Int and the same data location to be used for the operator /.
|
||||
// TypeError 3605: (61-64): The function "div" needs to have parameters and return value of the same type to be used for the operator /.
|
||||
// TypeError 2271: (325-350): Binary operator + not compatible with types Int and Int. No matching user-defined operator found.
|
||||
// TypeError 2271: (356-381): Binary operator - not compatible with types Int and Int. No matching user-defined operator found.
|
||||
// TypeError 2271: (387-412): Binary operator / not compatible with types Int and Int. No matching user-defined operator found.
|
||||
// TypeError 2271: (325-350): Built-in binary operator + cannot be applied to types Int and Int. No matching user-defined operator found.
|
||||
// TypeError 2271: (356-381): Built-in binary operator - cannot be applied to types Int and Int. No matching user-defined operator found.
|
||||
// TypeError 2271: (387-412): Built-in binary operator / cannot be applied to types Int and Int. No matching user-defined operator found.
|
||||
|
||||
@@ -64,5 +64,5 @@ function test(S calldata s) pure {
|
||||
// TypeError 7617: (82-87): The function "unsub" needs to have one or two parameters of type S and the same data location to be used for the operator -.
|
||||
// TypeError 3605: (82-87): The function "unsub" needs to have parameters and return value of the same type to be used for the operator -.
|
||||
// TypeError 7743: (98-104): The function "bitnot" needs to return exactly one value of type S to be used for the operator ~.
|
||||
// TypeError 2271: (764-769): Binary operator * not compatible with types struct S calldata and struct S calldata. No matching user-defined operator found.
|
||||
// TypeError 2271: (764-769): Built-in binary operator * cannot be applied to types struct S calldata and struct S calldata. No matching user-defined operator found.
|
||||
// TypeError 4907: (797-799): Built-in unary operator - cannot be applied to type struct S calldata. No matching user-defined operator found.
|
||||
|
||||
@@ -59,5 +59,5 @@ contract C {
|
||||
// TypeError 7743: (68-71): The function "mod" needs to return exactly one value of type S to be used for the operator %.
|
||||
// TypeError 7743: (82-87): The function "unsub" needs to return exactly one value of type S to be used for the operator -.
|
||||
// TypeError 1147: (98-104): The function "bitnot" needs to have exactly one parameter of type S to be used for the operator ~.
|
||||
// TypeError 2271: (728-733): Binary operator * not compatible with types struct S storage ref and struct S storage ref. No matching user-defined operator found.
|
||||
// TypeError 2271: (728-733): Built-in binary operator * cannot be applied to types struct S storage ref and struct S storage ref. No matching user-defined operator found.
|
||||
// TypeError 4907: (785-787): Built-in unary operator ~ cannot be applied to type struct S storage ref. No matching user-defined operator found.
|
||||
|
||||
@@ -14,4 +14,4 @@ function test() {
|
||||
Int.wrap(0) + Int.wrap(1);
|
||||
}
|
||||
// ----
|
||||
// TypeError 2271: (213-238): Binary operator + not compatible with types Int and Int. Multiple user-defined functions provided for this operator.
|
||||
// TypeError 2271: (213-238): Built-in binary operator + cannot be applied to types Int and Int. Multiple user-defined functions provided for this operator.
|
||||
|
||||
Reference in New Issue
Block a user