Microsoft and Google each have languages/ecosystems with larger developer share (Google at over 6% for Dart, and Microsoft at over 27% for C#).
[1] https://survey.stackoverflow.co/2023/#technology-most-popula...
> It would be a completely new source of developers for these platforms.
I have no idea who you're referring to here. Who are the developers that are locked-in to iOS/MacOS but would consider ChromeOS or Windows if it supported Swift better? I cannot think of a single person I know that fills that bill. If anything it's the other way around, where people end up switching away because they don't have any use for Swift/AppleScript.
Opposite is not true though, there are lots of troubles you have to go through to have Swift on Android/Windows.
Very often, especially in startups, when the new app is created, it is first created for iOS and then for Android. Having proper Swift support would reduce effort for bringing apps to Android/Windows.
The future is not that far off where you can write a 100% native Android app and, minus any Android OS-specific functionality, port it over as-is to iOS and desktop.
Yes it can. It's just Apple can't be bothered - most of the work to do that doesn't benefit Apple - it does benefit the Swift ecosystem and community of devs, but not Apple - the venn diagram of Apple vs the Swift dev community overlaps but doesn't completely close.
Swift came out in 2014 - Windows support for the compiler came out in 2020. That's it. They haven't bothered to upgrade the tooling support in VSCode or any other app because most VSCode users aren't Apple devs. The ball is literally in Apple's court - no one elses.
Plus, honestly, moving from swift to kotlin or even dotnet is marginal. The problem is getting into the qwirks of the underlying frameworks like swiftui, the ios sdk, the android sdk, and the conventions of these platforms. Language itself is relatively marginal in that. So really I don't see the value in what you're claiming.
Apple doesn't really care about Swift outside their wallet garden. How dare other companies refrain from investing in such a wonderful creation!
Investing in Swift would to an extent canibalize Go, Dart/Flutter, TypeScript, C#. You know, the technologies which have creators that actually care and invest billions in cross-platform development.
Not to mention fragmentation.
Apple doesn't even care about Linux running in their own hardware. Their contribution towards that goal ranges from hostile to scraps, depending on who you ask.
In fact, they don't even have to do that much for Swift. They don't have to develop neither the language nor the compiler.
They need to do similar to what The Browser Company did, exposing and allowing usage of their APIs from Swift, and maintain it as their API evolves.
If The Browser Company could afford it, while developing the browser, Google and Microsoft can afford it as well.
Commoditizing your own product is never in a company's best interest so don't expect it to happen willingly.
If The Browser Company could afford it, 3 trillion USD market cap Apple can afford it as well.
I mean, this is just absurd logic. How is the lack of Swift support on non-Apple platforms somehow up to Google or Microsoft? The burden to support more platforms is on the language developer, not the platform dev.
I wouldn’t assume that any iOS engineer would be jumping all over the opportunity to make Android or Windows apps just because they can do it with Swift. They have their (typically pretty lucrative!) niche and are happy living in it.
AppKit is still dominant on macOS (despite the addition of Catalyst), UIKit is the chief framework on iOS/iPadOS/tvOS/visionOS, SwiftUI is native on watchOS and mostly wraps AppKit/UIKit on the other platforms. macOS is oriented around KB+mouse usage, iOS/iPadOS/watchOS are touch-dominant, tvOS is made to be remote-friendly, and visionOS is oriented around eye navigation and hand gestures.
Apple claimed they were running OSX back at the iPhone launch, but it was truly very stripped down to accommodate the underpowered hardware, and they've only made incremental, very targeted expansions in the last 16 years.