[stdlib] added fast getObjects:andKeys:

Improved performance of some bridged dictionary operations
Fixes rdar://problem/18873563

Swift SVN r24293
This commit is contained in:
Maxwell Swadling
2015-01-09 02:09:53 +00:00
parent efddf5f7de
commit 21fd60fd92
3 changed files with 87 additions and 0 deletions

View File

@@ -95,6 +95,9 @@ public protocol _NSDictionaryCoreType :
func copyWithZone(zone: _SwiftNSZone) -> AnyObject
func getObjects(objects: UnsafeMutablePointer<AnyObject>,
andKeys keys: UnsafeMutablePointer<AnyObject>)
func countByEnumeratingWithState(
state: UnsafeMutablePointer<_SwiftNSFastEnumerationState>,
objects: UnsafeMutablePointer<AnyObject>, count: Int
@@ -111,6 +114,8 @@ public protocol _NSDictionaryCoreType :
/// supplies.
@unsafe_no_objc_tagged_pointer @objc
public protocol _NSDictionaryType : _NSDictionaryCoreType {
// Note! This API's type is different from what is imported by the clang
// importer.
func getObjects(objects: UnsafeMutablePointer<AnyObject>,
andKeys keys: UnsafeMutablePointer<AnyObject>)
}