Swift has a clear policy on this, but basically: it's worth breaking things early on rather than freeze in bad design decisions. They provide a code migrator to help with this pain.
However, this was only in the early releases. The plan is to stop breaking changes soon and freeze the ABI. They're a little behind schedule for this, but it should happen soon.
> First, ABI stability is the center focus of Swift 5 — and we will pivot much of our prioritization of efforts for Swift 5 around it. With Swift 4, ABI stability was a strong goal. In Swift 5, it is a requirement of the release. Whatever ABI we have at the end of Swift 5 is the ABI that we will have. ABI stability is an important inflection point for the maturity of the language, and it cannot be delayed any longer.
> ...
> Module stability is a stretch goal for Swift 5, but even without module stability we can still achieve the primary value of ABI stability.
>In Swift 5, [ABI stability] is a requirement of the release.
Once Swift 5 comes out, does that mean it's "safe" for people to write things in Swift?
My company still has apps stuck on Swift 2.x because we simply can't give people the time to fix the hundreds of issues that happen when we try to upgrade the project to Swift 3. Unfortunately the migration tools just don't work and we end up having to either fix almost every line of code or revert the repo. Everyone is frozen on a specific version of Xcode as Swift 2.x isn't supported anymore. It's a complete mess, and hearing year on year "this is the last time we'll break everything" is getting very tiring.
For a variety of reasons we're likely to rewrite our app in the coming months. I'm very seriously considering pushing for writing it in Objective-C because it's just more stable than Swift. We can't do a yearly rewrite, especially as mobile is going to be a bigger focus for us this year and next year.
Can you promise me if I push for the rewrite in Swift 5 it will be the last time we need to do that (for a reasonable amount of time, say 5 years? Or that changes will be far far more gradual and can incorporate it with our workflow?).
If not, we're going to abandon Swift because it's already left a horrible taste in our mouths.
> Once Swift 5 comes out, does that mean it's "safe" for people to write things in Swift?
It means it's "safe" to ship binaries to people without providing the source and it should remain compatible forever™.
> It's a complete mess, and hearing year on year "this is the last time we'll break everything" is getting very tiring.
Swift 3->4 was much easier. Of course, if you're still stuck on Swift 2 this isn't going to help you much…
> Can you promise me if I push for the rewrite in Swift 5 it will be the last time we need to do that (for a reasonable amount of time, say 5 years? Or that changes will be far far more gradual and can incorporate it with our workflow?)
That's how it was supposed to be in Swift 4, and it should get better from there.
However, this was only in the early releases. The plan is to stop breaking changes soon and freeze the ABI. They're a little behind schedule for this, but it should happen soon.