Hacker News new | ask | show | jobs
by pjc50 1023 days ago
> I'm curious if somebody is working on a flavor of the modern C++ that abandons backward compatibility ?

This is just Rust. You can't really deprecate bare pointers in C++ without completely wrecking the language.

1 comments

This... seems false? In particular, the point of an "edition" system is that code written for the new edition can seamlessly import code written for the old edition, and so a hypothetical pointerless "new edition" would simply disallow bare pointers in new files, and things like smart pointers would continue to be _implemented_ in old edition code.
Bringing editions to C++ failed, and I am not aware of anyone trying to tackle the issues https://github.com/cplusplus/papers/issues/631

(I could be wrong though! I follow the committee more than you may guess, but not as much as to think I know everything about what's going on.)

> would simply disallow bare pointers in new files

And all their header files. That's a real Year Zero moment: you've just cut yourself off from the standard library, as well as most of the code you might want to link to. I don't think there's any "simpler" about it.