Swift 2.2 changelog

  • ++ and – are deprecated
  • Traditional C-style for loops are deprecated
  • Arrays and other slice types now have removeFirst()
  • You can now compare tuples
  • Tuple splat syntax is deprecated
  • More keywords can be used as argument labels
  • var parameters have been deprecated
  • Renamed debug identifiers: #line, #function, #file
  • Stringified selectors are deprecated
  • Compile-time Swift version checking
1
2
3
4
5
#if swift(>=2.2)
print("Running Swift 2.2 or later")
#else
print("Running Swift 2.1 or earlier")
#endif