News for hackers. Stuff that matters.
Re:Building a Cloud Database from Scratch: Why We Moved from... by lelanthran on Friday February 10, 2023 @09:55AM (#34740428)
> It’s basically a compiler enforced set of C++ best practices. It’s strange how hostile some in the C++ community are to Rust.

Well, the syntax is alien and new, it doesn't do OO the way 9 out of 10 working developers expect it to, almost all C++ popular design patterns have to be rejected, many of the claims("fearless concurrency") are exaggerated and the Rust evangelists are really really toxic when referring to C++ or C, often simply claiming that fewer bugs is worth the tradeoff from switching to Rust.

I literally saw a comment on HN this past week complaining that OSes are not switching to Rust, almost completely ignoring the fact that any rewrite of a 3 decades old codebase is going to introduce more bugs than it is going to prevent, even if you have perfect memory safety (which you won't, in an OS).

In all honesty, Rust would have been adopted orders of magnitudes faster had Rust evangelists been welcoming, and not accused of being defensive or hostile.

I mean, look through this very page full of comments, and be honest, how many of the comments talking about C++ developers are welcoming to C++ developers?

Re:Building a Cloud Database from Scratch: Why We Moved from... by Taywee on Friday February 10, 2023 @10:04AM (#34740543)
I've seen an order of magnitude more people complaining about Rust evangelists as I've actually seen Rust evangelists, and they've been significantly more hostile and toxic.

The majority of Rust programmers I know were C++ programmers in the past. Many, including myself, use both professionally.

Re:Building a Cloud Database from Scratch: Why We Moved from... by lelanthran on Friday February 10, 2023 @10:34AM (#34740973)
> I've seen an order of magnitude more people complaining about Rust evangelists as I've actually seen Rust evangelists, and they've been significantly more hostile and toxic.

Does this, to you, look like a response that is welcoming to C++ devs? I gave careful and impassive reasons, and you strike back with literal ad hominem attacks.

This sort of reply is what makes Rust, as a community, look shallow-minded and toxic.

Re:Building a Cloud Database from Scratch: Why We Moved from... by Taywee on Friday February 10, 2023 @03:43PM (#34745551)
You said Rust evangelists are toxic and exaggerating. I said that I've seen the more of the same in the other direction, and I'm the one striking back with literal ad hominem, and "shallow-minded and toxic"? My response isn't all that difference in tone and content to your own comment, but you've come back way harder at me personally than I was being in general.
Re:Building a Cloud Database from Scratch: Why We Moved from... by humanrebar on Friday February 10, 2023 @10:13AM (#34740660)
The headlines these days are definitely hostile, though. C++ is unsafe, a legacy language, etc.
Re:Building a Cloud Database from Scratch: Why We Moved from... by blub on Friday February 10, 2023 @11:22AM (#34741752)
Look and you shall find. Third comment from the top: https://news.ycombinator.com/item?id=34741241

That jumble of ideas is a good example of the arrogance directed not only at C++ programmers, but also Golang and C.

Re:Building a Cloud Database from Scratch: Why We Moved from... by Taywee on Friday February 10, 2023 @03:57PM (#34745738)
I'm not saying it doesn't exist. I'm just saying I've seen way more griping about Rust evangelists than I've seen actual Rust evangelists. For every crazy Rust post like that, I've seen at least 5 of people complaining about crazy rust posts like that. I've seen plenty of articles with comments crapping on Rust evangelists when they weren't even in the comments at all.
Re:Building a Cloud Database from Scratch: Why We Moved from... by pharmakom on Friday February 10, 2023 @11:24AM (#34741781)
OOP is not C++ best practice these days. For me C++ best practice is:

- Smart pointers

- auto and const references all over the place

- RAII

- Pure data structs

- Free functions

- At little bit of templating but not too crazy

Modern C++ reads a bit like JavaScript strangely!

Re:Building a Cloud Database from Scratch: Why We Moved from... by Shorel on Friday February 10, 2023 @12:30PM (#34742803)
> Modern C++ reads a bit like JavaScript strangely!

I yield to your comment.

Re:Building a Cloud Database from Scratch: Why We Moved from... by FpUser on Friday February 10, 2023 @02:04PM (#34744137)
There is no "best practice". It depends on context. OOP is good for some things and not that much for others. Same goes for your list of "best" practices. Dismissing a paradigm in totality because some Joe Shmoe of today has declared it non cosher looks rather more like a religious statement than a practical choice.
Re:Building a Cloud Database from Scratch: Why We Moved from... by lelanthran on Friday February 10, 2023 @02:32PM (#34744552)
> OOP is not C++ best practice these days.

I didn't say it was.

I didn't say anything about best practice, only about familiarity.

Re:Building a Cloud Database from Scratch: Why We Moved from... by pharmakom on Friday February 10, 2023 @04:01PM (#34745790)
Good point. Bad ideas don’t die, only practitioners
Re:Building a Cloud Database from Scratch: Why We Moved from... by Shorel on Friday February 10, 2023 @12:29PM (#34742783)
The part about the Rust evangelists being really toxic mirrors my own experience.

I like the language. I really don't want to deal with their community.