mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-29 09:06:15 +02:00
* toPath: should be the identity on paths.
This commit is contained in:
parent
cba913c521
commit
be1961c9f8
1 changed files with 1 additions and 3 deletions
|
@ -343,9 +343,7 @@ static Expr primToString(EvalState & state, const ATermVector & args)
|
||||||
static Expr primToPath(EvalState & state, const ATermVector & args)
|
static Expr primToPath(EvalState & state, const ATermVector & args)
|
||||||
{
|
{
|
||||||
PathSet context;
|
PathSet context;
|
||||||
string path = evalString(state, args[0], context);
|
string path = coerceToPath(state, args[0], context);
|
||||||
if (path == "" || path[0] != '/')
|
|
||||||
throw EvalError("string doesn't represent an absolute path in `toPath'");
|
|
||||||
return makeStr(canonPath(path), context);
|
return makeStr(canonPath(path), context);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue