File tree Expand file tree Collapse file tree 1 file changed +5
-10
lines changed Expand file tree Collapse file tree 1 file changed +5
-10
lines changed Original file line number Diff line number Diff line change 34
34
* @code
35
35
* #include "toolchain.h"
36
36
*
37
- * typedef struct {
37
+ * MBED_PACKED( struct) foo {
38
38
* char x;
39
39
* int y;
40
- * } MBED_PACKED foo ;
40
+ * };
41
41
* @endcode
42
42
*/
43
43
#ifndef MBED_PACKED
44
44
#if defined(__ICCARM__ )
45
- #define MBED_PACKED __packed
45
+ #define MBED_PACKED ( struct ) __packed struct
46
46
#else
47
- #define MBED_PACKED __attribute__((packed))
47
+ #define MBED_PACKED ( struct ) struct __attribute__((packed))
48
48
#endif
49
49
#endif
50
50
@@ -238,16 +238,11 @@ typedef int FILEHANDLE;
238
238
#endif
239
239
240
240
#ifndef PACKED
241
- #define PACKED MBED_PACKED
241
+ #define PACKED MBED_PACKED()
242
242
#endif
243
243
244
244
#ifndef EXTERN
245
245
#define EXTERN extern
246
246
#endif
247
247
248
- // Backwards compatibility
249
- #ifndef EXTERN
250
- #define EXTERN extern
251
- #endif
252
-
253
248
#endif
You can’t perform that action at this time.
0 commit comments