-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Foundation API Conformance Update: Miscellaneous #567
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
…osed by Darwin Foundation
@swift-ci Please test |
@swift-ci Please test |
@@ -576,7 +576,7 @@ open class FileManager : NSObject { | |||
|
|||
If you wish to only receive the URLs and no other attributes, then pass '0' for 'options' and an empty NSArray ('[NSArray array]') for 'keys'. If you wish to have the property caches of the vended URLs pre-populated with a default set of attributes, then pass '0' for 'options' and 'nil' for 'keys'. | |||
*/ | |||
open func enumerator(at url: URL, includingPropertiesForKeys keys: [URLResourceKey]?, options mask: DirectoryEnumerationOptions = [], errorHandler handler: (@escaping (URL, Error) -> Bool)? = nil) -> DirectoryEnumerator? { | |||
open func enumerator(at url: URL, includingPropertiesForKeys keys: [URLResourceKey]?, options mask: DirectoryEnumerationOptions = [], errorHandler handler: ((URL, Error) -> Bool)? = nil) -> DirectoryEnumerator? { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jrose-apple This is a pretty gnarly error; these should be markable as @escaping
. Do you know who would be the best to look at this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've been talking about it with @milseman and @slavapestov. Right now it is treated as @escaping
, so it's not broken; a function type used as a generic argument is assumed to be used in arbitrary ways inside the body of the type, and that includes Optional. But we probably want to special-case Optional at some point, and then we'll have to be careful to put this back.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the clarification! I'll add a comment in there to explain.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(Good catch, Philippe.)
Third time's the charm? |
Okay, expected failure. Working on integration on rad |
Merging along with swiftlang/swift-corelibs-xctest#158 |
@swift-ci Please test |
(Tested manually as well so this should work) |
Changes
NSBinarySearchOptions
FirstEqual
→firstEqual
LastEqual
→lastEqual
InsertionIndex
→insertionIndex
Cache
Cache
→NSCache
NSCache
generic for type safetyFileHandle
func
→var
public
→open
String
→RunLoopMode
NSExpression
AnyObject
→Any
expressionValueWithObject(_ object: AnyObject?, context: NSMutableDictionary?)
→expressionValue(with object: AnyObject?, context: NSMutableDictionary?)
Predicate
Predicate
→NSPredicate
public init(format predicateFormat: String, arguments argList: CVaListPointer) { NSUnimplemented() }
andpublic convenience init(format predicateFormat: String, _ args: CVarArg...) { NSUnimplemented() }
filter
/filtered
extensions for collection classesComparisonPredicate
ComparisonPredicate
→NSComparisonPredicate
CompoundPredicate
CompoundPredicate
→NSCompoundPredicate
public
→open
UserDefaults
func standardUserDefaults() -> UserDefaults
→var standard: UserDefaults
NumberFormatter
AnyObject
→Any
NSAttributedString
methods[NS]PersonNameComponents
PersonNameComponentsFormatter
phonetic
→isPhonetic
MeasurementFormatter
public func string<UnitType : Unit>(from measurement: Measurement<UnitType>) -> String { NSUnimplemented() }
FileManager
String
→FileAttributeKey
/FileAttributeType
structsNSFileManagerItemReplacementOptions
→NSFileManager.ItemReplacementOptions
AnyObject
→Any