about summary refs log tree commit diff
path: root/src/nix/installables.cc
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2018-01-16T16·11+0100
committerEelco Dolstra <edolstra@gmail.com>2018-01-16T16·11+0100
commit23fa7e3606a2bee6e3622a61f07e66bdda9b5304 (patch)
treedfda9be2b94dd1222037146791de90d0f5bf253e /src/nix/installables.cc
parentba75c69e0014178cf524cc07427bb4e9eac333f7 (diff)
parseExprFromFile -> evalFile
parseExprFromFile() should be avoided since it doesn't cache anything.
Diffstat (limited to 'src/nix/installables.cc')
-rw-r--r--src/nix/installables.cc6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/nix/installables.cc b/src/nix/installables.cc
index ae93c4ef649e..c3b06c22eba8 100644
--- a/src/nix/installables.cc
+++ b/src/nix/installables.cc
@@ -30,10 +30,8 @@ Value * SourceExprCommand::getSourceExpr(EvalState & state)
 
     vSourceExpr = state.allocValue();
 
-    if (file != "") {
-        Expr * e = state.parseExprFromFile(resolveExprPath(lookupFileArg(state, file)));
-        state.eval(e, *vSourceExpr);
-    }
+    if (file != "")
+        state.evalFile(lookupFileArg(state, file), *vSourceExpr);
 
     else {