aboutsummaryrefslogtreecommitdiff
path: root/src/libexpr/parser.y
diff options
context:
space:
mode:
authorGuillaume Maudoux <guillaume.maudoux@tweag.io>2022-09-11 01:34:19 +0200
committerGuillaume Maudoux <guillaume.maudoux@tweag.io>2022-09-11 01:34:19 +0200
commitc7b901fd33e817bfd8306a0e1b4f021ee3a209c9 (patch)
tree19386fe7bb7333762aae102f7a0b734f95910b57 /src/libexpr/parser.y
parenteb460a9529dd79995b6b788d59322fbc8f989214 (diff)
Cleanup error strings rebase
Diffstat (limited to 'src/libexpr/parser.y')
-rw-r--r--src/libexpr/parser.y6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libexpr/parser.y b/src/libexpr/parser.y
index 7768ed8df..a91b8b41f 100644
--- a/src/libexpr/parser.y
+++ b/src/libexpr/parser.y
@@ -396,7 +396,7 @@ expr_function
;
expr_if
- : IF expr THEN expr ELSE expr { $$ = new ExprIf(CUR_POS, $2, $4, $6); }
+ : IF expr THEN expr ELSE expr { $$ = new ExprIf(makeCurPos(@2, data), $2, $4, $6); }
| expr_op
;
@@ -788,13 +788,13 @@ Path EvalState::findFile(SearchPath & searchPath, const std::string_view path, c
if (hasPrefix(path, "nix/"))
return concatStrings(corepkgsPrefix, path.substr(4));
- debugThrowLastTrace(ThrownError({
+ debugThrow(ThrownError({
.msg = hintfmt(evalSettings.pureEval
? "cannot look up '<%s>' in pure evaluation mode (use '--impure' to override)"
: "file '%s' was not found in the Nix search path (add it using $NIX_PATH or -I)",
path),
.errPos = positions[pos]
- }));
+ }), 0, 0);
}