diff options
author | John Hodge <tpg@mutabah.net> | 2015-09-19 18:16:36 +0800 |
---|---|---|
committer | John Hodge <tpg@mutabah.net> | 2015-09-19 18:16:36 +0800 |
commit | e6738ed57d644572e7cbefa6d68a4118935a5f80 (patch) | |
tree | a38b823d4b3771b045239a2f811eb63824a1032c /src/include/span.hpp | |
parent | 03e211d6eeb3f8f3c6f0b22f77c2074e81443952 (diff) | |
download | mrust-e6738ed57d644572e7cbefa6d68a4118935a5f80.tar.gz |
Disable UFCS resolve (due to ordering issues), fix Self handling
Diffstat (limited to 'src/include/span.hpp')
-rw-r--r-- | src/include/span.hpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/include/span.hpp b/src/include/span.hpp index c8c61627..452f37ba 100644 --- a/src/include/span.hpp +++ b/src/include/span.hpp @@ -52,5 +52,6 @@ struct Span void note(::std::function<void(::std::ostream&)> msg) const; }; -#define ERROR(span, code, msg) do { (span).error(code, [](::std::ostream& os) { os << msg; }); throw ::std::runtime_error("Error fell through" #code); } while(0) +#define ERROR(span, code, msg) do { (span).error(code, [&](::std::ostream& os) { os << msg; }); throw ::std::runtime_error("Error fell through" #code); } while(0) +#define BUG(span, msg) do { (span).bug([&](::std::ostream& os) { os << msg; }); throw ::std::runtime_error("Bug fell through"); } while(0) |