Added foldLeft and more switch annotations