4 ms·
I would really hate to be learning Swift now. I started using it around the v2 release and I think it had nice syntax & was relatively small and opinionated. N
by AJRF 6y ago
I would really hate to be learning Swift now. I started using it around the v2 release and I think it had nice syntax & was relatively small and opinionated.
Now there are so many ways to the same thing it must be a nightmare to teach. Each way of doing the same thing is in its own way nice, but they seem to just be accepting every half-way decent proposal for things they've already solved.
I feel like SwiftUI had brought a number of challenges that have massively complicated the language and you can really feel it when you bump up against things that have been tacked on to make SwiftUI work (which it looks like they are getting around to smoothing out now - multiple trailing closures is very a much a problem compounded by SwiftUI).
It's a shame, I loved this language from v2 -> v4, v5 was a good release but started to muddy the waters and now its just getting continually worse.
- skohan 6y ago> feel like SwiftUI had brought a number of challenges that have massively complicated the language and I've been a huge fan of Swift for years, and it's still one of the languages I reach for most for personal projects, but I was really put off by the way the rollout was handled for the features supporting SwiftUI, specifically property wrappers and function builders. Property wrappers in particular feel like a half-baked solution to paper over the lack of real meta-programming facilities. I think it was especially disheartening the way these changes were sprung on the community after being shown at WWDC. It just made the promise of Swift being an open source project built through a community-based process seem like a bit of a farce, and made me a bit more apprehensive about investing in a language which might radically change in direction based on the product needs of Apple.
- tonyedgecombe 6y agoIt's difficult to dip in and out of, you really need to be focussed on it to become productive. It's interesting to compare it to C# which I learnt by opening the IDE and writing code. There was far less to trip you up in C# despite it also being a fairly big language.
- j-pb 6y agoThat description sadly applies to every apple product, software or hardware wise, except for iPhone hardware maybe.
- matt2000 6y agoI agree with you. When Swift was introduced it was billed as a modern replacement for ObjC that was easier to learn, even a good choice as a language for learning to program. I'm not sure it was ever that, but it sure isn't now. I just got back into a project written in Swift 3 and had to change a bunch of stuff to get it to work in Swift 5. Why? I keep hearing the language is going to be stable "soon" but that doesn't appear to be happening. Swift appears to be a language for the captive audience of iOS devs, who are able to keep up if that's all they're doing. I don't really see it being adopted anywhere else.
- wool_gather 6y agoFor what it's worth, source stability is definitely a much firmer constraint now in the minds of the core team: https://forums.swift.org/t/principles-for-trailing-closure-evolution-proposals/37265/18 https://forums.swift.org/t/principles-for-trailing-closure-e... Of course this comes with its own concerns, as you can see from that thread.
- skohan 6y agoTo be fair, the pace of source breaking changes has slowed down considerably. From Swift 1 to Swift 3 there were many breaking changes between versions, and automated migration was very necessary. Between 3 and 4 there were some changes, and between 4 and 5 almost no source breaking changes. I think it's actually fair for a new language to take a somewhat cavalier approach to backward compatibility. I would rather not be stuck with all the naive mistakes made in the first version of a language just to avoid migration.
- JimDabell 6y ago> I just got back into a project written in Swift 3 and had to change a bunch of stuff to get it to work in Swift 5. Why? I keep hearing the language is going to be stable "soon" but that doesn't appear to be happening. Swift 3 was released in 2016. Swift is ABI / source / module stable now, but that doesn't make it retroactively stable with a version released four years ago.
- seandougall 6y ago> I keep hearing the language is going to be stable "soon" I think you may be referring to the promises of ABI stability? They kept promising that "soon" starting around Swift 3 (IIRC) and kicking the can down the road for a while there, but it is stable now on Apple's OSes. But I don't recall seeing promises of source stability back then; they were pretty open about the fact that the language was still evolving.
- hombre_fatal 6y agoSwift is trivial compared to the rest of iOS/macOS/iDevice development. CoreData, nasty Cocoa/AppKit APIs, SwiftUI buggyness, all the legacy objc cruft, 99% of resources online being for iOS, not macOS. Swift idiosyncrasies don't even put a dent in the learning curve imo. I don't think anything gets this across quite like onboarding experienced devs into a client app that haven't done mobile client dev before. They'll ask you completely reasonable questions about Appkit/UIKit/CoreData like why is NSBox used here and you realize 90% of the time your best answer is just "well, that's just kind of how you learn to do it over time." Very few questions about Swift itself.
- blondin 6y agoi agree with you on the iOS vs macOS comment! apple allowed this problem to happen. it's the same as allowing people to abuse SEO to get on the first page of results. apple told people that there is money in iOS and they went there. we are the worse. nobody is teaching you how to write a macOS app. heck, metal has been out for 6 years and there is zero book that will tell you how to set it up on the mac. if that goes on, metal will die because only few will use it. people are like metal is for library and framework and game engine builders. don't use it directly. yeah, and it is competing with and replacing opengl or vulkan. and people are using those directly. and there are bazillions of resources on those. kids are writing shaders in unity. oh let me give some kudos to the apple programming guides because they deserve it! i stopped looking for books and watching videos because of the iOS thing mentioned above. everything i needed was on developer.apple.com and i didn't know it. i started with the metal programming guide on my phone a few weeks ago. but that guide made it clear that i needed to understand the ecosystem first. so my detour took me through many others: the cocoa, the event system, the view hierarchy, etc. these guides have been the highlight of the past few weeks for me. they are better than most programming documentation out there. and i read them on my phone! i have 3 of them loaded in chrome on my phone right now. i still don't know what makes them so great but i intend to write about that at some point. one thing i figured is that they are light on code sample. reading code on the phone is really the worst. sorry long comment, but yeah, swift is not the best thing. i am finding great joy in objective-c and what came before because i went through these guides.
- julius_set 6y agoThis really just sounds like nit-picking, the language is miles ahead of most other languages.
- saagarjha 6y agoYou can criticize a language where it fails even if it is overall better than others.
- deleted 6y ago[deleted]
- ksec 6y ago>I would really hate to be learning Swift now. I started using it around the v2 release and I think it had nice syntax & was relatively small and opinionated. But the Swift team / Apple doesn't seems to be aware of it. ( At least a few internal Apple devs completely reject Swift for their project.) That is why I think Chris Lattner trying to make Swift scale from Javascript down to C was wrong from the start. And Swift will be like C# on Windows.