https://gitlab.tiker.net/inducer/pytential/blob/ce019ad2e707933b2457f05dc502cbbd9a0eb051/pytential/qbx/target_assoc.py#L88-120
cgen.Enum could help with that.
cgen.Enum
cc @mattwala