diff options
Diffstat (limited to 'test/libsolidity/SolidityNameAndTypeResolution.cpp')
-rw-r--r-- | test/libsolidity/SolidityNameAndTypeResolution.cpp | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/test/libsolidity/SolidityNameAndTypeResolution.cpp b/test/libsolidity/SolidityNameAndTypeResolution.cpp index e2e9f08a..4fe52243 100644 --- a/test/libsolidity/SolidityNameAndTypeResolution.cpp +++ b/test/libsolidity/SolidityNameAndTypeResolution.cpp @@ -6461,6 +6461,30 @@ BOOST_AUTO_TEST_CASE(builtin_reject_gas) } )"; CHECK_ERROR(text, TypeError, "Member \"gas\" not found or not visible after argument-dependent lookup"); + text = R"( + contract C { + function f() { + sha256.gas(); + } + } + )"; + CHECK_ERROR(text, TypeError, "Member \"gas\" not found or not visible after argument-dependent lookup"); + text = R"( + contract C { + function f() { + ripemd160.gas(); + } + } + )"; + CHECK_ERROR(text, TypeError, "Member \"gas\" not found or not visible after argument-dependent lookup"); + text = R"( + contract C { + function f() { + ecrecover.gas(); + } + } + )"; + CHECK_ERROR(text, TypeError, "Member \"gas\" not found or not visible after argument-dependent lookup"); } BOOST_AUTO_TEST_CASE(builtin_reject_value) |