1
1
Fork 0
mirror of https://github.com/NixOS/nix.git synced 2025-11-30 22:20:59 +01:00

Improve error messages from call-flake.nix

This commit is contained in:
Eelco Dolstra 2022-09-28 15:09:24 +02:00
parent 28b62dd3e0
commit a291e37b20
3 changed files with 12 additions and 8 deletions

View file

@ -704,14 +704,10 @@ void callFlake(EvalState & state,
vRootSubdir->mkString(lockedFlake.flake.lockedRef.subdir);
if (!state.vCallFlake) {
state.vCallFlake = allocRootValue(state.allocValue());
state.eval(state.parseExprFromString(
#include "call-flake.nix.gen.hh"
, state.rootPath("/")), **state.vCallFlake);
}
Value vCallFlake;
state.evalFile(state.callFlakeInternal, vCallFlake);
state.callFunction(**state.vCallFlake, *vLocks, *vTmp1, noPos);
state.callFunction(vCallFlake, *vLocks, *vTmp1, noPos);
state.callFunction(*vTmp1, *vRootSrc, *vTmp2, noPos);
state.callFunction(*vTmp2, *vRootSubdir, vRes, noPos);
}