We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 011054e commit 34d2994Copy full SHA for 34d2994
test/common/non_trivially_destructible.h
@@ -0,0 +1,21 @@
1
+#ifndef ENTT_COMMON_NON_TRIVIALLY_DESTRUCTIBLE_H
2
+#define ENTT_COMMON_NON_TRIVIALLY_DESTRUCTIBLE_H
3
+
4
+#include <compare>
5
+#include <type_traits>
6
7
+namespace test {
8
9
+struct non_trivially_destructible final {
10
+ ~non_trivially_destructible() {}
11
+ [[nodiscard]] constexpr bool operator==(const non_trivially_destructible &) const noexcept = default;
12
+ [[nodiscard]] constexpr auto operator<=>(const non_trivially_destructible &) const noexcept = default;
13
+ int value{};
14
+};
15
16
+// ensure non trivially destructible-ness :)
17
+static_assert(!std::is_trivially_destructible_v<test::non_trivially_destructible>, "Not a trivially destructible type");
18
19
+} // namespace test
20
21
+#endif
0 commit comments