7 ms·
> Swift is better for writing UI and servers and some parts of compilers and operating systems. Swift is better for some UI and some servers/operating systems.
by talldayo 2y ago
> Swift is better for writing UI and servers and some parts of compilers and operating systems.
Swift is better for some UI and some servers/operating systems. A considerable problem with Swift's adoption is that zero attention has been given to ergonomics on other platforms which has left it as the Xserve of programming languages for quite a while now.
If the Foundation framework and SwiftUI paid serious attention to non-Apple platforms, then Swift itself might have a chance. Until then, even C# is going to look more attractive for cross-platform devs that don't want to drown their software in ifdefs.
- amichail 2y agoCan't you use Qt with Swift's bidirectional C++ interoperability?
- neonsunset 2y agoYou can. But you can also use Avalonia*, Uno Platform* , Gir.Core or whatever currently maintained Qt binding library is for .NET. The FP and syntax advantages listed in the article exist in equal measure in C#, and so do zero-cost Rust-style abstractions. Swift is a language with a lot of potential, but it has a lot of work ahead of it, the work that was done for .NET's performance, cross-platform support, tooling ecosystem and OSS-focused development process. *both of which have SwiftUI style extensions for declarative UI definition and MVU patterns. Avalonia even has the F# version of that.
- talldayo 2y agoI mean, you can use all of POSIX with C FFI if you wanted. But that goes for most languages, and it's a far cry from the convenience of a well-made standard library. People want Apple to stop pretending like it's impossible to support other OSes, it's really that simple. If they want their language to have serious popularity, they have to act like a real Open Source maintainer and not a business. Swift's adoption outside of Apple developers forced into using it is more or less sabotaged by Apple's decisions. Whether they realize it or not, this behavior is undermining Swift's credibility and likely pushing people onto C++/Rust where they can use LLVM without limitations.
- Someone 2y ago> If the Foundation framework and SwiftUI paid serious attention to non-Apple platforms They started late, but isn’t https://github.com/apple/swift-foundation https://github.com/apple/swift-foundation paying serious attention to non-Apple platforms now? SwiftUI, I think, isn’t as essential, as it isn’t really possible to create a good cross-platform Ui library (and yes, that means I think running iOS apps on MacOS can’t provide an optimal experience)
- talldayo 2y agoI'm just calling it like it is. I'm a Rust dev that really doesn't look at Swift with much hope. It's not a language that performs consistently across platforms, which is documented well in the repo's Issues tab. I just don't have the time or patience to work with a language that treats me as a platform adversary. If Apple doesn't go the extra mile to make their language attractive outside their ecosystem, they're just not going to compete in the greater programming community. Rejecting it on principle is a no-brainer for any cross-platform project. The case for Swift is shallow, even if you're a Mac-native dev. The worst part is, Swift is a perfectly fine language on paper. It's got Lattner behind it, it's got literal trillion-dollar corporation funding behind it, and interfaces with LLVM to boot. It's lovely! My problem with Swift has always been Apple's attitude towards their own language and how desperate they are to reject non-ecosystem users. My life is too short to put up with nonworking language primitives in 2024. It pains me to say it, since Swift is so cool, but there are several better languages.
- deleted 2y ago[deleted]