In particular, get rid of the enum magic; we can use map<string,int> if we really need some named enums. Which we usually don’t.