martin odersky | 28 Dec 22:31
Picon
Picon
Favicon

Re: Scala Object Notation ( SCON? )

>
> class Person{
>  String name;
>  Integer age;
> }
>
> p = new Person(name: "Andres", age: 29)
>
> A pretty feature to add to Scala.

I (still) don't understand. The above feature already works one by one in Scala:

  class Person {
     var name: String = _
     var age: Int = _
   }
   val p = new Person{ name = "Andres", age = 29 }

Cheers

-- Martin


Gmane