From de6c34757792a70b692c3fdec1e7bcfb4e1e6e49 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kamil=20=C5=9Aliwak?= Date: Fri, 7 Apr 2023 14:07:49 +0200 Subject: [PATCH] Disallow using overloaded functions as literal suffixes --- libsolidity/analysis/TypeChecker.cpp | 115 ++---------------- libsolidity/analysis/TypeChecker.h | 1 - .../overloaded_suffix_in_abi_encode.sol | 17 --- .../parameters/overloading.sol | 2 + .../overloading_address_vs_payable.sol | 2 +- ...ween_suffix_and_function_allowed_calls.sol | 2 + ...n_suffix_and_function_disallowed_calls.sol | 2 +- ...rloading_decimal_mantissa_out_of_range.sol | 2 +- .../overloading_decimal_vs_decimal.sol | 2 + ...ding_decimal_vs_decimal_ambiguous_sign.sol | 2 +- ...ding_decimal_vs_decimal_ambiguous_size.sol | 2 +- .../overloading_imported_suffix.sol | 2 + .../overloading_integer_vs_decimal.sol | 2 + ...erloading_integer_vs_decimal_ambiguous.sol | 2 +- .../overloading_integer_vs_integer.sol | 2 + ...ding_integer_vs_integer_ambiguous_sign.sol | 2 +- ...ding_integer_vs_integer_ambiguous_size.sol | 2 +- .../parameters/overloading_qualified.sol | 2 + .../overloading_string_vs_bytes.sol | 2 + .../overloading_string_vs_bytes_ambiguous.sol | 2 +- .../overloading_with_attached_functions.sol | 2 +- ..._with_unimplemented_contract_functions.sol | 2 +- ...overloaded_contract_function_as_suffix.sol | 2 +- .../invalid_revert_as_suffix.sol | 2 +- 24 files changed, 41 insertions(+), 134 deletions(-) delete mode 100644 test/libsolidity/semanticTests/literalSuffixes/overloaded_suffix_in_abi_encode.sol diff --git a/libsolidity/analysis/TypeChecker.cpp b/libsolidity/analysis/TypeChecker.cpp index 6df789ba3..50e19cb90 100644 --- a/libsolidity/analysis/TypeChecker.cpp +++ b/libsolidity/analysis/TypeChecker.cpp @@ -3021,10 +3021,6 @@ void TypeChecker::typeCheckFunctionGeneralChecks( bool TypeChecker::visit(FunctionCall const& _functionCall) { - solAssert(!m_currentSuffixCall); - if (_functionCall.isSuffixCall()) - m_currentSuffixCall = &_functionCall; - vector> const& arguments = _functionCall.arguments(); bool argumentsArePure = true; @@ -3045,7 +3041,8 @@ bool TypeChecker::visit(FunctionCall const& _functionCall) for (ASTPointer const& argument: arguments) funcCallArgs.types.push_back(type(*argument)); - _functionCall.expression().annotation().arguments = std::move(funcCallArgs); + if (!_functionCall.isSuffixCall()) + _functionCall.expression().annotation().arguments = std::move(funcCallArgs); } _functionCall.expression().accept(*this); @@ -3220,7 +3217,6 @@ bool TypeChecker::visit(FunctionCall const& _functionCall) break; } - m_currentSuffixCall = nullptr; return false; } @@ -3439,62 +3435,15 @@ bool TypeChecker::visit(MemberAccess const& _memberAccess) size_t const initialMemberCount = possibleMembers.size(); if (initialMemberCount > 1 && arguments) { - RationalNumberType const* mantissa = nullptr; - RationalNumberType const* exponent = nullptr; - RationalNumberType const* literalRationalType = nullptr; - if (m_currentSuffixCall) - { - if (annotation.arguments->types.size() == 1) - { - solAssert(annotation.arguments->types[0]); - literalRationalType = dynamic_cast(annotation.arguments->types[0]); - if (literalRationalType) - tie(mantissa, exponent) = literalRationalType->fractionalDecomposition(); - } - } - // do overload resolution for (auto it = possibleMembers.begin(); it != possibleMembers.end();) - { - bool viableCandidate = false; - if (it->type->category() == Type::Category::Function) - { - FunctionTypePointer functionType = dynamic_cast(it->type); - solAssert(functionType); - - if (!m_currentSuffixCall || m_currentSuffixCall->expression() != _memberAccess) - viableCandidate = functionType->canTakeArguments(*arguments, exprType); - else - { - // NOTE: We're before type-checking of suffix calls so we can't yet assume that - // the suffix is not something weird, including being a bound function. - - auto const* functionDefinition = dynamic_cast(it->declaration); - - bool isSuffixFunction = - functionDefinition && - functionDefinition->usableAsSuffix(); - bool singleArgumentMatch = - functionType->parameterTypes().size() == 1 && - functionType->canTakeArguments(*annotation.arguments); - bool mantissaExponentMatch = - functionType->parameterTypes().size() == 2 && - literalRationalType && - // NOTE: If the literal cannot be decomposed it's fine to act as if suffix could not take it. - // It will be reported as error when type-checking the suffix call anyway. - mantissa && - exponent && - functionType->canTakeArguments({{mantissa, exponent}, {}}); - - viableCandidate = isSuffixFunction && (singleArgumentMatch || mantissaExponentMatch); - } - } - - if (viableCandidate) - ++it; - else + if ( + it->type->category() == Type::Category::Function && + !dynamic_cast(*it->type).canTakeArguments(*arguments, exprType) + ) it = possibleMembers.erase(it); - } + else + ++it; } annotation.isConstant = false; @@ -4004,8 +3953,6 @@ bool TypeChecker::visit(Identifier const& _identifier) annotation.referencedDeclaration = *annotation.overloadedDeclarations.begin(); else if (!annotation.arguments) { - solAssert(!m_currentSuffixCall); - // The identifier should be a public state variable shadowing other functions vector candidates; @@ -4023,54 +3970,16 @@ bool TypeChecker::visit(Identifier const& _identifier) } else { - vector candidates; + // NOTE: Suffix calls intentionally have no 'arguments' annotation so that they never enter this branch. - RationalNumberType const* mantissa = nullptr; - RationalNumberType const* exponent = nullptr; - RationalNumberType const* literalRationalType = nullptr; - if (m_currentSuffixCall) - { - if (annotation.arguments->types.size() == 1) - { - solAssert(annotation.arguments->types[0]); - literalRationalType = dynamic_cast(annotation.arguments->types[0]); - if (literalRationalType) - tie(mantissa, exponent) = literalRationalType->fractionalDecomposition(); - } - } + vector candidates; for (Declaration const* declaration: annotation.overloadedDeclarations) { FunctionTypePointer functionType = declaration->functionType(true /* _internal */); solAssert(!!functionType, "Requested type not present."); - - if (!m_currentSuffixCall) - { - if (functionType->canTakeArguments(*annotation.arguments)) - candidates.push_back(declaration); - } - else - { - auto const* functionDefinition = dynamic_cast(declaration); - - bool isSuffixFunction = - functionDefinition && - functionDefinition->usableAsSuffix(); - bool singleArgumentMatch = - functionType->parameterTypes().size() == 1 && - functionType->canTakeArguments(*annotation.arguments); - bool mantissaExponentMatch = - functionType->parameterTypes().size() == 2 && - literalRationalType && - // NOTE: If the literal cannot be decomposed it's fine to act as if suffix could not take it. - // It will be reported as error when type-checking the suffix call anyway. - mantissa && - exponent && - functionType->canTakeArguments({{mantissa, exponent}, {}}); - - if (isSuffixFunction && (singleArgumentMatch || mantissaExponentMatch)) - candidates.push_back(declaration); - } + if (functionType->canTakeArguments(*annotation.arguments)) + candidates.push_back(declaration); } if (candidates.size() == 1) annotation.referencedDeclaration = candidates.front(); diff --git a/libsolidity/analysis/TypeChecker.h b/libsolidity/analysis/TypeChecker.h index 1a7902cd6..fb33f51f4 100644 --- a/libsolidity/analysis/TypeChecker.h +++ b/libsolidity/analysis/TypeChecker.h @@ -206,7 +206,6 @@ private: SourceUnit const* m_currentSourceUnit = nullptr; ContractDefinition const* m_currentContract = nullptr; - FunctionCall const* m_currentSuffixCall = nullptr; langutil::EVMVersion m_evmVersion; diff --git a/test/libsolidity/semanticTests/literalSuffixes/overloaded_suffix_in_abi_encode.sol b/test/libsolidity/semanticTests/literalSuffixes/overloaded_suffix_in_abi_encode.sol deleted file mode 100644 index d1713769d..000000000 --- a/test/libsolidity/semanticTests/literalSuffixes/overloaded_suffix_in_abi_encode.sol +++ /dev/null @@ -1,17 +0,0 @@ -function suffix(uint x) pure suffix returns (uint) { return x; } -function suffix(bool x) pure suffix returns (bool) { return x; } -function suffix(address x) pure suffix returns (address) { return x; } -function suffix(string memory x) pure suffix returns (string memory) { return x; } - -contract C { - function run() public returns (bytes memory) { - return abi.encode( - 42 suffix, - true suffix, - 0x1234567890123456789012345678901234567890 suffix, - "a" suffix - ); - } -} -// ---- -// run() -> 0x20, 0xc0, 0x2a, 1, 0x1234567890123456789012345678901234567890, 0x80, 1, "a" diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading.sol index 0eff69e36..a4632e109 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading.sol @@ -9,3 +9,5 @@ contract C { address c = 0x1234567890123456789012345678901234567890 suffix; string d = "a" suffix; } +// ---- +// TypeError 2144: (259-265): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_address_vs_payable.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_address_vs_payable.sol index d87ceccd8..1f07b7814 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_address_vs_payable.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_address_vs_payable.sol @@ -6,4 +6,4 @@ contract C { } // ---- // TypeError 2998: (74-89): This literal suffix function is not usable as a suffix because no literal is implicitly convertible to its parameter type. -// TypeError 7407: (170-219): Type address is not implicitly convertible to expected type address payable. +// TypeError 2144: (213-219): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_between_suffix_and_function_allowed_calls.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_between_suffix_and_function_allowed_calls.sol index 1dd32f9f3..b9d3451b2 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_between_suffix_and_function_allowed_calls.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_between_suffix_and_function_allowed_calls.sol @@ -17,3 +17,5 @@ contract C { f("a"); } } +// ---- +// TypeError 2144: (268-269): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_between_suffix_and_function_disallowed_calls.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_between_suffix_and_function_disallowed_calls.sol index f3c0d63ed..d3f9aea09 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_between_suffix_and_function_disallowed_calls.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_between_suffix_and_function_disallowed_calls.sol @@ -10,4 +10,4 @@ contract C { } } // ---- -// TypeError 9322: (208-209): No matching declaration found after argument-dependent lookup. +// TypeError 2144: (162-163): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_mantissa_out_of_range.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_mantissa_out_of_range.sol index 593a63649..cc52cd25e 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_mantissa_out_of_range.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_mantissa_out_of_range.sol @@ -5,4 +5,4 @@ contract C { int32 a = 115792089237316195423570985008687907853269984665640564039457584007913129639936 uSuffix; // 2**256 } // ---- -// TypeError 9322: (229-236): No matching declaration found after argument-dependent lookup. +// TypeError 2144: (229-236): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_vs_decimal.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_vs_decimal.sol index 7856c47b4..9b5b62f52 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_vs_decimal.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_vs_decimal.sol @@ -17,3 +17,5 @@ contract C { int e = 2.55 iuSuffix; int f = -2.55 iuSuffix; } +// ---- +// TypeError 2144: (392-399): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_vs_decimal_ambiguous_sign.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_vs_decimal_ambiguous_sign.sol index 2c8d110c5..39a735f47 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_vs_decimal_ambiguous_sign.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_vs_decimal_ambiguous_sign.sol @@ -5,4 +5,4 @@ contract C { uint a = 1.27 iuSuffix; } // ---- -// TypeError 4487: (151-159): No unique declaration found after argument-dependent lookup. +// TypeError 2144: (151-159): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_vs_decimal_ambiguous_size.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_vs_decimal_ambiguous_size.sol index b65bb66a3..356ec3295 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_vs_decimal_ambiguous_size.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_decimal_vs_decimal_ambiguous_size.sol @@ -5,4 +5,4 @@ contract C { uint a = 1.27 uSuffix; } // ---- -// TypeError 4487: (151-158): No unique declaration found after argument-dependent lookup. +// TypeError 2144: (151-158): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_imported_suffix.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_imported_suffix.sol index afea8f875..eb9d5228f 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_imported_suffix.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_imported_suffix.sol @@ -29,3 +29,5 @@ contract D { "a" f; } } +// ---- +// TypeError 2144: (B.sol:201-202): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_decimal.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_decimal.sol index 67bf0346a..b558cb199 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_decimal.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_decimal.sol @@ -11,3 +11,5 @@ contract C { // Not ambiguous: 1024 won't fit into uint8. bool b = 1024 suffix8; } +// ---- +// TypeError 2144: (325-334): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_decimal_ambiguous.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_decimal_ambiguous.sol index a575e1a5e..815df180d 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_decimal_ambiguous.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_decimal_ambiguous.sol @@ -7,4 +7,4 @@ contract C { } } // ---- -// TypeError 4487: (176-182): No unique declaration found after argument-dependent lookup. +// TypeError 2144: (176-182): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_integer.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_integer.sol index 32d8e5f04..0b9bd7b92 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_integer.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_integer.sol @@ -17,3 +17,5 @@ contract C { int e = 255 iuSuffix; int f = -255 iuSuffix; } +// ---- +// TypeError 2144: (355-362): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_integer_ambiguous_sign.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_integer_ambiguous_sign.sol index 25d36da38..e38b4826f 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_integer_ambiguous_sign.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_integer_ambiguous_sign.sol @@ -5,4 +5,4 @@ contract C { int a = 127 iuSuffix; } // ---- -// TypeError 4487: (137-145): No unique declaration found after argument-dependent lookup. +// TypeError 2144: (137-145): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_integer_ambiguous_size.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_integer_ambiguous_size.sol index 59cd105e9..f75bccd9c 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_integer_ambiguous_size.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_integer_vs_integer_ambiguous_size.sol @@ -5,4 +5,4 @@ contract C { int a = 127 uSuffix; } // ---- -// TypeError 4487: (137-144): No unique declaration found after argument-dependent lookup. +// TypeError 2144: (137-144): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_qualified.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_qualified.sol index d301d08b5..276539410 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_qualified.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_qualified.sol @@ -13,3 +13,5 @@ contract C { address c = 0x1234567890123456789012345678901234567890 A.suffix; string d = "a" A.suffix; } +// ---- +// TypeError 6675: (B.sol:49-57): Member "suffix" not unique after argument-dependent lookup in module "A.sol". diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_string_vs_bytes.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_string_vs_bytes.sol index f9dc96f8e..85392d74c 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_string_vs_bytes.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_string_vs_bytes.sol @@ -4,3 +4,5 @@ function suffix(bytes memory) pure suffix returns (bytes memory) {} contract C { bytes a = hex"abcd" suffix; } +// ---- +// TypeError 2144: (176-182): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_string_vs_bytes_ambiguous.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_string_vs_bytes_ambiguous.sol index edff07964..1d8d9f0d6 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_string_vs_bytes_ambiguous.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_string_vs_bytes_ambiguous.sol @@ -5,4 +5,4 @@ contract C { uint a = "abcd" suffix; } // ---- -// TypeError 4487: (155-161): No unique declaration found after argument-dependent lookup. +// TypeError 2144: (155-161): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_with_attached_functions.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_with_attached_functions.sol index 3069b9c50..55a82240b 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_with_attached_functions.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_with_attached_functions.sol @@ -11,4 +11,4 @@ contract C { } } // ---- -// TypeError 9582: (218-226): Member "suffix" not found or not visible after argument-dependent lookup in uint8. +// TypeError 6675: (218-226): Member "suffix" not unique after argument-dependent lookup in uint8. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_with_unimplemented_contract_functions.sol b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_with_unimplemented_contract_functions.sol index 99044b8fd..bdebfd65f 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_with_unimplemented_contract_functions.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/parameters/overloading_with_unimplemented_contract_functions.sol @@ -7,4 +7,4 @@ abstract contract C { } } // ---- -// TypeError 9322: (194-200): No matching declaration found after argument-dependent lookup. +// TypeError 2144: (194-200): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/usableAsSuffix/invalid_overloaded_contract_function_as_suffix.sol b/test/libsolidity/syntaxTests/literalSuffixes/usableAsSuffix/invalid_overloaded_contract_function_as_suffix.sol index 627a6268c..c8499c6b2 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/usableAsSuffix/invalid_overloaded_contract_function_as_suffix.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/usableAsSuffix/invalid_overloaded_contract_function_as_suffix.sol @@ -5,4 +5,4 @@ contract C { function suffix(address) public pure returns (uint) {} } // ---- -// TypeError 9322: (31-37): No matching declaration found after argument-dependent lookup. +// TypeError 2144: (31-37): No matching declaration found after variable lookup. diff --git a/test/libsolidity/syntaxTests/literalSuffixes/usableAsSuffix/invalid_revert_as_suffix.sol b/test/libsolidity/syntaxTests/literalSuffixes/usableAsSuffix/invalid_revert_as_suffix.sol index 95cbc8a95..b6a572757 100644 --- a/test/libsolidity/syntaxTests/literalSuffixes/usableAsSuffix/invalid_revert_as_suffix.sol +++ b/test/libsolidity/syntaxTests/literalSuffixes/usableAsSuffix/invalid_revert_as_suffix.sol @@ -4,4 +4,4 @@ contract C { } } // ---- -// TypeError 9322: (54-60): No matching declaration found after argument-dependent lookup. +// TypeError 2144: (54-60): No matching declaration found after variable lookup.