ST / ST_Events-old

Dependents:   HelloWorld_CCA01M1 HelloWorld_CCA02M1 CI-data-logger-server HelloWorld_CCA02M1 ... more

This is a fork of the events subdirectory of https://github.com/ARMmbed/mbed-os.

Note, you must import this library with import name: events!!!

Revision:
6231:a9915ab0d683
Parent:
6230:ff703c65fe9c
Child:
6375:81a9af277ac6
--- a/hal/api/toolchain.h	Thu May 26 18:43:02 2016 -0500
+++ b/hal/api/toolchain.h	Wed Jun 01 16:10:19 2016 -0500
@@ -34,17 +34,17 @@
  *  @code
  *  #include "toolchain.h"
  *
- *  typedef struct {
+ *  MBED_PACKED(struct) foo {
  *      char x;
  *      int y;
- *  } MBED_PACKED foo;
+ *  };
  *  @endcode
  */
 #ifndef MBED_PACKED
 #if defined(__ICCARM__)
-#define MBED_PACKED __packed
+#define MBED_PACKED(struct) __packed struct
 #else
-#define MBED_PACKED __attribute__((packed))
+#define MBED_PACKED(struct) struct __attribute__((packed))
 #endif
 #endif
 
@@ -238,16 +238,11 @@
 #endif
 
 #ifndef PACKED
-#define PACKED MBED_PACKED
+#define PACKED MBED_PACKED()
 #endif
 
 #ifndef EXTERN
 #define EXTERN extern
 #endif
 
-// Backwards compatibility
-#ifndef EXTERN
-#define EXTERN extern
 #endif
-
-#endif