ads1115 only

Fork of mbed by mbed official

Revision:
130:d75b3fe1f5cb
Parent:
128:9bcdf88f62b0
diff -r 0ab6a29f35bf -r d75b3fe1f5cb platform/toolchain.h
--- a/platform/toolchain.h	Tue Nov 08 17:28:34 2016 +0000
+++ b/platform/toolchain.h	Thu Nov 24 11:01:25 2016 +0000
@@ -19,6 +19,8 @@
 #ifndef MBED_TOOLCHAIN_H
 #define MBED_TOOLCHAIN_H
 
+#include "mbed_preprocessor.h"
+
 
 // Warning for unsupported compilers
 #if !defined(__GNUC__)   /* GCC        */ \
@@ -65,8 +67,7 @@
  */
 #ifndef MBED_ALIGN
 #if defined(__ICCARM__)
-#define _MBED_ALIGN(N) _Pragma(#N)
-#define MBED_ALIGN(N) _MBED_ALIGN(data_alignment=N)
+#define MBED_ALIGN(N) _Pragma(MBED_STRINGIFY(data_alignment=N))
 #else
 #define MBED_ALIGN(N) __attribute__((aligned(N)))
 #endif
@@ -219,10 +220,10 @@
  *  @endcode
  */
 #ifndef MBED_DEPRECATED
-#if defined(__GNUC__) || defined(__clang__)
+#if defined(__CC_ARM)
+#define MBED_DEPRECATED(M) __attribute__((deprecated))
+#elif defined(__GNUC__) || defined(__clang__)
 #define MBED_DEPRECATED(M) __attribute__((deprecated(M)))
-#elif defined(__CC_ARM)
-#define MBED_DEPRECATED(M) __attribute__((deprecated))
 #else
 #define MBED_DEPRECATED(M)
 #endif