summaryrefslogtreecommitdiffstatshomepage
path: root/py/compile.c
diff options
context:
space:
mode:
Diffstat (limited to 'py/compile.c')
-rw-r--r--py/compile.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/py/compile.c b/py/compile.c
index ee735a872f..532e29a233 100644
--- a/py/compile.c
+++ b/py/compile.c
@@ -86,8 +86,8 @@ STATIC const mp_map_elem_t mp_constants_table[] = {
STATIC const mp_map_t mp_constants_map = {
.all_keys_are_qstrs = 1,
.table_is_fixed_array = 1,
- .used = sizeof(mp_constants_table) / sizeof(mp_map_elem_t),
- .alloc = sizeof(mp_constants_table) / sizeof(mp_map_elem_t),
+ .used = ARRAY_SIZE(mp_constants_table),
+ .alloc = ARRAY_SIZE(mp_constants_table),
.table = (mp_map_elem_t*)mp_constants_table,
};