Skip to content

Commit 70b6cc6

Browse files
committed
refactor serializer
1 parent c6d7e27 commit 70b6cc6

File tree

5 files changed

+101
-230
lines changed

5 files changed

+101
-230
lines changed

Diff for: include/mrdox/Debug.hpp

+3
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,9 @@ debugEnableHeapChecking();
4040
#define Assert(expr) ((!!(expr))? ((void)0): llvm_unreachable(#expr))
4141
#endif
4242

43+
#define static_error(msg, value) \
44+
static_assert(!std::is_same_v<decltype(value),decltype(value)>,msg)
45+
4346
} // mrdox
4447
} // clang
4548

Diff for: include/mrdox/meta/Enum.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,6 @@ namespace mrdox {
3131
// Information for a single possible value of an enumeration.
3232
struct EnumValueInfo
3333
{
34-
static constexpr InfoType type_id = InfoType::IT_enum;
35-
3634
explicit
3735
EnumValueInfo(
3836
llvm::StringRef Name = llvm::StringRef(),
@@ -67,6 +65,8 @@ struct EnumValueInfo
6765
// Info for types.
6866
struct EnumInfo : SymbolInfo
6967
{
68+
static constexpr InfoType type_id = InfoType::IT_enum;
69+
7070
EnumInfo()
7171
: SymbolInfo(InfoType::IT_enum)
7272
{

0 commit comments

Comments
 (0)