mirror of
https://github.com/NixOS/nix
synced 2025-06-26 11:41:15 +02:00
Remove non-method mkPath()
This commit is contained in:
parent
263a8d293c
commit
ed93aec3c3
3 changed files with 7 additions and 9 deletions
|
@ -786,9 +786,9 @@ void Value::mkString(std::string_view s, const PathSet & context)
|
|||
}
|
||||
|
||||
|
||||
void mkPath(Value & v, const char * s)
|
||||
void Value::mkPath(std::string_view s)
|
||||
{
|
||||
v.mkPath(dupString(s));
|
||||
mkPath(dupStringWithLen(s.data(), s.size()));
|
||||
}
|
||||
|
||||
|
||||
|
@ -1711,8 +1711,7 @@ void ExprConcatStrings::eval(EvalState & state, Env & env, Value & v)
|
|||
else if (firstType == nPath) {
|
||||
if (!context.empty())
|
||||
throwEvalError(pos, "a string that refers to a store path cannot be appended to a path");
|
||||
auto path = canonPath(s.str());
|
||||
mkPath(v, path.c_str());
|
||||
v.mkPath(canonPath(s.str()));
|
||||
} else
|
||||
v.mkString(s.str(), context);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue