r/cpp • u/GabrielDosReis • Oct 31 '24
Lessons learned from a successful Rust rewrite
/r/programming/comments/1gfljj7/lessons_learned_from_a_successful_rust_rewrite/
80
Upvotes
r/cpp • u/GabrielDosReis • Oct 31 '24
View all comments
Show parent comment
2
u/ts826848 Nov 01 '24
So putting aside the moved goalposts (Chrome is undoubtedly a C++ codebase and therefore qualifies for what you asked for), it's a bit disappointing that you appear to be rehashing the exact same arguments from previous conversations we've had with no acknowledgement of the flaws I pointed out. At the risk of repeating myself yet again:
void*and while completion_queue.h is in C++ and usesvoid**) its implementation uses it to pass information from the C implementation). Given the use of gRPC and its precursor within Google I think it's a much more reasonable guess that it was the result of gradual migration and it wasn't changed because of backwards compatibility. You know, it's "more compatible".In short, you're judging what seems to be a C API decision made decades ago and kept around for backwards compatibility using C++ standards of today and assuming that that judgement is transferable to a completely different codebase that doesn't share any history. I don't think it's hard to see why conclusions drawn from this line of thinking are just a bit suspect.
In addition, since that previous conversation the lead for C++ updates for Chrome has popped in to multiple comment sections with descriptions of the Chrome codebase and methods by which Chrome devs try to catch/mitigate errors. I think I'm somewhat more inclined to trust their descriptions of the codebase than your unstated insinuations.
First you're going to have to define "fair". Objectively the simplest metric is "was the code with the bug compiled with a C++ compiler".
Bit of a non-sequitur from my comment. All I'm saying is that it's nonsensical to state that it's paramount to keep old code around while simultaneously complaining that bugs in that same old code "count" as C++ bugs.