octascript: fix potential constant key bug in enums