The Swift Programming Language
251–260 of 970 posts
Re: The Swift Programming Language
#252Feels like they looked at a bunch of programming languages, took all their favorite features, and then put them into one which still sits on top of the ObjC runtime. And then added some Apple syntactic craziness. For example: var apples = 3; // mutable let oranges = 5; // immutable let summary = "I have \(apples) apples and \(oranges) oranges";
a. No fall through. This is a plus in avoiding bugs. This is minus if you really know what you are doing and want fall throughs b. Pattern Matching in case statements. This is bit interesting and should take care of the previous case.
Other than that my first impression is it's a mishmash of various programming languages. Everything else that they demo'ed seem to be features of XCode (rewinds, variable lifetype analysis etc..) rather than the language itself.
Re: The Swift Programming Language
#253“You also don’t need to write semicolons at the end of every statement.” Please. Please. PLEASE don't be whitespace delimited!
Oh. I was rather hoping it would be! But still, there's not a lot to hate. It looks like a cleaner javascript at first glance. Not quite as pretty as Python but then, what is. :)
Re: The Swift Programming Language
#254Re: The Swift Programming Language
#255I did it because the book was free.
Re: The Swift Programming Language
#256Unicode variables, I love it: let 🐶🐮 = "dogcow" Moof!
Re: The Swift Programming Language
#257Re: The Swift Programming Language
#258Earlier quoted context omitted.
Swift doesn't seem to have anything to do with the parallel language at swift-lang.org. Whoops. Should've corrected that when I copied the comment over. In any case, reference counting is disastrous for the parallelism story. GC thread coming along and causing an additional cache miss is way better than having to do atomic operations on reference counts all the time. Why are atomic reference counts necessary? You wou…
I'm not sure you can be Objective-C compatible without a shared heap. If you have a shared heap, you need atomic reference counting.
Re: The Swift Programming Language
#259Link to the EBOOK on iTunes: https://itunes.apple.com/nl/book/swift-programming-language/...
Is there any way to get this without installing iTunes?
Re: The Swift Programming Language
#260So it looks like the language isn't open source and won't target non-Apple runtimes? I'm not trying to troll, I just think that it's a pity that Apple tends to limit the ecosystem and applications of its otherwise-great languages. Building against LLVM ought to make it fairly trivial to make this cross-platform.
Is there anything to stop a independent implementation? Like C#/.Net and Mono?