Commits

Doug Gregor committed 5b0423c9f2b
Omit needless words: prefer removing leading redundant type information first. We intentionally avoid collapsing a method name down to just a preposition. When we end up in such cases, prefer to strip leading redundant type information (which corresponds to both context and return types) rather than trailing type information. This can help keep close method families together, e.g., in NSFontDescriptor: - func fontDescriptorWith(_: UIFontDescriptorSymbolicTraits) -> UIFontDescriptor - func fontDescriptorWithSize(_: CGFloat) -> UIFontDescriptor - func fontDescriptorWithMatrix(_: CGAffineTransform) -> UIFontDescriptor - func fontDescriptorWithFace(_: String) -> UIFontDescriptor - func fontDescriptorWithFamily(_: String) -> UIFontDescriptor + func withSymbolicTraits(_: UIFontDescriptorSymbolicTraits) -> UIFontDescriptor + func withSize(_: CGFloat) -> UIFontDescriptor + func withMatrix(_: CGAffineTransform) -> UIFontDescriptor + func withFace(_: String) -> UIFontDescriptor + func withFamily(_: String) -> UIFontDescriptor Note especially the first case, where we don't want to just go down to "with" for the name, even though "SymbolicTraits" is redundant with the parameter type. Swift SVN r31702