refactor: Move to LISTIFY/DT_FOREACH_PROP_ELEM macros.

This commit is contained in:
Peter Johanson
2022-09-20 21:35:40 -04:00
committed by Pete Johanson
parent 69a4c3200d
commit 243a227ff9
10 changed files with 33 additions and 31 deletions

View File

@@ -13,9 +13,9 @@
#define _TRANSFORM_ENTRY(i, _) \
[(KT_ROW(DT_PROP_BY_IDX(ZMK_KEYMAP_TRANSFORM_NODE, map, i)) * ZMK_MATRIX_COLS) + \
KT_COL(DT_PROP_BY_IDX(ZMK_KEYMAP_TRANSFORM_NODE, map, i))] = i,
KT_COL(DT_PROP_BY_IDX(ZMK_KEYMAP_TRANSFORM_NODE, map, i))] = i
static uint32_t transform[] = {UTIL_LISTIFY(ZMK_KEYMAP_LEN, _TRANSFORM_ENTRY, 0)};
static uint32_t transform[] = {LISTIFY(ZMK_KEYMAP_LEN, _TRANSFORM_ENTRY, (,), 0)};
#endif