5 ms·
I'm a big fan of the idea of Swift as a cross platform language general purpose langauge, but it just feels bad without Xcode. The Vscode extension is just okay
by Decabytes 2y ago
I'm a big fan of the idea of Swift as a cross platform language general purpose langauge, but it just feels bad without Xcode. The Vscode extension is just okay, and all of the tutorials/documentation assumes you are using Xcode.
A lot of the issues that Swift is currently facing are the same issues that C# has, but C# had the benefit of Mono and Xamarin, and in general more time. Plus you have things like JetBrains Rider to fill in for Visual Studio. Maybe in a few years Swift will get there, but I'm just wary because Apple really doesn't have any incentive to support it.
Funnily enough, the biggest proponent of cross platform Swift has been Miguel De Icaza, Gnome creator, and cofounder of Mono the cross platform C# implementation pre .net core. His Swift Godot project even got a shout out recently by Apple
- giancarlostoro 2y agoThe only thing holding it back is Apple not investing into making it happen. Swift is in a weird spot where it has so much potential, but without investment in the tooling for other platforms (which is uncommon for Apple in general) it just wont happen, at least not as quickly as it could.
- refulgentis 2y agoI wouldn't describe Swift itself as having so much potential: I loved it and advocated for it, for years. After getting more experience on other platforms and having time to watch how it evolved, or didn't as per TFA, it's...okay to mediocre compared to peers - Kotlin, Dart, Python come to mind. If Foundation was genuinely cross platform and open source, that description becomes more plausible for at least some subset of engineers. * (for non-Apple devs, Foundation ~= Apple's stdlib, things like dateformatting) I don't mean to be argumentative, I'm genuinely curious what it looks like through someone else's eyes and the only way to start that conversation is taking an opposing position. I am familiar with an argument it's better than Rust, but I'd very curious to understand if "better than" is "easier to pick up" or "better at the things people use Rust for": i.e. I bet it is easier to read & write, but AFAIK it's missing a whole lot of what I'll call "necessary footguns for performance" that Rust offers. * IIRC there is a open source Foundation intended for Linux? but sort of just thrown at the community to build.
- TheFragenTaken 2y agoI'm not deep in Swift, but this would make it seem a reimplementation of Foundation is open source: https://github.com/apple/swift-corelibs-foundation/tree/main https://github.com/apple/swift-corelibs-foundation/tree/main
- sunnybeetroot 2y agoIm surprised to see Python in that list. Swift being type safe and Python not puts Swift miles ahead.
- refulgentis 2y agoOne of those awkward things where I don't like it, and wouldn't go back to nulls that blow up. But as far as being the right tool/accessible it ended up winning use cases where I expected scripting and Playgrounds to have mindshare
- wiseowise 2y agoPython has Mypy (yes, it’s good enough, don’t bother arguing with me that’s it’s not “real”) and ecosystem is leagues above anything Swift can offer.
- giancarlostoro 2y agoPython is the new Perl. Heck its the lingua franca of ML / AI and has been for data science for a while. Dynamic types dont mean you cannot compete with a typed language. Python has type hints which gives the benefit people are usually after, catching bugs / issues ahead of time. Theres a library for just about everything in Python. I dont know that I can say that about Swift.
- smaudet 2y ago> The only thing holding it back is Apple not investing into making it happen. This seems to be a (bad) pattern with Apple, one that Google used to (and still does) get a lot of flack for, this habit of not investing in things and then thing dying slow, painful deaths. E.g. I remember this criticism being leveraged at e.g. Safari a lot. But, for better or worse, Apple is not a technology company, really, its a design company. They focus on their cash-cow (iPhone) and main dev tools (macbook) and nearly everything else is irrelevant. Even their arm-laptops aren't really about being a great silicon competitor, I suspect. Their aim is to simplify their development model across phone/laptop/tablet and design seamless things, not make technically great or good things. The reason(s) they haven't turned (as much) to enshittification probably are that a) it goes against their general design principles b) they have enough to do improve what they have and so release new stuff c) they aren't in a dominant/monopolistic market position where they can suddenly create utter trash and get away with it because there's nothing else. And yes, they exhibit monopolistic behaviors within their "walled garden", but if they make a product bad enough, people can and will flee for e.g. Android (or possibly even something microsoft-ish). They can't afford to make a terrible product, but they can afford to abandon anything that doesn't directly benefit their bottom line. Which is why I suppose I generally stopped caring about most things Apple.
- smaudet 2y agoI don't mind if people disagree with my viewpoint, but I'd appreciate the discussion.
- elpakal 2y agoI use a swift toolchain with JetBrains' CLion (for CLIs) and it's pretty good and quite refreshing when compared to Xcode.
- einsteinx2 2y agoDoes it properly syntax highlight and autocomplete in CLion?
- JackYoustra 2y agoI would say the opposite, actually: at least on large pure swift projects, Xcode grinds to a halt. Many of its features come with unacceptable performance cliffs which are impossible to patch. I ran into a particular problem with the build documentation command recently: https://www.jackyoustra.com/blog/xcode-test-lag https://www.jackyoustra.com/blog/xcode-test-lag
- ivm 2y agoC# has been decent on Mac since the early 2010s (MonoDevelop, Unity3d), and mobile .NET has been pretty robust on iOS and Android for about a decade, with plenty of NuGet libraries available. Meanwhile, Swift has a long way to go to reach at least the state of Kotlin Multiplatform, which is still mostly in beta and lacks libraries that can work outside of Android.
- pjmlp 2y agoC# also has the issue that while the .NET team is making heroic efforts for .NET to be a good cross platform citizen, upper management would rather sell Visual Studio and Windows licenses, alongside "works best in Azure" frameworks.
- rochak 2y agoI can’t be bothered to use a language that doesn’t have a good LSP (need it for Neovim), so Swift is an easy pass.
- chrisandchris 2y agoLSP?
- debugnik 2y agoLanguage Server Protocol, see https://microsoft.github.io/language-server-protocol/ https://microsoft.github.io/language-server-protocol/ It isn't a particularly good protocol specification, but at least it got adoption thanks to Microsoft offering a reference client implementation as a library for VS Code extensions, and other editors like Neovim adding support in some form.
- msk-lywenn 2y agoWhat's wrong with Swift's LSP?