1
1
Fork 0
mirror of https://github.com/NixOS/nix.git synced 2025-12-07 01:21:00 +01:00

Fix gcc 12 warnings

This commit is contained in:
Eelco Dolstra 2024-02-28 22:59:20 +01:00
parent 90ec015d61
commit 65bb12ba78
5 changed files with 11 additions and 1 deletions

View file

@ -123,6 +123,11 @@ struct KeyedBuildResult : BuildResult
* The derivation we built or the store path we substituted.
*/
DerivedPath path;
// Hack to work around a gcc "may be used uninitialized" warning.
KeyedBuildResult(BuildResult res, DerivedPath path)
: BuildResult(std::move(res)), path(std::move(path))
{ }
};
}