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

Joe Groff jgroff at apple.com
Tue Mar 8 13:35:11 CST 2016


> On Mar 8, 2016, at 11:33 AM, Brian Pratt via swift-evolution <swift-evolution at swift.org> wrote:
> 
> I'm definitely a big +1 on this -- and pretty much any other suggestion that makes Swift code more portable and sets up a simple interface so that other platforms can be supported without the addition of more code.
> 
> A few thoughts to add:
>  - there are differences (minor, but still) between Glibc and Darwin. Those should be either unified (if possible) or re-arranged so that the unified library shares unified functionality and then each separate one can have its own set of caveats.
> 
>  - I like `import System` myself, for the reasons you mentioned (conveys LibC+POSIX combo)

This would be problematic for non-POSIX platforms, like Windows. (iOS and Android are also limited in POSIX-ness in various ways.)

-Joe



More information about the swift-evolution mailing list