This is a single archived entry from Stefan Tilkov’s blog. For more up-to-date content, check out my author page at INNOQ, which has more information about me and also contains a list of published talks, podcasts, and articles. Or you can check out the full archive.

Java's "new" considered harmful

Stefan Tilkov,

Interesting DDJ article on memory allocation and object instantiation in Java. One claim I believe to be incorrect:

How do other programming languages handle object creation? C++ is just like Java, as you would expect.

It’s been a while since I programmed C++ in earnest, but at least with regards to memory allocation, placement new is certainly more powerful (and complicated and error prone) than what you have available in Java.