summaryrefslogtreecommitdiffstats
path: root/src/sord_internal.h
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2022-07-07 10:34:52 -0400
committerDavid Robillard <d@drobilla.net>2022-07-17 17:32:02 -0400
commitd06e4107e82fd7e1337068b94c451e2f29f4e76c (patch)
treea7c8881b9d6986f4c05eb2679a8d91be49a60df5 /src/sord_internal.h
parentc6f05ca4a012642012235e67da166f9833f6c56b (diff)
downloadsord-d06e4107e82fd7e1337068b94c451e2f29f4e76c.tar.gz
sord-d06e4107e82fd7e1337068b94c451e2f29f4e76c.tar.bz2
sord-d06e4107e82fd7e1337068b94c451e2f29f4e76c.zip
Implement SORD_UNREACHABLE() for MSVC
Diffstat (limited to 'src/sord_internal.h')
-rw-r--r--src/sord_internal.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/sord_internal.h b/src/sord_internal.h
index 4aef846..ef22467 100644
--- a/src/sord_internal.h
+++ b/src/sord_internal.h
@@ -24,9 +24,10 @@
#if defined(__clang__) || (defined(__GNUC__) && __GNUC__ > 4)
# define SORD_UNREACHABLE() __builtin_unreachable()
+#elif defined(_MSC_VER)
+# define SORD_UNREACHABLE() __assume(0)
#else
-# include <assert.h>
-# define SORD_UNREACHABLE() assert(0)
+# define SORD_UNREACHABLE()
#endif
/** Resource node metadata */