Cache diagnostic message for easier access, and better extern C handling
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2019-06-19 15:49:44 +02:00
parent 7958576b6a
commit b76548da16
4 changed files with 26 additions and 6 deletions

View File

@@ -48,7 +48,7 @@ TEST_CASE( "Get full diagnostic message", "[integration]" ) {
REQUIRE(script->Diagnostics -> HasErrors());
auto diags = script->Diagnostics -> GetDiagnostics();
auto msg = script->Diagnostics->GetFullDiagnostic(&diags[0]);
REQUIRE(msg == "[Error] (2, 2) '\\x' is not a valid control character.");
REQUIRE(*msg == "[Error] (2, 2) '\\x' is not a valid control character.");
delete script;
}