[wpiutil] DynamicStruct: Store StructDescriptor by value

This commit is contained in:
Peter Johnson
2024-10-25 14:21:27 -07:00
parent caae5357b7
commit 2cfe114c78
3 changed files with 26 additions and 32 deletions

View File

@@ -7,14 +7,12 @@
#include <stdint.h>
#include <cassert>
#include <memory>
#include <span>
#include <string>
#include <string_view>
#include <utility>
#include <vector>
#include "wpi/MathExtras.h"
#include "wpi/StringMap.h"
#include "wpi/bit.h"
@@ -357,7 +355,7 @@ class StructDescriptorDatabase {
const StructDescriptor* Find(std::string_view name) const;
private:
StringMap<std::unique_ptr<StructDescriptor>> m_structs;
StringMap<StructDescriptor> m_structs;
};
/**