On Saturday, 22 February 2014 at 03:41:29 UTC, Jesse Phillips
wrote:
On Saturday, 22 February 2014 at 03:03:18 UTC, Meta wrote:
This code works fine:
http://dpaste.dzfl.pl/c0b3a941d917
That is an anonymous class, that is defining and instantiating
the class, which isn't what the scala code was doing. (BTW this
feature was added because Java could do it).
Sorry, I thought you meant it doesn't allow you to create a new
object that implements a certain interface, instead of creating a
new object and then implement an interface. Looking at the Scala
example again, I see it is indeed different.