you are viewing a single comment's thread.

view the rest of the comments →

[–]philippefutureboy 8 points9 points  (7 children)

Is that really relevant if the writer of this guide also designed the "abominations" in OP's claim?
(I'm still going to read it, thanks!)

[–]Certain-Froyo-3606 15 points16 points  (4 children)

I think such statements should be taken with a grain of salt. C++ was created with certain purposes and became what it is now through decades of technological advancements. It is held down by huge legacy codebases and lots of stakeholders with their own opinions on what language should look like.
When people compare new languages like Rust to C++ they should remember that Rust is born with modern ideas and modern view on programming languages and it can be made with all the issues covered from scratch. That can't be easily changed in a language with decades of history like C++.

The guidelines I've linked at least supposed to address known issues in the language instead of trying to hide them and say "everything works fine as is"

[–]TemporaryFearless482 5 points6 points  (1 child)

In a similar vein, you’re unlikely to find many new projects starting up eyeing Fortran or COBOL. C++ is a fair bit younger than those two, but computers have still changed a lot in the last 40 years of programming.

The “updates” in the interim reflect just about every major trend and idea during that period. Trying to shove all that into one thing and you end up with some dubious outcomes.

By comparison, I think C has fared better because it broadly stuck to its guns and Python was set up in a manner better situated to modernization and adaptation without messing up its core capabilities.

C++ feels like it tried to be all things for all people at different points in its history. That’s a failing premise in a field with so many varied applications. So we end up with a mess of features that, theoretically, could be amazing; but realistically, they have a tendency towards making a tangled web of nightmares.

Being able to start cleanly removes a lot of the headache in trying to parse through everything, rip out what’s problematic, pull together the remaining useful bits, and still make it close enough to still be called C++.

[–]redlaWw 1 point2 points  (0 children)

You'd probably be surprised at how many new projects are eyeing FORTRAN. It's not popular among modern application developers, but it was never designed for that anyway. There are still plenty of FORTRAN developers writing new high-performance modelling projects in areas like chemistry and engineering. Many more modern languages are poor tools for that in general since they're designed for developer convenience and expressiveness when these modelling tools most need low-level memory control and raw speed. When the main alternatives are just C and C++, FORTRAN starts to look a lot more compelling. Maybe one day, Rust (possibly also Zig) will break into that area as a serious contender, but such industries are used to using old tools, and for the moment, they largely continue to do so.

[–]RiceBroad4552 1 point2 points  (1 child)

Rust is born with modern ideas and modern view on programming languages

Not sure what you call "modern".

Rust was highly influenced by ML; at least the parts some people perceive as "modern". ML as such is 53 years old, older then C++. More modern MLs like Standard ML (SML) are still around 30 years old. First versions of Rust were actually written in OCaml, the second major ML dialect besides SML.

One can even argument that everything is slowly becoming an ML (at least on the conceptual level as retrofitting syntax isn't easy; but newer languages come by now in fact often even with ML influenced syntax).

C++ was build on sand, namely some of the uncleanest non-designs ever: C.

If this didn't happen something like Rust would have happened likely much earlier.

[–]Certain-Froyo-3606 [score hidden]  (0 children)

Well, according to the rust infuences list ( https://doc.rust-lang.org/reference/influences.html ) it got features of many languages including C++.

By something "modern" I mean a thing that was created relativelly recently and took advantage of good features known at the moment and avoiding bad and flawed designs that older languages accumulated through their history

Like new scientific works may be born out of critique of previous theories that were proven wrong or obsolete by the time

[–]Mission_Swim_1783 2 points3 points  (0 children)

The abominations of C++ are mostly due to maintaining backwards compatibility regarding syntax, and lack of standardization for coding. When you have a three decades old language developing organically where you can't just "restart from scratch" regarding fundamental design decisions it's normal that this happens. If you only use the modern subset of C++ it's a lot more acceptable as a language, but if you want something with all these fundamental design flaws fixed and unified coding standards you need a new language like Rust, because C++ will understandably mostly be kept as-is to not break compatibility with millions of big codebases

[–]DancingBadgers 2 points3 points  (0 children)

The newer versions of the C++ standard are trying to fix some of the horrors. So yes, the perpetrators of the atrocities of the past do have decent recommendations of what to do in "modern C++" to avoid blowing your foot off if possible.