Linked by R_T_F_M on Thu 13th Sep 2012 21:19 UTC
Thread beginning with comment 535065
To view parent comment, click here.
To read all comments associated with this story, please click here.
To view parent comment, click here.
To read all comments associated with this story, please click here.





Member since:
2007-02-18
Since Java 7 you can make use of try-with-resources, which pretty much covers the RAAI scenarios. "
You still need to make it explicit with a statement. RAII operates as soon as you acquire the resource. The benefit of C++ RAII is that it's automatic.
Blame the programmers, not the language.
I can also give examples of C++ frameworks, which rely on inheritance to death, coupled with nice touches of multiple inheritance. "
But you're the one who brought up extreme mystery action at a distance, which only exists due to programmers, not the language. You also blamed the language for abuses of templates by programmers. You can't have one standard for criticizing one language and a different standard for another.
I'm blaming the language insofar as that at least C++ templates (I much prefer Ada generics I freely admit) provide a viable alternative. Java generics are tacky add ons.
Java the LANGUAGE itself has an overreliance on inheritance, so I don't need to blame the programmers. I would always encourage programmers to write in the way the language designers intended the language to be used (which is inheritance up the yin yang for OO dominant languages), even if the language is badly designed.