1
1
Fork 0
mirror of https://github.com/NixOS/nix.git synced 2025-11-15 23:12:44 +01:00

Merge pull request #14502 from obsidiansystems/more-store-object-info-json-cleanup

More store object info json cleanup
This commit is contained in:
John Ericson 2025-11-10 20:26:12 +00:00 committed by GitHub
commit 68a5110fb9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
18 changed files with 111 additions and 78 deletions

View file

@ -114,4 +114,13 @@ struct adl_serializer<std::optional<T>>
}
};
template<typename T>
static inline std::optional<T> ptrToOwned(const json * ptr)
{
if (ptr)
return std::optional{*ptr};
else
return std::nullopt;
}
} // namespace nlohmann