Implement scoped enumerations.