Swift 2 Global Functions

In Swift 2.0, thanks to the power of protocol extension, some of the global functions have been converted into methods, particularly global functions that act on parameters of type Sequence or Collection. However, I do have some questions while going through my list of global functions:


- Why is that global funtions like dropFirst, dropLast, prefix, suffix and zip not converted into methods?

- Some global functions are also methods of Collection type, but not removed as global functions, for example: insert, join, removeAll, removeLast, removeRange, sort. Why?


Thanks!

As mentioned in the release notes, we're not done with this work:

"Several global generic functions in the standard library have not yet been moved to be methods."


Expect more changes in this area in future betas.


-Chris

Swift 2 Global Functions
 
 
Q