Ver código fonte

Added no return to debugBreak to hint code analysis.

Branimir Karadzic 11 anos atrás
pai
commit
cbec117a46
1 arquivos alterados com 7 adições e 0 exclusões
  1. 7 0
      include/bx/debug.h

+ 7 - 0
include/bx/debug.h

@@ -27,6 +27,11 @@ extern "C" void NSLog(CFStringRef _format, ...);
 
 namespace bx
 {
+	BX_PRAGMA_DIAGNOSTIC_PUSH();
+	BX_PRAGMA_DIAGNOSTIC_IGNORED_CLANG("-Winvalid-noreturn");
+
+	inline void debugBreak() BX_NO_RETURN;
+
 	inline void debugBreak()
 	{
 #if BX_COMPILER_MSVC
@@ -43,6 +48,8 @@ namespace bx
 #endif // BX
 	}
 
+	BX_PRAGMA_DIAGNOSTIC_POP();
+
 	inline void debugOutput(const char* _out)
 	{
 #if BX_PLATFORM_ANDROID