From dc1685ca25567fe75c8d50c825fb0303fbb66fac Mon Sep 17 00:00:00 2001 From: Zachary T Welch Date: Mon, 16 Nov 2009 03:29:30 -0800 Subject: move ARRAY_SIZE macro to types.h The ARRAY_SIZE macro was defined in several target files, so move it to types.h. This patch also removes two other identical macros: DIM (from jtag.h) and asizeof (from arm11.h). --- src/jtag/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/jtag/core.c') diff --git a/src/jtag/core.c b/src/jtag/core.c index c8a76e88..ea723ebe 100644 --- a/src/jtag/core.c +++ b/src/jtag/core.c @@ -586,7 +586,7 @@ int jtag_add_statemove(tap_state_t goal_state) unsigned tms_bits = tap_get_tms_path(cur_state, goal_state); unsigned tms_count = tap_get_tms_path_len(cur_state, goal_state); tap_state_t moves[8]; - assert(tms_count < DIM(moves)); + assert(tms_count < ARRAY_SIZE(moves)); for (unsigned i = 0; i < tms_count; i++, tms_bits >>= 1) { -- cgit v1.2.3-18-g5258