aboutsummaryrefslogtreecommitdiff
path: root/src/libexpr
diff options
context:
space:
mode:
authorThéophane Hufschmitt <theophane.hufschmitt@tweag.io>2022-11-14 15:00:05 +0100
committerThéophane Hufschmitt <theophane.hufschmitt@tweag.io>2022-11-14 15:00:05 +0100
commit8b4352d79b488a82321254b7ab531ff977816361 (patch)
tree50e0dfb0d22b82d49b82aac0cd7b80f5482deada /src/libexpr
parente7ed9ae0c711c4efd83756b16379549ecff52355 (diff)
parent302ddee749f1341895b3f18c7f430dfc13171985 (diff)
Merge remote-tracking branch 'nixos/master' into readFile-scan-references
Diffstat (limited to 'src/libexpr')
-rw-r--r--src/libexpr/eval.cc6
-rw-r--r--src/libexpr/flake/call-flake.nix2
-rw-r--r--src/libexpr/primops.cc4
3 files changed, 6 insertions, 6 deletions
diff --git a/src/libexpr/eval.cc b/src/libexpr/eval.cc
index e3716f217..563f24e48 100644
--- a/src/libexpr/eval.cc
+++ b/src/libexpr/eval.cc
@@ -904,7 +904,7 @@ void EvalState::throwEvalError(const char * s, const std::string & s2,
const std::string & s3)
{
debugThrowLastTrace(EvalError({
- .msg = hintfmt(s, s2),
+ .msg = hintfmt(s, s2, s3),
.errPos = positions[noPos]
}));
}
@@ -913,7 +913,7 @@ void EvalState::throwEvalError(const PosIdx pos, const char * s, const std::stri
const std::string & s3)
{
debugThrowLastTrace(EvalError({
- .msg = hintfmt(s, s2),
+ .msg = hintfmt(s, s2, s3),
.errPos = positions[pos]
}));
}
@@ -922,7 +922,7 @@ void EvalState::throwEvalError(const PosIdx pos, const char * s, const std::stri
const std::string & s3, Env & env, Expr & expr)
{
debugThrow(EvalError({
- .msg = hintfmt(s, s2),
+ .msg = hintfmt(s, s2, s3),
.errPos = positions[pos]
}), env, expr);
}
diff --git a/src/libexpr/flake/call-flake.nix b/src/libexpr/flake/call-flake.nix
index 932ac5e90..8061db3df 100644
--- a/src/libexpr/flake/call-flake.nix
+++ b/src/libexpr/flake/call-flake.nix
@@ -43,7 +43,7 @@ let
outputs = flake.outputs (inputs // { self = result; });
- result = outputs // sourceInfo // { inherit inputs; inherit outputs; inherit sourceInfo; };
+ result = outputs // sourceInfo // { inherit inputs; inherit outputs; inherit sourceInfo; _type = "flake"; };
in
if node.flake or true then
assert builtins.isFunction flake.outputs;
diff --git a/src/libexpr/primops.cc b/src/libexpr/primops.cc
index ff620ca63..22f6ad3cc 100644
--- a/src/libexpr/primops.cc
+++ b/src/libexpr/primops.cc
@@ -3826,8 +3826,8 @@ static RegisterPrimOp primop_parseDrvName({
.args = {"s"},
.doc = R"(
Split the string *s* into a package name and version. The package
- name is everything up to but not including the first dash followed
- by a digit, and the version is everything following that dash. The
+ name is everything up to but not including the first dash not followed
+ by a letter, and the version is everything following that dash. The
result is returned in a set `{ name, version }`. Thus,
`builtins.parseDrvName "nix-0.12pre12876"` returns `{ name =
"nix"; version = "0.12pre12876"; }`.