[string] Force specialization for small Character

This commit is contained in:
Michael Ilseman
2018-01-22 01:04:54 -08:00
parent c7eefc1ca5
commit d14b8abc8b

View File

@@ -1039,6 +1039,12 @@ extension _StringGuts {
}
}
//
// FIXME (TODO JIRA): Appending a character onto the end of a string should
// really have a less generic implementation, then we can drop @specialize.
//
@_specialize(where C == Character._SmallUTF16)
public // @testable
mutating func append<C : Collection>(contentsOf other: C)
where C.Element == UTF16.CodeUnit {