mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Add line info to serious exceptions.
This commit is contained in:
@@ -41,6 +41,9 @@ struct Exception: virtual std::exception, virtual boost::exception
|
||||
Exception(std::string _message = std::string()): m_message(std::move(_message)) {}
|
||||
const char* what() const noexcept override { return m_message.empty() ? std::exception::what() : m_message.c_str(); }
|
||||
|
||||
/// @returns "FileName:LineNumber" referring to the point where the exception was thrown.
|
||||
std::string lineInfo() const;
|
||||
|
||||
private:
|
||||
std::string m_message;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user