From 4d99d22e10a3cb2a421da1618c127128816613c9 Mon Sep 17 00:00:00 2001 From: jacqueline Date: Tue, 26 Sep 2023 13:36:07 +1000 Subject: std::string -> std::pmr::string in psram --- src/database/include/index.hpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/database/include/index.hpp') diff --git a/src/database/include/index.hpp b/src/database/include/index.hpp index 17b40f5b..838eff31 100644 --- a/src/database/include/index.hpp +++ b/src/database/include/index.hpp @@ -17,7 +17,7 @@ #include "leveldb/slice.h" #include "leveldb/write_batch.h" -#include "shared_string.h" +#include "memory_resource.hpp" #include "track.hpp" namespace database { @@ -29,7 +29,7 @@ struct IndexInfo { IndexId id; // Localised, user-friendly description of this index. e.g. "Albums by Artist" // or "All Tracks". - std::string name; + std::pmr::string name; // Specifier for how this index breaks down the database. std::vector components; }; @@ -51,7 +51,7 @@ struct IndexKey { // The filterable / selectable item that this key represents. "Jacqueline" for // kArtist, "My Cool Album" for kAlbum, etc. - std::optional item; + std::optional item; // If this is a leaf component, the track id for this record. // This could reasonably be the value for a record, but we keep it as a part // of the key to help with disambiguation. @@ -59,8 +59,8 @@ struct IndexKey { }; auto Index(const IndexInfo&, const Track&, leveldb::WriteBatch*) -> bool; -auto ExpandHeader(const IndexKey::Header&, const std::optional&) - -> IndexKey::Header; +auto ExpandHeader(const IndexKey::Header&, + const std::optional&) -> IndexKey::Header; // Predefined indexes // TODO(jacqueline): Make these defined at runtime! :) -- cgit v1.2.3