5 ms·
C++ has a standard that is thousands of pages long and I needed to look something up in it exactly zero times. On the other hand, I encountered hundreds of segf
by lpapez 5y ago
C++ has a standard that is thousands of pages long and I needed to look something up in it exactly zero times. On the other hand, I encountered hundreds of segfaults and race conditions and unlike Rust the well defined C++ language did nothing to prevent it. I would take a poorly specified borrow checker over extremely pedantic spec in a heartbeat.
- mike_hock 5y agoI drink milk daily and I've had to milk a cow exactly zero times. On the other hand, I've had to go to the grocery store to buy milk hundreds of times. Obviously the spec isn't meant to be a necessary read for end users.
- jepler 5y agoMy experience is different. The C/C++ (draft) standards documents are regular reference material for me, alongside web searches, man pages, & experimentation. (the draft standards are available for free in pdf format and for all practical purposes I've been able to treat them as the real thing) Experimentation is great for determining what the implementation you have right in front of you does, but not what is actually guaranteed. Trusted reference web pages are great (in fact, cppreference is AWESOME particularly for highlighting text that applies version-by-version of the C++ standard) but don't always cover everything. "I googled my error message" hits are so-so (but they may help you solve your problem) But the standard is the document that really lets you get into "how SHOULD it work", even while doing battle with 2 or 3 different compilers each of which implement a subset of the language you are theoretically programming in. (It's getting better, but finding a compatible subset of C++ supported by MSVC, gcc and clang used to be an interesting puzzle. And what a bummer to "switch to C++14" -- only with a list of caveats longer than most people will even read through, because of differential language & library support) I'd also just recommend becoming comfortable finding & extracting data from a daunting document like the C++ standard! It's a skill that will stand you in good stead, and I feel like being able to do this is one of the things that led to having my technical expertise well appreciated at work.