1313
1414namespace vcpkg
1515{
16- // / <summary>
17- // / Installed package metadata
18- // / </summary>
16+
17+ // metadata for a package's representation in the 'installed' tree
1918 struct StatusParagraph
2019 {
2120 StatusParagraph () noexcept ;
@@ -30,14 +29,12 @@ namespace vcpkg
3029
3130 void serialize (const StatusParagraph& pgh, std::string& out_str);
3231
33- std::string to_string (InstallState f);
34-
35- std::string to_string (Want f);
32+ StringLiteral to_string_literal (InstallState f);
33+ StringLiteral to_string_literal (Want f);
3634
3735 struct InstalledPackageView
3836 {
39- InstalledPackageView () noexcept : core(nullptr ) { }
40-
37+ InstalledPackageView () = default ;
4138 InstalledPackageView (const StatusParagraph* c, std::vector<const StatusParagraph*>&& fs)
4239 : core(c), features(std::move(fs))
4340 {
@@ -51,11 +48,14 @@ namespace vcpkg
5148
5249 std::vector<StatusParagraph> all_status_paragraphs () const ;
5350
54- const StatusParagraph* core;
51+ const StatusParagraph* core = nullptr ;
5552 std::vector<const StatusParagraph*> features;
5653 };
5754
5855 Json::Value serialize_ipv (const InstalledPackageView& ipv,
5956 const InstalledPaths& installed,
6057 const ReadOnlyFilesystem& fs);
6158}
59+
60+ VCPKG_FORMAT_WITH_TO_STRING_LITERAL_NONMEMBER (vcpkg::InstallState);
61+ VCPKG_FORMAT_WITH_TO_STRING_LITERAL_NONMEMBER (vcpkg::Want);
0 commit comments