forked from lix-project/lix
Fix #7655
We had some local variables left over from the older (more complicated) implementation of this function. They should all be unused, but one wasn't by mistake. Delete them all, and replace the one that was still in use as intended.
This commit is contained in:
parent
88d8f6ac48
commit
0afdf4084c
|
@ -83,15 +83,13 @@ static void prim_getContext(EvalState & state, const PosIdx pos, Value * * args,
|
||||||
state.forceString(*args[0], context, pos);
|
state.forceString(*args[0], context, pos);
|
||||||
auto contextInfos = std::map<StorePath, ContextInfo>();
|
auto contextInfos = std::map<StorePath, ContextInfo>();
|
||||||
for (const auto & p : context) {
|
for (const auto & p : context) {
|
||||||
Path drv;
|
|
||||||
std::string output;
|
|
||||||
NixStringContextElem ctx = NixStringContextElem::parse(*state.store, p);
|
NixStringContextElem ctx = NixStringContextElem::parse(*state.store, p);
|
||||||
std::visit(overloaded {
|
std::visit(overloaded {
|
||||||
[&](NixStringContextElem::DrvDeep & d) {
|
[&](NixStringContextElem::DrvDeep & d) {
|
||||||
contextInfos[d.drvPath].allOutputs = true;
|
contextInfos[d.drvPath].allOutputs = true;
|
||||||
},
|
},
|
||||||
[&](NixStringContextElem::Built & b) {
|
[&](NixStringContextElem::Built & b) {
|
||||||
contextInfos[b.drvPath].outputs.emplace_back(std::move(output));
|
contextInfos[b.drvPath].outputs.emplace_back(std::move(b.output));
|
||||||
},
|
},
|
||||||
[&](NixStringContextElem::Opaque & o) {
|
[&](NixStringContextElem::Opaque & o) {
|
||||||
contextInfos[o.path].path = true;
|
contextInfos[o.path].path = true;
|
||||||
|
|
Loading…
Reference in a new issue