Re: [swift-corelibs-dev] Mark NSUnimplemented functions as unavailable.

2017-05-10 Thread Philippe Hausler via swift-corelibs-dev
It might be also useful to keep track of each one of these so we can make sure there are bugs for each one. (Even if it is a list that a script could create tickets). Many of the NSUnimplemented methods are good points to start contributing. > On May 10, 2017, at 16:59, Sergej Jaskiewicz via sw

Re: [swift-corelibs-dev] Mark NSUnimplemented functions as unavailable.

2017-05-10 Thread Sergej Jaskiewicz via swift-corelibs-dev
Well, here is what I got in IBM Swift Sandbox. http://swift.sandbox.bluemix.net/#/repl/5913a8594ee0cd258050b2fd If I got you right, it works. Yes, partially implemented functions is a problem. But we definitely could mark the on

Re: [swift-corelibs-dev] Mark NSUnimplemented functions as unavailable.

2017-05-10 Thread Philippe Hausler via swift-corelibs-dev
This of course is predicated upon availability macros working appropriately on linux (which last time I checked we don’t have a version variant). It is definitely worth investigation. > On May 10, 2017, at 16:41, Tony Parker via swift-corelibs-dev > wrote: > > Hi Sergej, > > This is a good i

Re: [swift-corelibs-dev] Mark NSUnimplemented functions as unavailable.

2017-05-10 Thread Tony Parker via swift-corelibs-dev
Hi Sergej, This is a good idea, but there are some additional things to consider. In some cases, methods are partially unimplemented (with edge cases, or at least less common cases remaining unfinished). The availability macro can’t reflect that status. In other cases, we want to partially imp

[swift-corelibs-dev] Mark NSUnimplemented functions as unavailable.

2017-05-10 Thread Sergej Jaskiewicz via swift-corelibs-dev
I was wondering why cannot we just mark all the methods/properties/functions in Swift Foundation that are NSUnimplemented or call a subroutine that is NSUnimplemented like this: @available(*, unavailable, message: “foo is not implemented yet”) func foo() { NSUnimplemented() } In this case we c

Re: [swift-corelibs-dev] Bring NSString functions to String

2017-05-10 Thread Andrey Fidrya via swift-corelibs-dev
Hi All, Btw, when migrating from NSString's methods to URL I've noticed that they work a bit differently: URL's methods convert strings from NFC to NFD (decomposed) unicode form which is demonstrated by the example below. I had to additionally call .precomposedStringWithCanonicalMapping on result

Re: [swift-corelibs-dev] Bring NSString functions to String

2017-05-10 Thread Eric Blachère via swift-corelibs-dev
Thanks for the answer ! It seems a bit weird from them to advocate using NSString methods in the unavailability comment. I would rather use URL when I can even if the conversions are a bit tedious ^^ Thanks a lot, Eric 2017-05-10 10:52 GMT+02:00 Brent Royal-Gordon : > > On May 8, 2017, at 9:39 A

Re: [swift-corelibs-dev] Bring NSString functions to String

2017-05-10 Thread Brent Royal-Gordon via swift-corelibs-dev
> On May 8, 2017, at 9:39 AM, Eric Blachère via swift-corelibs-dev > wrote: > > I was just wondering if there are plans to bring NSString functions > manipulating paths into the native String class. (such as lastPathComponent, > pathComponents etc...) > Because even if we can always make an ex