diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2012-11-07 10:54:49 +0100 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2012-11-13 09:20:57 +0100 |
commit | 9ed2befb6bfefe760272aa33d00af45a92240333 (patch) | |
tree | 6babd1b1fe05c1f80c4bff8f121f3cdb215da89f /cpukit/score | |
parent | rtems-message_queue.adb: Formatting (diff) | |
download | rtems-9ed2befb6bfefe760272aa33d00af45a92240333.tar.bz2 |
score: Add and use RTEMS_ARRAY_SIZE()
Diffstat (limited to 'cpukit/score')
-rw-r--r-- | cpukit/score/include/rtems/score/basedefs.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/cpukit/score/include/rtems/score/basedefs.h b/cpukit/score/include/rtems/score/basedefs.h index 8239994c03..e91467d84d 100644 --- a/cpukit/score/include/rtems/score/basedefs.h +++ b/cpukit/score/include/rtems/score/basedefs.h @@ -174,6 +174,8 @@ typedef int rtems_static_assert_ ## msg [(cond) ? 1 : -1] #endif +#define RTEMS_ARRAY_SIZE(array) (sizeof(array) / sizeof((array)[0])) + #ifndef ASM #ifdef RTEMS_DEPRECATED_TYPES typedef bool boolean; |