From 8ee5d3b274112d064328aa673496dfb484b03531 Mon Sep 17 00:00:00 2001 From: chriseth Date: Fri, 4 May 2018 16:20:38 +0200 Subject: New tests for wildcard assignments. --- .../syntaxTests/tupleAssignments/warn_fill_assignment.sol | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 test/libsolidity/syntaxTests/tupleAssignments/warn_fill_assignment.sol (limited to 'test/libsolidity/syntaxTests/tupleAssignments/warn_fill_assignment.sol') diff --git a/test/libsolidity/syntaxTests/tupleAssignments/warn_fill_assignment.sol b/test/libsolidity/syntaxTests/tupleAssignments/warn_fill_assignment.sol new file mode 100644 index 00000000..a079a509 --- /dev/null +++ b/test/libsolidity/syntaxTests/tupleAssignments/warn_fill_assignment.sol @@ -0,0 +1,11 @@ +contract C { + function f() public pure returns (uint, uint, bytes32) { + uint a; + bytes32 b; + (a,) = f(); + (,b) = f(); + } +} +// ---- +// Warning: (96-106): Different number of components on the left hand side (2) than on the right hand side (3). +// Warning: (110-120): Different number of components on the left hand side (2) than on the right hand side (3). -- cgit v1.2.3