@{ mapast(f, seq) { out = {}; for (i in seq) { e = seq[i]; out[length(out)] = e.__proto__ != Token ? f(e) : e ; } out; } idToString(x) { { __proto__: C_string, value: "\"" + string(x.name.identifier) + "\"" } } nil; } enum foo { Closed = 0, ReadOnly = 1, WriteOnly = 2 }; static char *stateNames[] = { @(mapast(idToString, program.last.enumList)) };