Revision 66fe09ee
ID | 66fe09eebb813b79e14279df11d723b433a973fb |
Use ARRAY_SIZE macro
Replace array size calculations with ARRAY_SIZE macro.
Implemented with this Coccinelle semantic patch, adapted from
Linux kernel:@
@
type T;
T[] E;
- (sizeof(E)/sizeof(*E))
+ ARRAY_SIZE(E)
@
@
type T;
T[] E;
- (sizeof(E)/sizeof(E[...]))
+ ARRAY_SIZE(E)
@
@
type T;
T[] E;
- (sizeof(E)/sizeof(T))
+ ARRAY_SIZE(E)
Some files (-dis.c, tests/) had to be filtered out.
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Files
- added
- modified
- copied
- renamed
- deleted