diff options
| author | hathach <[email protected]> | 2014-04-17 22:57:11 +0700 |
|---|---|---|
| committer | hathach <[email protected]> | 2014-04-17 22:57:11 +0700 |
| commit | 06bb9ad7a797d5da58358a59fb874782e1c67b59 (patch) | |
| tree | 399b4e7108dc4ef2094468450865fcbbc2ae3dfa /tinyusb/common/assertion.h | |
| parent | 69c46b2f9a1b272392fe5fb26d6cbea1da530c13 (diff) | |
move STRING & XSTRING & STATIC_ASSERT to compiler.h
disable test for a class of cdc host
temporarily disable test for test_osal_none.c
change include in some core files
remove osal.h from common.h
Diffstat (limited to 'tinyusb/common/assertion.h')
| -rw-r--r-- | tinyusb/common/assertion.h | 18 |
1 files changed, 3 insertions, 15 deletions
diff --git a/tinyusb/common/assertion.h b/tinyusb/common/assertion.h index 4cbbd8aa8..3832c00c4 100644 --- a/tinyusb/common/assertion.h +++ b/tinyusb/common/assertion.h @@ -50,25 +50,13 @@ extern "C" #endif
#include "tusb_option.h"
+#include "primitive_types.h"
+#include "compiler/compiler.h"
+
#include "hal/hal.h" // TODO find a way to break hal dependency
#define VOID_RETURN
-//--------------------------------------------------------------------+
-// Compile-time Assert
-//--------------------------------------------------------------------+
-#ifdef __ICCARM__
- #define STATIC_ASSERT static_assert
-#else
- #if defined __COUNTER__ && __COUNTER__ != __COUNTER__
- #define _ASSERT_COUNTER __COUNTER__
- #else
- #define _ASSERT_COUNTER __LINE__
- #endif
-
- #define STATIC_ASSERT(const_expr, message) enum { XSTRING_CONCAT_(static_assert_, _ASSERT_COUNTER) = 1/(!!(const_expr)) }
-#endif
-
//#if ( defined CFG_PRINTF_UART || defined CFG_PRINTF_USBCDC || defined CFG_PRINTF_DEBUG )
#if TUSB_CFG_DEBUG
#define _PRINTF(...) printf(__VA_ARGS__)
|
