diff options
author | Eelco Dolstra <e.dolstra@tudelft.nl> | 2011-08-06 13:02:55 +0000 |
---|---|---|
committer | Eelco Dolstra <e.dolstra@tudelft.nl> | 2011-08-06 13:02:55 +0000 |
commit | 54945a2950174ded83d58336061b4a9990cdbbfd (patch) | |
tree | 8789c505f73551e9a40d745cbb2858ddc683cd9c /src/nix-env/user-env.cc | |
parent | c8606664abe952f74985503c831d31ae7a7369bc (diff) |
* Refactoring: move parseExprFromFile() and parseExprFromString() into
the EvalState class.
Diffstat (limited to 'src/nix-env/user-env.cc')
-rw-r--r-- | src/nix-env/user-env.cc | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/nix-env/user-env.cc b/src/nix-env/user-env.cc index 865d24e2f..670052bcb 100644 --- a/src/nix-env/user-env.cc +++ b/src/nix-env/user-env.cc @@ -5,7 +5,6 @@ #include "globals.hh" #include "shared.hh" #include "eval.hh" -#include "parser.hh" #include "profiles.hh" @@ -24,7 +23,7 @@ DrvInfos queryInstalled(EvalState & state, const Path & userEnv) if (pathExists(manifestFile)) { Value v; - state.eval(parseExprFromFile(state, manifestFile), v); + state.evalFile(manifestFile, v); Bindings bindings; getDerivations(state, v, "", bindings, elems); } else if (pathExists(oldManifestFile)) @@ -113,7 +112,7 @@ bool createUserEnv(EvalState & state, DrvInfos & elems, /* Get the environment builder expression. */ Value envBuilder; - state.eval(parseExprFromFile(state, nixDataDir + "/nix/corepkgs/buildenv"), envBuilder); + state.evalFile(nixDataDir + "/nix/corepkgs/buildenv", envBuilder); /* Construct a Nix expression that calls the user environment builder with the manifest as argument. */ |