O'Reilly logo
  • Curtis Turner thinks this is interesting:

The assignment p.age = 3 could be replaced by p.age_=(3). When Scala encounters an assignment like x = e, it checks whether there’s any method defined like x_= and if so, it invokes the method. The assignment interpretation is interesting in Scala, and it can mean different things based on context. For example, assignment to a function application like f(args) = e is interpreted as f.update(args)


Cover of Scala in Action


This makes the language so dense! Difficult to get the hang of but I think It'll allow for declarative power.