Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Maybe "feels like" is too subjective but it absolutely feels like Java to me:

* Object-oriented with inheritance (sharing the same keywords such as 'class' and 'extends'

* Non-optional semicolons

* Constructors, method overriding, calling `super.whatever` in your overriden methods

* Presence of null

* A base Object class for all objects in Dart, with hashCode() toString() methods

These are mostly superficial observations, and it's not a criticism of the language, but it certainly feels like Java to me, more than Scala or Go does.



True, there are many similarities. But it seems to me that the author of this article makes Dart appear even more like Java by ignoring Dart features and idioms.

For instance, what's the point of those Java style getter methods in the Movie class? These are public instance variables after all, and Dart has special property syntax to transparently wrap instance variables if and when the need arises.

I know next to nothing about Dart. So maybe there is a reason for this weirdness. But I rather suspect that the author has written a lot of Java and almost no Dart in his life.


* @Override annotation instead of a proper keyword

One of my pet peeves with Java.




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

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

Search: