[swift-evolution] [Review] SE-0006 Apply API Guidelines to the Standard Library

Brent Royal-Gordon brent at architechies.com
Sat Jan 30 03:53:54 CST 2016


> I still don’t see why we need a suffix at all, what is unclear about the CollectionType protocol simply being called Collection instead?

They're attractive nuisances. Someone wants an integer type, sees Integer, tries to use it, and suddenly they're getting weird errors about Self and associated object requirements. Or they want a boolean variable, see Boolean, and suddenly their one-bit value is wrapped in a 40-byte protocol witness. Nobody is going to mistake Integerlike or Booleanlike for a concrete type and use it accidentally.

-- 
Brent Royal-Gordon
Architechies



More information about the swift-evolution mailing list