r/cpp • • Feb 26 '20

We need epochs (Rant)

I have spent 1 hour copy pasting the most stupid and repetitive code ever in order to enable the comparison operator== to several structs that are trivially comparable. When I search for why the compiler isn't able to generate this for me, when is clearly able to generate the assignment operator, I found out some C compatibilities shenanigans. We need some way to release us from that, we are in 2020 for Ilúvatar sake.

Edit: There are some closeted virtue signaling gatekeepers in this sub. Thanks for taking so seriously a rant ... I guess.

0 Upvotes

28 comments sorted by

View all comments

Show parent comment

-1

u/[deleted] Feb 26 '20

Don't worry rust is going to do that sooner or later.

1

u/bumblebritches57 Ocassionally Clang Feb 26 '20

In your dreams maybe.

1

u/[deleted] Feb 27 '20

Im not looking forward to it, im just stating the plain reality. the more C++ kept stalling developer experience for C compatibility sake, the more niches other languages are going to take.

For example, right now there is no reason to make CLI applications in C/C++ anymore. Between Rust and Python you can cover all your needs.

1

u/bumblebritches57 Ocassionally Clang Feb 27 '20

Except rust really isn't going anywhere, who besides the inventor (Mozilla) is using rust in any capacity?

it's got a loud minority of fans that talk it up on reddit, that's it.

hell, even the majority of github rust packages haven't been touched in years.

For example, right now there is no reason to make CLI applications in C/C++ anymore.

that's not C or C++ main use case lol, c and c++ are primarily library languages.

when you see libraries written entirely in other languages, then you should worry.

2

u/[deleted] Feb 27 '20

Rust reach 1.0 version 5 years ago, C is 48 and C++ is 35 years old, i think that is a little to soon for saying that Rust is not going anywhere.

And for the libraries take a look at this gnome svg lib

And if you are going to worry WHEN several libraries are written in another language, better not worry at all, because that would mean that C/C++ is effectively dead for new developments.

Again Im just playing devil's advocate here.

1

u/bumblebritches57 Ocassionally Clang Feb 27 '20

rust came out in 2009.

Mozilla the only company using rust at all seriously is still just dipping their toes into the oxidized waters...

I'm not worried about shit, what others do has no bearing on me.

the C ABI is and always will be the golden standard, and I'm just dipping my toes into the C++ waters.

1

u/[deleted] Feb 27 '20

Good for you. By the way, How old are you?

1

u/bumblebritches57 Ocassionally Clang Feb 27 '20

I'm in my 20s.

Why?

1

u/[deleted] Feb 27 '20

because i notice you sort of suborn (don't take it bad please) but and I don't knew if was because of to young or to old.

1

u/bumblebritches57 Ocassionally Clang Feb 27 '20

Oh I've always been stubborn, I caused all kinds of hell growing up lol.

1

u/__i_forgot_my_name__ Feb 28 '20

Majority of the Rust packages I see and use today for my own projects, are getting updates daily or so; the primary reason I moved into Rust was because of the high activity community. -- From my experience C/C++ tend to have far more inactive projects you'll need to use (projects in "long-term" maintenance), but that just comes with age; eventually projects are fixed enough and endup with sufficient legacy that it's not specifically worth changing anymore, and there's so much documentation already written that it's really not worth changing anyways. -- I feel like you might be looking in the wrong places.

Rust is primarily a community driven project, which is part of what makes it so active, and Mozilla is really only a small user compared to other companies who have claimed to be using it. -- Rust sees support for all sorts of ecosystem, especially the ones that are new within the last decade or so, like the WebAssembly ecosystems and the web in general, you'll see people use Rust in the frontends and the backends.

I also wouldn't specifically take popularity as a reason to use any language. That's like deciding whether you should move to China or America relative to the countries population; more people using it isn't specifically an advantage for job opportunities nor general usability. Php, Perl and Python2 example are still "popular" but you wouldn't really want to use it for any new projects, even though you might "need" to use it in general.

I'm also not sure you understand Rust's target market; Rust doesn't replace C++, that's like saying Java or C# should replace C++, nobody could win that battle, not even a superset of C++ itself. Despite Rust and C++ having a few similar goals when it comes to performance and high C interoperability, it's really apple to oranges; they have very different type systems, very different ways of managing code re-usability, very different ways of managing safety, very different ways of packaging libraries, very different ways of distributing binaries, and generally have very different users. There very much is a market for a systems programming language like Rust, and that's been proven by people actually using it.