Hacker News new | ask | show | jobs
by abcd_f 16 days ago
> I would consider it beautiful.

If there's something that C++ actually lacks, that's the elegance, grace and beauty. The rest, it's all already there or will be there shortly :)

3 comments

Think of it like a rainforest ecosystem. Very complex and tangled, even fragile. But it’s the tangled fragile complexity that makes it interesting.
I find C++ beautiful only when I come across simple, powerful things that use the minimal amount of advanced language features possible
The problem with that is best described by Antoine de Sain-Exupery's saying "perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away." I guess the same goes for elegance and grace...
C++ is in the transitional phase where major bad things are being taken away very satisfactorily, usually by providing a simpler and more general replacement (for example, auto instead of long and pointless type declarations or modern initialization protecting against implicit conversions and surprise constructor overloads), but most progress of elegance and grace come from new features that enable something traditionally terrible or impossible (for example the gradual generalization of templates, culminating with concepts, the gradual extension of constexpr, consteval etc, and the new reflection).
Oh, have they finally started to remove features?
Yes, several even, C++98 or C++11 code will not compile in C++26 mode, depending if some of those feature were being used.

Exception specifications, auto_ptr, C++11 GC, the way volatile works, uninitialised variables,...

That's the thing though isn't it. C++ didn't add type erasure to the language, it added compile time reflection and said have at it.