3 ms·
> nobody thinks that the Swift libs will be wrong as a first guess This is highly dependent on which version of Swift you started with! When Swift introduced t
by gh123man 5y ago
> nobody thinks that the Swift libs will be wrong as a first guess
This is highly dependent on which version of Swift you started with! When Swift introduced the new substring API I hit a bug where certain UTF-8 character sequences caused an index out of bounds error internally. Unfortunately we learned this in production when an entire organization couldn't launch our app due to a string they were feeding through it.
That is how your trust in the standard libs is forever broken. Library and compiler bugs were quite common in the Swift 1-3 days.
- jcelerier 5y agoYeah, over the course of my allegedly short career (I'm 29) I've reported dozens of bugs against GCC, Clang, MSVC, binutils, Qt, SDL, glibc, PortAudio, macOS and other foundational stuff... I'm not saying I automatically assume "toolchain bug", but my cutoff for seriously pondering "is it a bug in $underlying_stuff" is around 30 minutes of "I really can't see where in my code things were done wrong" and so far this heuristic has consistently held...
- deleted 5y ago[deleted]
- resonious 5y agoYup this kind of thing piles on and you start to understand why a lot of experienced programmers eventually adopt a "no libraries" policy. I've also found that depending on my employer, the open source codebases we use often don't actually hold up to the standard of quality that we hold our own code to. But we don't check it because all libraries are assumed to work.