Hacker News new | ask | show | jobs
by kragen 6347 days ago
You can learn a part of C++ in a week or two weeks, but really internalizing all the subtle gotchas takes longer. Static initialization order fiasco? Exception-safety without needing catch (...) { ... throw; } clauses? Why X-is-a-Y implies pointer-to-X-is-a-pointer-t-Y but not pointer-to-pointer-to-X-is-a-pointer-to-pointer-to-Y? Why do I get a long pause when I exit this scope where I destroy just one object? How do I debug a segfault? How do I debug multithreaded deadlock? When should I use a virtual base class? Etc.

You can't learn all that stuff in a week or two. And maybe you shouldn't learn it at all; for many applications there are things that will work better than C++ without so much complexity, whether that's C or Java or Python.