creating 'translate_enum' helper (fix #74)