There are just so many ways to solve a problem now that it's more or less impossible for someone to be familiar with all of them.
There are just so many ways to solve a problem now that it's more or less impossible for someone to be familiar with all of them.
People aren't expected to really learn that there is a "feature" called global-actor isolated conformances, but at some point they'll try to make a UI type conform to `Equatable,` and instead of an error saying you can't do that, they'll get a fixit about needing to specify the conformance as `struct MyUIType: @MainActor Equatable` instead.
I bet 99% of codebases won't use "method and initializer key paths," but there's really no reason why you should be able to get a key path to a property, but not a method. It just hadn't been implemented yet, and the language is more consistent now.
Personally, I think raw identifiers are kinda dumb, but that just means I won't use them. IMO there isn't really more cognitive overhead when using the language because it's possible to use spaces in function names now.
That said, some of the, erm, "new ways" to solve problems have been significant advancements. EG: Async/Await was a huge improvement over Combine for a wide variety of scenarios.
What is the alternative to Combine's CurrentValueSubject or combineLatest()?
> What is the alternative to Combine's CurrentValueSubject or combineLatest()?
combine latest et al can be found in async algorithms from apple*https://github.com/apple/swift-async-algorithms
* though current value subject is not there its not hard to make one if you need it
I gave up on C++ for good reasons, after spending roughly 20 years trying to make sense of it.
Coming back to a Swift codebase after a few months in different languages is surreal, I can't remember what half of it means.
I find you can do apply java and javascript type thinking to swift but they're less preferred.