[swift-evolution] [Draft] Unify "import Darwin/Glibc" to simply "Libc"

Saleem Abdulrasool compnerd at compnerd.org
Tue Jul 5 19:41:58 CDT 2016

On Tuesday, July 5, 2016, Chris Lattner <clattner at apple.com> wrote:

> On Jul 5, 2016, at 5:28 PM, Saleem Abdulrasool <compnerd at compnerd.org
> <javascript:_e(%7B%7D,'cvml','compnerd at compnerd.org');>> wrote:
> On Tuesday, July 5, 2016, Chris Lattner <clattner at apple.com
> <javascript:_e(%7B%7D,'cvml','clattner at apple.com');>> wrote:
>> On Jul 5, 2016, at 2:59 PM, Brian Gesiak via swift-evolution <
>> swift-evolution at swift.org> wrote:
>> Sorry to resurrect such an old thread! I understand getting this in Swift
>> 3.0 might not be realistic anymore, but this is still something I’d love to
>> see added to Swift. Could someone advise on whether it still makes sense to
>> spend time on this proposal? Or is this part of Swift too solidified to
>> change at this point?
>> It is definitely beyond Swift 3.0, but I’d love to see this happen at
>> some point, we really need someone to drive the (surely to be contentious)
>> design process.
> I'm probably going to regret this, but given that I had originally
> proposed this to Brian and would really like to see this happen, what does
> this entail?
> 1) get some consensus on list for an overall approach
> 2) formalize a proposal and submit a PR to swift-evolution
> 3) iterate
> #1 is the hardest I think.  I don’t think a truly minimal wrapper of the
> POSIX APIs is interesting, I think we should at least make a Swifty POSIX
> API, which is portable and low-abstraction overhead.  However, it should
> fix the mistakes of errno and “creat” among other things.

That sounds pretty reasonable.  Especially if we do this earlier, breaking
from expectations in terms of mapping for things like "creat" would be less

Not sure what you had in mind for errno.  It seems like if we have an SDK
overlay for posix, we could hide errno, handling it similar to NSError.
However, I think that violates the low overhead.

> -Chris

Saleem Abdulrasool
compnerd (at) compnerd (dot) org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20160705/60b11932/attachment.html>

More information about the swift-evolution mailing list