aboutsummaryrefslogtreecommitdiff
path: root/src/libexpr
diff options
context:
space:
mode:
authorQyriad <qyriad@qyriad.me>2024-07-07 18:45:06 -0600
committerQyriad <qyriad@qyriad.me>2024-08-01 00:37:03 +0000
commit4f6a3d7e9efafdcddedef0245475fdd4314fc54d (patch)
tree2519c4c30dcc5a8455b9815451f42690ebef0000 /src/libexpr
parent5ffed6d06aec09d5ece63fcbf2fa0a28ab73cb80 (diff)
libexpr: include the type of the non-derivation value in the type error
Change-Id: Id4717b5b0df7c09b0dbf17e642d8713a0a3efbae
Diffstat (limited to 'src/libexpr')
-rw-r--r--src/libexpr/get-drvs.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/libexpr/get-drvs.cc b/src/libexpr/get-drvs.cc
index fe4d3a7d5..d7869d09b 100644
--- a/src/libexpr/get-drvs.cc
+++ b/src/libexpr/get-drvs.cc
@@ -447,7 +447,8 @@ static void getDerivations(EvalState & state, Value & vIn,
return;
} else if (v.type() != nAttrs) {
state.error<TypeError>(
- "expression does not evaluate to a derivation (or a list or set of those)"
+ "expression was expected to be a derivation or collection of derivations, but instead was %s",
+ showType(v.type(), true)
).debugThrow();
}