What’s the difference between == and .equals in Scala?

You normally use ==, it routes to equals, except that it treats nulls properly. Reference equality (rarely used) is eq.

Leave a Comment