News for hackers. Stuff that matters.
[dead]
Re:Std::visit is everything wrong with modern C++ (2017) by DerDangDerDang on Saturday December 05, 2020 @10:30AM (#25315232)
Against massive initial skepticism, I’m becoming very impressed with Rust. I’m now going to be ‘that guy’ - apologies.

After years of being annoyed by Rust people claiming C++ is dying or too unsafe or whatever, I expected this to be another C# - a sort of C-with-training-wheels for people who care more about productivity than perf. Something I could safely ignore.

This ‘borrow checker’ stuff sounds great for kids, but for disciplined experienced C++ guys it’s at best a non feature and at worst would just get in the way, like GC, right?

In fact, I’m finding the reduced mental overhead (not just from borrow, but from the language as a whole being smaller and more consistent) is a huge win. Even learning the language and stdlib as I go.

I’ll still use C++ proudly where it’s the best choice, but I’d put some effort into trying Rust first. As a cpp-master-race guy, that surprised the crap out of me.

Re:Std::visit is everything wrong with modern C++ (2017) by amelius on Saturday December 05, 2020 @10:39AM (#25315303)
Have you tried writing self-referential data structures, like doubly linked lists?
Re:Std::visit is everything wrong with modern C++ (2017) by Silhouette on Saturday December 05, 2020 @11:02AM (#25315480)
Why would you write your own basic data structures when the standard library provides them for you? I haven't written an implementation of a doubly-linked list by hand in a very long time.

If your point was about explicit ownership being a little more tricky with self-referential structures, that's true, though the existence of std::collections::LinkedList shows that it's entirely possible to manage these structures and at least you still get the benefits of explicit ownership for the structure and the data within it.

Re:Std::visit is everything wrong with modern C++ (2017) by amelius on Saturday December 05, 2020 @11:20AM (#25315648)
> Why would you write your own basic data structures when the standard library provides them for you?

I think the problem with this view is that Rust is not being used as a true programming language (like for implementing algorithms), but more as a "glue language".

If all the interesting stuff has to be done in libraries in "unsafe" mode, and all the uninteresting stuff (gluing) is done with borrow checking, then Rust is more a glue language. Which is fine. But don't call it a general purpose programming language.

Re:Std::visit is everything wrong with modern C++ (2017) by Silhouette on Saturday December 05, 2020 @11:45AM (#25315870)
I respectfully disagree. Using tools provided by the standard library is common practice in any general purpose programming language. It just means that the algorithms you're implementing can concentrate on the novel aspects that provide additional value and not get bogged down with reinventing wheels for the basic implementation details.

Also, you seem to be suggesting that it's necessary to use unsafe code to implement these data structures in Rust. For something like the doubly-linked lists that were mentioned in an earlier comment, it usually suffices to use tools like Option and Rc for the links and to encapsulate the logic that manages those links inside functions like push_back and pop_back that you are surely defining to mutate your data structure anyway. Is there something specific you have in mind where this kind of strategy doesn't work and unsafe code is the only solution?

Re:Std::visit is everything wrong with modern C++ (2017) by steveklabnik on Saturday December 05, 2020 @12:39PM (#25316442)
Someone above suggests boot::intrusive. Do you also think that means C++ is a "glue language"?
Re:Std::visit is everything wrong with modern C++ (2017) by xigoi on Saturday December 05, 2020 @12:45PM (#25316514)
So any language that doesn't force you to constantly reinvent the wheel is a “glue language”?
Re:Std::visit is everything wrong with modern C++ (2017) by j16sdiz on Saturday December 05, 2020 @11:21AM (#25315657)
I write my own basic structure when I need specific implementation for performance. Most of time its about memory layout or caching a specific internal pointer for some hot code.
Re:Std::visit is everything wrong with modern C++ (2017) by Silhouette on Saturday December 05, 2020 @11:39AM (#25315797)
Sure, but unless the high performance code you work with is very different in nature to the high performance code I've worked with, you probably have a small set of carefully implemented and probably very well optimised structures in your toolbox and write everything else using them. You do need to deal with the explicit ownership semantics in Rust when you're first implementing those tools, but that's a probably minor inconvenience up front and afterwards things mostly just work like the equivalent data structures in any other programming language, but with the added safety guarantees from the ownership system and borrow checker.
Re:Std::visit is everything wrong with modern C++ (2017) by bluecalm on Saturday December 05, 2020 @11:40AM (#25315818)
Double linked list is just an example. There are other both more useful and harder to generalize structures like various kinds of trees for example. Anyway, if your question is why implement your own data structures then it's very likely C/C++ isn't a proper tool for your job anyway.
Re:Std::visit is everything wrong with modern C++ (2017) by Silhouette on Saturday December 05, 2020 @11:54AM (#25315992)
There are other both more useful and harder to generalize structures like various kinds of trees for example.

Trees are usually easy because each node has a single parent all the way up to the root and ownership can follow the same hierarchy. More general graphs are a little more tricky, but the same techniques that you can use to implement a specific case like a DLL generalise. For example, in Rust, you can combine Option and Rc to handle, respectively, the intermediate states while the structure is being manipulated and the shared ownership semantics.

Re:Std::visit is everything wrong with modern C++ (2017) by nchi3 on Saturday December 05, 2020 @10:59AM (#25315456)
Self-referential data structures are a code smell in non-GCd languages, and I think I have neither used or written a doubly linked list since university.

You can do both in unsafe rust though. But you probably shouldn't no matter what high level non-GCd language you use.

/Another ex-cpp-master-race guy who has been impressed with Rust

Re:Std::visit is everything wrong with modern C++ (2017) by cycloptic on Saturday December 05, 2020 @11:34AM (#25315769)
I see doubly-linked lists and other self-referential structures all the time in low-level code. Boost even has a whole library dedicated to them: http://www.boost.org/libs/intrusive
Re:Std::visit is everything wrong with modern C++ (2017) by nchi3 on Saturday December 05, 2020 @01:15PM (#25316801)
Yeah, hence high level non-GCed language. Using heap allocated linked lists is rarely the way to go if you're not developing for embedded.

However, if you're developing for embedded you'll probably want to be familiar with unsafe either way if you're going to use Rust.

Regarding self-referencing: Rust encourages you to design differently, which I've found leads to nicer and more thought out designs most of the time. Not all algorithms are possible (or efficient) without it though, and for those you'll have to use unsafe if you _really_ have to implement them yourself.

Re:Std::visit is everything wrong with modern C++ (2017) by steveklabnik on Saturday December 05, 2020 @12:38PM (#25316429)
For a really interesting take on this area, see http://dtrace.org/blogs/bmc/2018/09/28/the-relative-performa...

Specifically, the discussion about intrusive vs non-intrusive data structures and their frequency.

Re:Std::visit is everything wrong with modern C++ (2017) by cycloptic on Saturday December 05, 2020 @03:28PM (#25318002)
It would be interesting to see how that measures up in a different test where the accesses are all from a cold cache.
Re:Std::visit is everything wrong with modern C++ (2017) by DerDangDerDang on Saturday December 05, 2020 @12:26PM (#25316312)
I have not. Does the borrow checker make things difficult? Isn’t there a weak_ptr equivalent?

Though honestly, in C++ it is very rare I use something other than vector (potentially wrapped for specific use case, like boost flat_map)

Re:Std::visit is everything wrong with modern C++ (2017) by steveklabnik on Saturday December 05, 2020 @12:37PM (#25316416)
There is a weak_ptr equivalent; the borrow checker makes it basically impossible to use references to implement it. You can still do it with raw pointers exactly like you would in C++ too.

(And yes, it's a niche data structure, vecs are far more common, but it's people's go-to "the borrow checker restricts you too much" example anyway.)

Re:Std::visit is everything wrong with modern C++ (2017) by DerDangDerDang on Saturday December 05, 2020 @12:55PM (#25316615)
Thanks, that’s illuminating.

Seems a counter productive go-to argument given the amount of effort we (c++ coders) generally put in to avoiding non-adjacent memory access :)

Re:Std::visit is everything wrong with modern C++ (2017) by steveklabnik on Saturday December 05, 2020 @01:10PM (#25316765)
You would think so, but it's sort of just become a standard thing on forums, someone claims that linked lists are impossible, someone else talks about how you can do them in various ways (possibly linking to the "Learning Rust with Too Many Linked Lists" book, which is awesome, by the way), and how you don't actually need them in real code, followed by someone saying that this is just Rust stockholm syndrome and they use linked lists all the time... just the fun of being on forums :)
Re:Std::visit is everything wrong with modern C++ (2017) by DerDangDerDang on Saturday December 05, 2020 @02:39PM (#25317607)
Haha, forums gonna forum I guess. Reminds me of the “but how can I trust std containers to allocate for me? Anything could happen!” crowd in the 90s and early 2000s.

FWIW I think the Rust community has done itself a disservice by focusing on the safety benefits. Const by default and move by default are much bigger deals in the day to day coding experience, but it’s hard to get across just how awesome they are.

That book looks great, thanks - should take me through a few corners I’ve yet to meet while keeping me entertained.

Re:Std::visit is everything wrong with modern C++ (2017) by steveklabnik on Saturday December 05, 2020 @03:21PM (#25317921)
You're welcome. I sorta kinda agree on the safety thing; I wrote a blog post that kind of kicked off a whole discussion about this a while back; https://brson.github.io/fireflowers/ is a really beautiful summary of all of that.
Re:Std::visit is everything wrong with modern C++ (2017) by DerDangDerDang on Saturday December 05, 2020 @05:07PM (#25318873)
That was a wonderful read.

After 20 years of C++ and about the same number of hours of Rust, Rust makes me feel like Fire Mario because when I come to do a strict correctness and memory efficiency pass after writing something - it’s already correct. I suspect this will have a compound interest-like effect, similar to good code coverage empowering change.

Re:Std::visit is everything wrong with modern C++ (2017) by dralley on Saturday December 05, 2020 @10:09AM (#25315062)
Rust and D are not "strictly worse". They are better in some respects and occasionally worse in others, but even there the gap has been shrinking.
Re:Std::visit is everything wrong with modern C++ (2017) by otabdeveloper4 on Saturday December 05, 2020 @10:20AM (#25315158)
The context makes it clear that what's meant is "strictly worse as a C++ alternative".

Rust, like you said, isn't there yet. And I'd take issue with the claim that the gap has been shrinking - C++ right now is developing at a faster pace than Rust.

Re:Std::visit is everything wrong with modern C++ (2017) by chromatin on Saturday December 05, 2020 @10:23AM (#25315178)
Rust is excellent overall, but is lacking in interoperability (I mean, it is capable -- but iterop is burdensome, relatively). Related to the overall topic of sum types, there is ergonomic support in the form of built-in enum.

D is excellent overall (and I think sadly under-recognized for this), but it is lacking in ecosystem. Related to the overall topic of sum types, there is an excellent library, `sumtype` which recently hit 1.0 status.

I much prefer either of these to modern C++.

Re:Std::visit is everything wrong with modern C++ (2017) by api on Saturday December 05, 2020 @10:27AM (#25315207)
Interoperability is generally a disaster. Most languages can interoperate with C ABI functions, but even that is painful in some cases. It seems like most languages consider this an afterthought when it should be a central consideration. There will never be a time when everything is written in just one language.
Re:Std::visit is everything wrong with modern C++ (2017) by jeltz on Saturday December 05, 2020 @10:47AM (#25315376)
The only languages I know of with good C interoperability are C++ and Zig. This is definitely an area where Rust could improve.
Re:Std::visit is everything wrong with modern C++ (2017) by chromatin on Saturday December 05, 2020 @10:01PM (#25320643)
D has crazy good and easy C interoperability.

There is a near 1-1 mapping of types. C interop was a major design goal.

Dstep, which uses llvm/clang as a library, can translate headers for you. dpp I believe automagically at compile time translates C++/C headers.

Re:Std::visit is everything wrong with modern C++ (2017) by agersant on Saturday December 05, 2020 @07:35PM (#25319820)
You can add Lua to this list!

https://luajit.org/ext_ffi.html

Re:Std::visit is everything wrong with modern C++ (2017) by touisteur on Saturday December 05, 2020 @12:57PM (#25316631)
Don't forget Ada where interop with C is baked in the language spec and interop with c++ has been muuuch improved some years ago.
Re:Std::visit is everything wrong with modern C++ (2017) by Silhouette on Saturday December 05, 2020 @02:14PM (#25317379)
How would you define "good C interoperability"?
Re:Std::visit is everything wrong with modern C++ (2017) by api on Saturday December 05, 2020 @03:39PM (#25318104)
Calling C functions with minimal fuss and good performance, which requires C header parsing and linking or DLL loading support. It also requires built in or standard library support for whatever convenience types and functions are needed to make using real C APIs pleasant and as safe as possible. Support for exporting functions and passing function pointers the other way is great too if it can be done.

Go with CGo is okay from a usability perspective but performance is poor. I haven't looked much at Rust's implementation so I can't comment. I've also heard Python is not bad.

Re:Std::visit is everything wrong with modern C++ (2017) by Silhouette on Saturday December 05, 2020 @04:23PM (#25318508)
Python was actually the reason I asked the question. There are multiple ways to integrate Python and C, depending on exactly what you want to do. The simplest is to use ctypes, which almost reduces calling C APIs in a DLL/SO to calling a function to load the shared library and then calling the APIs like any other function.

The most obvious practical limitation is that ctypes can only infer so much about the required parameter and return types of the C functions from how you call them, so you have to specify the types explicitly in your Python code in any other case. That's no harder than writing a C header file, though, and I expect there is probably a tool somewhere that would automatically generate the corresponding Python/ctypes code for the common use cases.

There are a few other warts that aren't quite as intrusive, including some restrictions relating to pointers and some verbose marshalling if you're passing strings around. But overall, it's a very convenient way to call out to C-style APIs from Python code that probably covers 95+% of practical use cases with only minor inconvenience compared to what you'd have written doing everything in either language on its own.

Re:Std::visit is everything wrong with modern C++ (2017) by vips7L on Saturday December 05, 2020 @11:40PM (#25321085)
Zig has the best C interop I've ever used. Just a simple import and it figures it out:

    const c = @cImport({
        @cInclude("types.h");
        @cInclude("stat.h");
        @cInclude("user.h");
    });
Re:Std::visit is everything wrong with modern C++ (2017) by vips7L on Saturday December 05, 2020 @11:09AM (#25315543)
I really wish D had the ecosystem. I think it could have excelled in a lot of the places Go has been used.
Re:Std::visit is everything wrong with modern C++ (2017) by api on Saturday December 05, 2020 @10:18AM (#25315144)
It’s not complex problems. It’s being close to the metal. Rust isn’t bad but it’s still not as good as C or C++ if you need to get every last bit of performance or need to be really close to the OS and hardware.

Rust is coming along though. It’s the first language I have seen that might unseat C++.

Re:Std::visit is everything wrong with modern C++ (2017) by MrBuddyCasino on Saturday December 05, 2020 @10:28AM (#25315214)
> Rust isn’t bad but it’s still not as good as C or C++

Can you elaborate in what way? I was under the impression the amount of low-level control was equal.

Re:Std::visit is everything wrong with modern C++ (2017) by steveklabnik on Saturday December 05, 2020 @12:40PM (#25316451)
I work at a company where we're doing software at all levels of the stack, from the firmware up. It is all in Rust. Even our firmware. It's working really well for us.
Re:Std::visit is everything wrong with modern C++ (2017) by elb2020 on Saturday December 05, 2020 @11:24AM (#25315688)
I think it's fair to call it a complex problem, if referring to the task itself, of creating performant software (which I assume is what he did). I agree with otabdeveloper in general. I'm learning C++, and over the past year there has been many occasions where I've found myself dumbfounded by patterns in the language. But, in 99% of the cases, the outcome is that the patterns are there for a reason. And the reason is performance.
Re:Std::visit is everything wrong with modern C++ (2017) by Cyph0n on Saturday December 05, 2020 @12:55PM (#25316610)
But Rust is a direct counterexample: it gives you comparable performance[1] to C++ while helping you avoid the common memory safety pitfalls of C++.

[1]: https://benchmarksgame-team.pages.debian.net/benchmarksgame/... (these benchmarks are not representative of all workloads, but it gives you a general idea)

Re:Std::visit is everything wrong with modern C++ (2017) by socialdemocrat on Sunday December 06, 2020 @12:18AM (#25321271)
Funny how people obsess about getting "every last bit of performance" and yet we are building applications in layers upon layers inside bloated Web browsers...

I think that is a bigger problem than using a language that gives you 10% less performance than C++. And anyway algorithms are typically are more important than the language in terms of performance.

Re:Std::visit is everything wrong with modern C++ (2017) by otabdeveloper4 on Saturday December 05, 2020 @10:28AM (#25315212)
> It’s the first language I have seen that might unseat C++.

Doubtful, as C++ has language standards and a visible, comprehensible story on how they evolve. C++ has also been evolving faster than Rust.

Right now Rust fills the "C++ with training wheels" niche - when you need a language in this space but don't have the energy or time to disentangle the sordid story of all the crufty legacy systems built around C++ after all this time.

But in principle if somebody made a well thought-out onboarding story for C++ then there's be little point in Rust.

P.S. But you say "my borrow checker" - well, sorry to disappoint you, people don't really care and actually view it as an impediment in learning Rust, not as a feature. If Rust had no borrow checker it'd be an even more popular language.

Re:Std::visit is everything wrong with modern C++ (2017) by Cyph0n on Saturday December 05, 2020 @10:42AM (#25315334)
The borrow checker is one of Rust’s selling main selling points, and was what got me into the language.

If you don’t see the value of compile-time memory safety in Rust, you probably haven’t spent hours debugging subtle runtime memory safety errors in a large C application.

Re:Std::visit is everything wrong with modern C++ (2017) by ncmncm on Saturday December 05, 2020 @01:17PM (#25316805)
This, anyway, is correct: In 30 years of coding maximal-performance C and C++ systems, I have not spent hours debugging subtle runtime memory safety errors. I have spent strictly more time tracking down compiler bugs.

I can count on one hand the memory errors I have debugged in five years. The longest took a half-hour. (Code that used a "relaxed" atomic load was moved to a place where it needed "acquire" -- which is the default.) So, I eagerly prefer (rounding up) 2.5 hours of debugging spent in five years over spending 5 extra hours every week -- 1750 hours in 5 years -- waiting on builds from a very slow compiler. (I don't know any reason why the Rust compiler could not be two orders of magnitude faster, and notably faster than a C++ compiler.)

My experience may be unusual in that I do not habitually depend on code badly-written by other people. My complaints about other people's code I do use are more typically about performance, conformability to requirements, or poor usability.

Re:Std::visit is everything wrong with modern C++ (2017) by Cyph0n on Saturday December 05, 2020 @01:56PM (#25317217)
I haven't been writing C for anywhere as long as you have, but I have definitely spent quite a bit of time printf() debugging and digging through corefiles in GDB. I also have never had to deal with compiler bugs, but that could be because IOS-XR uses a stable/old compiler toolchain.

I could be wrong, but I would wager that you are definitely an outlier among C and C++ developers. For the remaining majority, I believe that the compile-time memory safety guarantees that Rust provides are huge.

As to why your experience is different, it could be that you're simply (1) a talented programmer, (2) work with talented programmers, or (3) don't work on a large and complex legacy codebase, or some combination of the above.

Re:Std::visit is everything wrong with modern C++ (2017) by otabdeveloper4 on Saturday December 05, 2020 @11:50AM (#25315942)
Read my post again, please.

The people who choose Rust over C++ aren't (generally speaking, there are of course exceptions) doing because of the borrow checker. They're doing because Rust has Cargo and C++ doesn't.

Re:Std::visit is everything wrong with modern C++ (2017) by steveklabnik on Saturday December 05, 2020 @12:09PM (#25316142)
I think it is extremely hard to generalize here.
Re:Std::visit is everything wrong with modern C++ (2017) by nindalf on Saturday December 05, 2020 @10:22AM (#25315170)
I’d love to read your detailed comparison of C++ with all of the languages you mentioned. You seem certain that they’re strictly worse.

I can make the case that in some circumstances like low latency requirements, C++ is superior to a GC language like Haskell. But it’s harder to make the case that it’s “strictly” better.

Re:Std::visit is everything wrong with modern C++ (2017) by knuthsat on Saturday December 05, 2020 @10:31AM (#25315248)
Most abstractions discussed in the article have a runtime cost in Haskell and zero cost in C++.
Re:Std::visit is everything wrong with modern C++ (2017) by geofft on Saturday December 05, 2020 @10:13AM (#25315102)
The amount of complexity you can have in a system without it falling over is finite. You need to find simple tools, or at least comprehensible abstractions and simple compositions, to solve complex problems. You can only afford to use complex tools when solving simple problems.
Re:Std::visit is everything wrong with modern C++ (2017) by otabdeveloper4 on Saturday December 05, 2020 @10:18AM (#25315145)
C++ is a simple tool with comprehensible abstractions. You just don't understand it because you don't have experience with how computers and compilers work under the hood of dynamic languages.
Re:Std::visit is everything wrong with modern C++ (2017) by vnorilo on Saturday December 05, 2020 @10:35AM (#25315279)
This sounds pretty condescending to me. I've worked on C++ for a long time, including on bare metal and compilers, and yes, the abstractions are totally comprehensible. But keeping them in your headspace is a full time job. The sheer size of the standard belies "simple" tool.
Re:Std::visit is everything wrong with modern C++ (2017) by User23 on Saturday December 05, 2020 @10:54AM (#25315418)
I used to sit next to a member of the C++ standards committee. He was quite open that he didn't fully comprehend the abstract machine and had to rely heavily on documentation. And as you'd expect he's a wizard at C++. There are a lot of great things you can say about C++, but that it's easy to understand is not one of them.
Re:Std::visit is everything wrong with modern C++ (2017) by geofft on Saturday December 05, 2020 @10:49AM (#25315383)
(It's also very funny because deeply understanding how compilers and computers work under the hood and making sure our C++ code keeps running is, in fact, one of the things I do in my full-time job.)
Re:Std::visit is everything wrong with modern C++ (2017) by snazz on Saturday December 05, 2020 @10:22AM (#25315171)
That’s a big assumption to make. I think it’s valid to say that C++ is complex and more difficult to understand than other compiled languages without resorting to ad hominem arguments.
Re:Std::visit is everything wrong with modern C++ (2017) by otabdeveloper4 on Saturday December 05, 2020 @10:33AM (#25315267)
Haskell is much more complex than C++, for one example. (How many language extensions does Haskell have now? A hundred?)

C++ is easy to understand when you understand the mental model its abstractions target.

(In some sense you're right: the mental model of Haskell is mathematical, while the mental model of C++ is some sort of multi-core "Harvard architecture" machine. While it's true that math is a lot easier for the human brain to grasp, this isn't really related to language complexity per se.)

Re:Std::visit is everything wrong with modern C++ (2017) by detaro on Saturday December 05, 2020 @10:31AM (#25315238)
To be fair, the root comment started by suggesting mental illnesses in C++ programmers, so charged responses are to be expected.
Re:Std::visit is everything wrong with modern C++ (2017) by nchi3 on Saturday December 05, 2020 @10:35AM (#25315273)
Stockholm syndrome isn't a mental illness, nor is it derigatory.
Re:Std::visit is everything wrong with modern C++ (2017) by detaro on Saturday December 05, 2020 @12:40PM (#25316457)
Suggesting everyone using C++ isn't capable of properly evaluating it (which the comment author can clearly tell from the outside, for every use case) is "not derogatory"?

(and from what I understand "Stockholm syndrome" is not classified as a medical condition because it's questioned if it actually exists as thing that can be usefully delineated, not because it wouldn't qualify)

I'm certainly not claiming "C++ is perfect and everything else is useless" or "Rust doesn't stand a chance", but this "there has to be something wrong with you if you use it/ever consider it more suitable" is seriously annoying, and disappointing to see as the top comment here (even if it's not the worst pro-rust denigration of C++-users I've seen). And is damaging the chances Rust et al have in these spaces.

Re:Std::visit is everything wrong with modern C++ (2017) by nchi3 on Saturday December 05, 2020 @04:06PM (#25318361)
Medical condition is a very different thing from a mental illness though. I'm quite sure there aren't mental _illnesses_ which last 1-2 days like Stockholm syndrome does.

>Suggesting everyone using C++ isn't capable of properly evaluating it (which the comment author can clearly tell from the outside, for every use case) is "not derogatory"?

I see it more as "I wonder if they have given other languages a chance?". There's definitely a lot of C++ devs who aren't giving for example Rust a try, and don't see the negatives of C++ because they haven't experienced anything else lately.

If anything, it was derogatory towards C++, not the devs.

Re:Std::visit is everything wrong with modern C++ (2017) by detaro on Sunday December 06, 2020 @08:29PM (#25328496)
"Stockholm syndrome" suggests a lot more "aren't mentally capable of" than "wonder if they have".

And the answer to the question "I wonder if any C++ developer has ever given other languages a chance" is also a quite obviously "yes" (remember, the claim was about "all"), not "no, they never have".

Re:Std::visit is everything wrong with modern C++ (2017) by tener on Saturday December 05, 2020 @10:27AM (#25315205)
Simple using which metric? As far as programming languages go, C++ is one of the most complex ones. Which is funny because e.g. Haskell has way more advanced type system and still is easier to understand.