stdlib: replace _CocoaArrayType with _SwiftNSArrayRequiredOverridesType

Swift SVN r21972
This commit is contained in:
Dmitri Hrybenko
2014-09-16 12:53:00 +00:00
parent 9b62c620a7
commit e6e17ac7d4
9 changed files with 44 additions and 56 deletions

View File

@@ -11,7 +11,7 @@
//===----------------------------------------------------------------------===//
//
// _ContiguousArrayStorageBase supplies the implementation of the
// _CocoaArrayType API (and thus, NSArray the API) for our
// _SwiftNSArrayRequiredOverridesType API (and thus, NSArray the API) for our
// _ContiguousArrayStorage<T>. We can't put this implementation
// directly on _ContiguousArrayStorage because generic classes can't
// override Objective-C selectors.
@@ -33,9 +33,9 @@ func _isValidArraySubscript(index: Int, count: Int) -> Bool {
return (index >= 0) & (index < count)
}
/// Base class of the heap buffer backing arrays.
@objc class _ContiguousArrayStorageBase : _NSSwiftArray, _CocoaArrayType {
@objc class _ContiguousArrayStorageBase :
_NSSwiftArray, _SwiftNSArrayRequiredOverridesType {
typealias Buffer = HeapBuffer<_ArrayBody, AnyObject>
// The optional Void arguments prevent these methods from being
@@ -138,7 +138,7 @@ func _isValidArraySubscript(index: Int, count: Int) -> Bool {
}
}
func copyWithZone(_: COpaquePointer) -> _CocoaArrayType {
func copyWithZone(_: _SwiftNSZone) -> AnyObject {
return self
}