Improve the Error class with a constructor for secondaryLocation

Remove occurances of Error construction using the boost helpers.
This commit is contained in:
Alex Beregszaszi
2020-12-17 13:50:04 +00:00
parent 2fa0e3c88a
commit 97173247c0
4 changed files with 92 additions and 99 deletions
+5 -2
View File
@@ -715,8 +715,11 @@ LinkerObject const& Assembly::assemble() const
if (!immutableReferencesBySub.empty())
throw
langutil::Error(1284_error, langutil::Error::Type::CodeGenerationError) <<
util::errinfo_comment("Some immutables were read from but never assigned, possibly because of optimization.");
langutil::Error(
1284_error,
langutil::Error::Type::CodeGenerationError,
"Some immutables were read from but never assigned, possibly because of optimization."
);
if (!m_subs.empty() || !m_data.empty() || !m_auxiliaryData.empty())
// Append an INVALID here to help tests find miscompilation.