Add support for enum type in RTCompileOptionsT

Add support for enum type in RTCompileOptionsT
This commit is contained in:
Jarosz, Piotr
2025-10-15 12:18:44 +00:00
committed by igcbot
parent 6057876654
commit 695fc442a8

View File

@ -18,11 +18,12 @@ SPDX-License-Identifier: MIT
#include <type_traits>
#include <assert.h>
#include "AdaptorCommon/API/igc.h"
namespace Interface {
template <typename T> class Optional {
static_assert(std::is_arithmetic_v<T>, "simple types for now!");
static_assert(std::is_arithmetic_v<T> || std::is_enum_v<T>, "simple types for now!");
T Val;
bool Valid = false;
@ -59,4 +60,8 @@ public:
void reset() { Valid = false; }
};
template <typename T> inline bool operator==(const Optional<T> &, const Optional<T> &) {
return true;
}
} // namespace Interface