fixed c++ 11 switch (should build on travis now)