Change dict to object for slight speedup
inline getChildren since it's a genexpr anyway
Fix bug in switch structuring