Skip to content

Commit 9b6bdf4

Browse files
Change SignerTypeDefs to a local array (dashpay#29)
1 parent b7ce3b8 commit 9b6bdf4

File tree

1 file changed

+11
-6
lines changed

1 file changed

+11
-6
lines changed

src/evo/verifiable.h

+11-6
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,17 @@ enum SignerType : uint8_t {
2222
};
2323
template<> struct is_serializable_enum<SignerType> : std::true_type {};
2424

25-
[[maybe_unused]] static constexpr std::array<std::string_view, SignerType::LAST+1> signerTypeDefs = {
26-
"UNKNOWN",
27-
"MGT",
28-
"ORAT",
29-
"LLMQ"
30-
};
25+
constexpr std::array<std::string_view, SignerType::LAST+1> makeSignerTypeDefs() {
26+
std::array<std::string_view, SignerType::LAST+1> arr = {
27+
"UNKNOWN",
28+
"MGT",
29+
"ORAT",
30+
"LLMQ"
31+
};
32+
return arr;
33+
}
34+
35+
[[maybe_unused]] static constexpr auto signerTypeDefs = makeSignerTypeDefs();
3136

3237
class Verifiable {
3338
public:

0 commit comments

Comments
 (0)