Hacker News new | past | comments | ask | show | jobs | submit login

You came back.

C++ is hard to appreciate without a good amount of programming experience.

A general pattern I am seeing is that programmers learn C++ as their first language, move to Java, Python, etc.. gain some experience and then they come back to C++ and say you know what, C++ is not that bad after all. But they don't come to this conclusion because C++ changed, but because they learnt to appreciate its usefulness.

After all, use the right tool for the job.




There is a silver bullet that would make C++ very competitive for most of the web/db centric apps:

It is Reflection/introspection capability built into the language.

Without it -- it is impossible to do DB structures to C++ structure mappings, or UI fields to C++ structures mapping.

There are of course work arounds (QT's macros, pre-compilers, etc).

Every time I approached this topic with some in C++ community, the answer always was ' C++ philosophy is -- if you do not use a feature of a language you will not pay a performance penality for it'.

Reflection, obvsiosly adds performance penalty. When I suggest that it should be a compiler switch (like RTTI) -- the reply I get -- is that reflection cannot be turned on/off on per compilation unit., and instead must be on per project level. But C++ standard does not define 'project level' compilation option -- therefore, not acceptable.

That's pretty much where this discussion gets stuck


Indeed reflection is limited.

There's a library called Reflex: http://root.cern.ch/drupal/content/reflex

SOCI uses generic template accessors to read/write full objects: http://soci.sourceforge.net/doc/exchange.html#object_relatio...


I learned some C++ as one of my first languages ever, about a decade ago. Since, I've used Python, Java, and JavaScript professionally. In my spare time: Go, Ruby, Haskell, and Clojure.

After changing teams about a year ago, I came back to C++. IMHO, C++ is the worst. By far. Without question. It's so bad I don't know what to rank as second-worst. Every new feature or quirk is tinged with horror. The latest example for me was: http://isocpp.org/blog/2012/11/universal-references-in-c11-s.... So was that HN piece about C++ pitfalls.

No, for me, it is the diametric opposite. The more I learn about anything other than C++, the more C++ seems like a big, creaking pile of leaky abstractions. It's like if you took the worst aspects of C and Java. And I struggle — earnestly — to imagine how people could actually be OK with it, let alone enjoy it.

But I have to use it at work. It's an industry-standard language. Some people like it. That's life.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: