r/cpp • • Jul 13 '22

Why does Linus hate C++ ?

308 Upvotes

436 comments sorted by

View all comments

8

u/top_logger Jul 13 '22

OOP, exceptions and bad design/reputation of STL.

As system software Engineer I am agree with him. At least partly. :).

4

u/elperroborrachotoo Jul 13 '22

Remembering that RDTSC is per-core and may jump backwards if your thread gets scheduled to another core: this is basically the entrance exam.

Remembering that std::vector::reserve exists: so mysterious, like, I can't even.

0

u/angelicosphosphoros Jul 13 '22

Do you remember API details and all restrictions of `valarray`, for example? STL is just too big to keep in short-term memory (and short-term memory is better to be filled by other things like hardware behaviour).

4

u/elperroborrachotoo Jul 13 '22

No, but I know where to look it up.1

Do you remember all the details of the API YOU are creating?
Do you recall the dragon book every time you hit compile? Do you look at the source of your compiler's optimizer anytime you feel "I could make that faster"?

Or are you working at a certian level of abstraction, like everyone else?

1) and I can parse "iterator" without having an episode.

→ More replies (3)