Migrate corelibs-foundation to the newest APIs

As you know, currently, as of the 03-24 DEVELOPMENT snapshot, the function
signatures for Foundation has diverged. This has caused us to create
platform specific calls to the NSString, NSDate, NSCache, etc. classes. For
instance,

#if os
(Linux)
                                                                                    
            >let lastSlash = fileName.rangeOfString("/", options:
            >NSStringCompareOptions.BackwardsSearch)
                                                                                    
            >#else
                                                                                    
            >let lastSlash = fileName.range(of: "/", options:
            >NSStringCompareOptions.backwardsSearch)
                                                                                    
            >#endif
                                                                                    
  I was curious about the timeline for the migration to the newer APIs and
whether someone in particular was working on it. We have some developers
here at IBM@Swift that could do some of this work, but want to make sure we
aren't duplicating work and are coordinated.

Hi Robert,

This is something we really do need some help with. Our goal is to have the Linux version match the Darwin version exactly.

There is also a PR up to change some of the results of the automatic renaming by the importer, here:

So we should take those into account as well.

- Tony

···

On Apr 12, 2016, at 9:45 AM, Robert F Dickerson via swift-corelibs-dev <swift-corelibs-dev@swift.org> wrote:

As you know, currently, as of the 03-24 DEVELOPMENT snapshot, the function signatures for Foundation has diverged. This has caused us to create platform specific calls to the NSString, NSDate, NSCache, etc. classes. For instance,

if os(Linux) <ecblank.gif>
<ecblank.gif> let lastSlash = fileName.rangeOfString("/", options: NSStringCompareOptions.BackwardsSearch)
<ecblank.gif> #else
<ecblank.gif> let lastSlash = fileName.range(of: "/", options: NSStringCompareOptions.backwardsSearch)
<ecblank.gif> #endif

I was curious about the timeline for the migration to the newer APIs and whether someone in particular was working on it. We have some developers here at IBM@Swift that could do some of this work, but want to make sure we aren't duplicating work and are coordinated.
_______________________________________________
swift-corelibs-dev mailing list
swift-corelibs-dev@swift.org
https://lists.swift.org/mailman/listinfo/swift-corelibs-dev

I noticed the folks at IBM were also doing platform checks when using the
corelibs-xctest APIs. I created [SR-1215] Provide both Swift 2.2 and Swift 3 APIs for corelibs-xctest? · Issue #390 · apple/swift-corelibs-xctest · GitHub to
track the issue.

corelibs-xctest is small enough that we may want to consider providing
*both* Swift 2.2 and Swift 3 APIs, perhaps behind a `#if swift(<3.0)` check.

corelibs-foundation provides a much greater API surface, so it may not be
feasible. But what does everyone think about this approach for
corelibs-xctest?

- Brian Gesiak

···

On Tue, Apr 12, 2016 at 12:57 PM, Tony Parker via swift-corelibs-dev < swift-corelibs-dev@swift.org> wrote:

Hi Robert,

This is something we really do need some help with. Our goal is to have
the Linux version match the Darwin version exactly.

There is also a PR up to change some of the results of the automatic
renaming by the importer, here:

Add Foundation API Notes for Swift 3 naming by cwillmor · Pull Request #2093 · apple/swift · GitHub

So we should take those into account as well.

- Tony

On Apr 12, 2016, at 9:45 AM, Robert F Dickerson via swift-corelibs-dev < > swift-corelibs-dev@swift.org> wrote:

As you know, currently, as of the 03-24 DEVELOPMENT snapshot, the function
signatures for Foundation has diverged. This has caused us to create
platform specific calls to the NSString, NSDate, NSCache, etc. classes. For
instance,

if os(Linux) <ecblank.gif>
<ecblank.gif> let lastSlash = fileName.rangeOfString("/", options:
NSStringCompareOptions.BackwardsSearch)
<ecblank.gif> #else
<ecblank.gif> let lastSlash = fileName.range(of: "/", options:
NSStringCompareOptions.backwardsSearch)
<ecblank.gif> #endif

I was curious about the timeline for the migration to the newer APIs and
whether someone in particular was working on it. We have some developers
here at IBM@Swift that could do some of this work, but want to make sure
we aren't duplicating work and are coordinated.

_______________________________________________
swift-corelibs-dev mailing list
swift-corelibs-dev@swift.org
https://lists.swift.org/mailman/listinfo/swift-corelibs-dev

_______________________________________________
swift-corelibs-dev mailing list
swift-corelibs-dev@swift.org
https://lists.swift.org/mailman/listinfo/swift-corelibs-dev