2 ms·
> Notably it doesn't solve anything about versioning. It does promise backwards compatibility. How is that not sufficient?
by the_mitsuhiko 4y ago
> Notably it doesn't solve anything about versioning.
It does promise backwards compatibility. How is that not sufficient?
- kevincox 4y agoThat just pushes the problem onto the user. There is lots of well-documented problems with C versioning. Just saying "don't change the size, order, alignment or layout of anything ever" isn't a great option, it can be done (Microsoft has done a pretty good job) but it requires infinite foresight and is very expensive. Swift allows libraries to naturally evolve while maintaining comparability. Most things that you would expect to work (add a new field) just work. Good luck adding a new field to `jmp_buf`. It's effectively impossible to do in an ABI compatible way. The fact that C's ABI is stable/backwards compatible doesn't help. Basically a backwards compatible ABI is the absolute minimum requirement for making backwards compatible libraries. Having more options removes heaps of complexity for library authors.
- the_mitsuhiko 4y agoThat’s a fair ask but I’m quite okay with that not being solved. Once the building blocks are stable you can build on top of that.