diff options
Diffstat (limited to 'test/libsolidity')
-rw-r--r-- | test/libsolidity/GasMeter.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/test/libsolidity/GasMeter.cpp b/test/libsolidity/GasMeter.cpp index 9f947af3..ebd5d774 100644 --- a/test/libsolidity/GasMeter.cpp +++ b/test/libsolidity/GasMeter.cpp @@ -120,8 +120,9 @@ BOOST_AUTO_TEST_CASE(non_overlapping_filtered_costs) if (first->first->location().intersects(second->first->location())) { BOOST_CHECK_MESSAGE(false, "Source locations should not overlap!"); - SourceReferenceFormatter::printSourceLocation(cout, first->first->location(), m_compiler.scanner()); - SourceReferenceFormatter::printSourceLocation(cout, second->first->location(), m_compiler.scanner()); + auto scannerFromSource = [&](string const&) -> Scanner const& { return m_compiler.scanner(); }; + SourceReferenceFormatter::printSourceLocation(cout, &first->first->location(), scannerFromSource); + SourceReferenceFormatter::printSourceLocation(cout, &second->first->location(), scannerFromSource); } } } |