eval: Improve ExprConcatStrings error messages and positions
"while evaluating a path segment" was just plain wrong Co-authored-by: eldritch horrors <pennae@lix.systems> Change-Id: I827374635df2887d17a8ee8b1755c078bf0b506b
This commit is contained in:
co-authored by
eldritch horrors
parent
7017def185
commit
8782c7533f
@@ -13,10 +13,10 @@ Expect the trace to not contain any traceback:
|
||||
|
||||
nix-repl> f 2
|
||||
error:
|
||||
… while evaluating a path segment
|
||||
at «string»:1:13:
|
||||
… while concatenating
|
||||
at «string»:1:11:
|
||||
1| f = a: "" + a
|
||||
| ^
|
||||
| ^
|
||||
|
||||
error: cannot coerce an integer to a string: 2
|
||||
|
||||
@@ -37,10 +37,10 @@ Expect the trace to have traceback:
|
||||
1| f = a: "" + a
|
||||
| ^
|
||||
|
||||
… while evaluating a path segment
|
||||
at «string»:1:13:
|
||||
… while concatenating
|
||||
at «string»:1:11:
|
||||
1| f = a: "" + a
|
||||
| ^
|
||||
| ^
|
||||
|
||||
error: cannot coerce an integer to a string: 2
|
||||
|
||||
@@ -51,9 +51,9 @@ Turning it off should also work:
|
||||
|
||||
nix-repl> f 2
|
||||
error:
|
||||
… while evaluating a path segment
|
||||
at «string»:1:13:
|
||||
… while concatenating
|
||||
at «string»:1:11:
|
||||
1| f = a: "" + a
|
||||
| ^
|
||||
| ^
|
||||
|
||||
error: cannot coerce an integer to a string: 2
|
||||
|
||||
Reference in New Issue
Block a user