<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">It does, but on Darwin, importing Foundation alone is sufficient.<div class=""><br class=""></div><div class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Jan 14, 2016, at 11:03 AM, Tony Parker &lt;<a href="mailto:anthony.parker@apple.com" class="">anthony.parker@apple.com</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Hi Drew,<div class=""><br class=""></div><div class="">I assume this works on Linux if you import Glibc as well?</div><div class=""><br class=""></div><div class="">- Tony</div><div class=""><br class=""><div class=""><blockquote type="cite" class=""><div class="">On Jan 14, 2016, at 8:44 AM, Drew Crawford via swift-corelibs-dev &lt;<a href="mailto:swift-corelibs-dev@swift.org" class="">swift-corelibs-dev@swift.org</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">on Darwin, we can say:<div class=""><br class=""></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><div class="">import Foundation</div><div class="">exit(2)</div></blockquote><br class=""><div class="">I'm not totally sure how this works, since exit is provided by Darwin, not by Foundation. &nbsp;But somehow importing Foundation imports Darwin as well.</div><div class=""><br class=""></div><div class="">I think for source compatibility, we should support this, because&nbsp;<a href="http://stackoverflow.com/questions/34186994/swift-2-2-on-linux-use-of-unresolved-identifier-exit" class="">people</a>&nbsp;are&nbsp;<a href="http://stackoverflow.com/questions/24102157/seeking-an-exit-equivalent-in-swift" class="">asking</a>&nbsp;why it doesn't work out of the box.</div><div class=""><br class=""></div><div class="">I considered PRing an exit implementation in corelibs-foundation, but I think that might cause the opposite problem–introduce a conflict between Darwin/Glibc exit and Foundation "exit".</div><div class=""><br class=""></div><div class="">Can someone speak to how this is solved in Darwin Foundation and what we should do about it?</div>
<img src="https://u2002410.ct.sendgrid.net/wf/open?upn=U7z7oSqRMSwdl2rYt9JJ4zIFaeg4R-2FxExg9xndDuCbxNUF-2BwXxb5-2BRNWWm30sEtRoA4DRpftIuazjE-2BfY5-2B-2Buy4Fv49czER3SqmgN2rzgGYKQ1oXFSigwsv3LbT6Wyo8BvFnreax7smj4fts5uulhx628BkRSZO0gZHBxXR-2BJmIlg-2BOy0kc3z7gM6MrZozsWhiN-2B48iTAeGwmnxFmsL-2BZGao6SESo8vdc20aJbVB8Ig-3D" alt="" width="1" height="1" border="0" style="height:1px !important;width:1px !important;border-width:0 !important;margin-top:0 !important;margin-bottom:0 !important;margin-right:0 !important;margin-left:0 !important;padding-top:0 !important;padding-bottom:0 !important;padding-right:0 !important;padding-left:0 !important;" class="">
</div>
_______________________________________________<br class="">swift-corelibs-dev mailing list<br class=""><a href="mailto:swift-corelibs-dev@swift.org" class="">swift-corelibs-dev@swift.org</a><br class=""><a href="https://lists.swift.org/mailman/listinfo/swift-corelibs-dev" class="">https://lists.swift.org/mailman/listinfo/swift-corelibs-dev</a><br class=""></div></blockquote></div><br class=""></div></div></div></blockquote></div><br class=""></div></body></html>