Why do all Scala classes inherit from ScalaObject
although that trait is completely empty and has no (visible?) functionality compared to AnyRef
, which does define additional methods?
Won't that slow down method calls like equals()
or hashCode()
because it will need to take another class into consideration (which might override the methods)?
Isn't it possible to fold AnyRef and ScalaObject into one class?