Try to fix build failure

Failure: https://hydra.nixos.org/build/205357257/nixlog/1

The problem seems to be trying to `std::visit` a derived class of
`std::variant`. Per
https://stackoverflow.com/questions/63616709/incomplete-type-stdvariant-used-in-nested-name-specifier
certain C++ standard library implementations allow this, but others do
not.

The solution is simply to call the `raw` method, which upcasts the
reference back to the `std::variant`.
This commit is contained in:
John Ericson 2023-01-15 15:16:14 -05:00
parent 2e41ae9f93
commit f419ab48e6

View file

@ -319,7 +319,7 @@ OutputPathMap resolveDerivedPath(Store & store, const DerivedPath::Built & bfd,
[&](const OutputsSpec::Names & names) { [&](const OutputsSpec::Names & names) {
return static_cast<std::set<std::string>>(names); return static_cast<std::set<std::string>>(names);
}, },
}, bfd.outputs); }, bfd.outputs.raw());
for (auto & output : outputNames) { for (auto & output : outputNames) {
auto outputHash = get(outputHashes, output); auto outputHash = get(outputHashes, output);
if (!outputHash) if (!outputHash)