enum error correction