mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-25 07:16:17 +02:00
Merge pull request #10861 from DeterminateSystems/fix-optional-deref
PackageInfo::queryDrvPath(): Don't dereference an empty optional
This commit is contained in:
commit
edd445f745
2 changed files with 2 additions and 3 deletions
|
@ -82,8 +82,7 @@ std::optional<StorePath> PackageInfo::queryDrvPath() const
|
||||||
} else
|
} else
|
||||||
drvPath = {std::nullopt};
|
drvPath = {std::nullopt};
|
||||||
}
|
}
|
||||||
drvPath.value_or(std::nullopt);
|
return drvPath.value_or(std::nullopt);
|
||||||
return *drvPath;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -278,7 +278,7 @@ private:
|
||||||
storePath = state.coerceToStorePath(i->pos, *i->value, context, "while evaluating the drvPath of a derivation");
|
storePath = state.coerceToStorePath(i->pos, *i->value, context, "while evaluating the drvPath of a derivation");
|
||||||
}
|
}
|
||||||
|
|
||||||
/* This unforutately breaks printing nested values because of
|
/* This unfortunately breaks printing nested values because of
|
||||||
how the pretty printer is used (when pretting printing and warning
|
how the pretty printer is used (when pretting printing and warning
|
||||||
to same terminal / std stream). */
|
to same terminal / std stream). */
|
||||||
#if 0
|
#if 0
|
||||||
|
|
Loading…
Reference in a new issue