Why do Scala immutable HashMap methods return a Map?

Posted by pau.estalella on Stack Overflow See other posts from Stack Overflow or by pau.estalella
Published on 2010-04-11T20:14:46Z Indexed on 2010/04/11 20:33 UTC
Read the original article Hit count: 178

Filed under:
|
|

Hi all!

I am having problems using the update method of scala.collection.immutable.HashMap.I don't see the reason it returns a Map instead of a HashMap. How do I get a new HashMap with a new key-value pair added?

© Stack Overflow or respective owner

Related posts about scala

Related posts about immutable