From baf0e3ea70c8a40244d1f5aec65298dff8d2147c Mon Sep 17 00:00:00 2001 From: Jake Turner Date: Sat, 20 Feb 2021 05:26:37 +0000 Subject: [PATCH] #error for unknown platform in demos project --- util/test/demos/main.cpp | 6 +++++- util/test/demos/test_common.h | 4 +++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/util/test/demos/main.cpp b/util/test/demos/main.cpp index ca24d7735..f1a134961 100644 --- a/util/test/demos/main.cpp +++ b/util/test/demos/main.cpp @@ -139,7 +139,7 @@ void NuklearShutdown() UnregisterClassW(wc.lpszClassName, wc.hInstance); } -#else +#elif defined(__linux__) #define NK_XLIB_IMPLEMENTATION #include "3rdparty/nuklear/nuklear_xlib.h" @@ -214,6 +214,10 @@ void NuklearShutdown() XCloseDisplay(dpy); } +#else + +#error UNKNOWN PLATFORM + #endif // nuklear diff --git a/util/test/demos/test_common.h b/util/test/demos/test_common.h index 691472d91..e25eb360f 100644 --- a/util/test/demos/test_common.h +++ b/util/test/demos/test_common.h @@ -26,8 +26,10 @@ #if defined(WIN32) #include "win32/win32_platform.h" -#else +#elif defined(__linux__) #include "linux/linux_platform.h" +#else +#error UNKNOWN PLATFORM #endif #include