commit f8a97d4c7469252240cca8e98f4499eb404948d1
parent 63921cc5a0dc36be515fc5515b767fd8ac626cf5
Author: Sebastian <sebastian@sebsite.pw>
Date: Sun, 20 Mar 2022 00:51:16 -0400
parse: don't treat synassert msg as format string
Signed-off-by: Sebastian <sebastian@sebsite.pw>
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hare/parse/parse.ha b/hare/parse/parse.ha
@@ -90,7 +90,7 @@ fn peek(
// Returns a syntax error if cond is false and void otherwise
fn synassert(loc: lex::location, cond: bool, msg: str) (void | error) = {
if (!cond) {
- return syntaxerr(loc, msg);
+ return syntaxerr(loc, "{}", msg);
};
};