Try to fix issues with macos clang, v3

This commit is contained in:
Guillaume Maudoux 2022-03-18 15:35:24 +01:00
parent 726f5836d8
commit c2b620f3ad

View file

@ -759,7 +759,7 @@ LocalNoInlineNoReturn(void throwEvalErrorWithTrace(const char * s, const std::st
LocalNoInlineNoReturn(void throwEvalError(const Pos & pos, const Suggestions & suggestions, const char * s, const std::string & s2)) LocalNoInlineNoReturn(void throwEvalError(const Pos & pos, const Suggestions & suggestions, const char * s, const std::string & s2))
{ {
throw EvalError({ throw EvalError(ErrorInfo {
.msg = hintfmt(s, s2), .msg = hintfmt(s, s2),
.errPos = pos, .errPos = pos,
.suggestions = suggestions, .suggestions = suggestions,
@ -768,7 +768,7 @@ LocalNoInlineNoReturn(void throwEvalError(const Pos & pos, const Suggestions & s
LocalNoInlineNoReturn(void throwEvalError(const Pos & pos, const char * s, const Value & v)) LocalNoInlineNoReturn(void throwEvalError(const Pos & pos, const char * s, const Value & v))
{ {
throw EvalError({ throw EvalError(ErrorInfo {
.msg = hintfmt(s, showType(v)), .msg = hintfmt(s, showType(v)),
.errPos = pos .errPos = pos
}); });
@ -777,7 +777,7 @@ LocalNoInlineNoReturn(void throwEvalError(const Pos & pos, const char * s, const
LocalNoInlineNoReturn(void throwEvalError(const Pos & p1, const char * s, const Symbol & sym, const Pos & p2)) LocalNoInlineNoReturn(void throwEvalError(const Pos & p1, const char * s, const Symbol & sym, const Pos & p2))
{ {
// p1 is where the error occurred; p2 is a position mentioned in the message. // p1 is where the error occurred; p2 is a position mentioned in the message.
throw EvalError({ throw EvalError(ErrorInfo {
.msg = hintfmt(s, sym, p2), .msg = hintfmt(s, sym, p2),
.errPos = p1 .errPos = p1
}); });