Closed ttilley closed 9 years ago
successful swift 2.0 update here: https://github.com/ttilley/docopt.swift/commit/aef1910ca095000bf396dda87fb23c0ebfcec8fc
removing use of Foundation will be a lot more complicated than I initially thought. considering there is no native regex functionality without importing from Foundation.
well, here's hoping the linux port includes a decent objc runtime and at least some of Foundation...
This looks really cool! :+1: How about a pull request? :)
I'd like to leave this is as a feature suggestion. Without knowing the details of the open source swift 2.0 release, it might be helpful to attempt a swift 2.0 port that doesn't make use of features outside the swift language itself. I suspect that any objc features in linux swift will depend on GNUStep, which might be an unnecessary dependency.
I've been meaning to learn swift, and swift 2.0 is the perfect catalyst to do so. Given enough time I'd like to take a look at this myself, but I would be learning the language features from scratch. Might be fun. :smile:
Note: the "upgrade project to swift 2.0" feature in xcode 7 doesn't end up producing a working library. Some of the issues make some sense (though i don't know why it wanted to rename x.left to x.count in one place), while others make none at all (simply failing to link with no useful error message). I'm guessing the failure to link is due to only some things working in swift 2.0 when running on 10.10. After a full backup, i'll try again on 10.11 DP3. ;)