scala-best-practices icon indicating copy to clipboard operation
scala-best-practices copied to clipboard

Avoid List (or any other LinearSeq) for indexed accesses

Open mpasa opened this issue 6 years ago • 2 comments

A lot of people new to Scala tend to use List as the Java's interface, without knowing that is a Linked List. Maybe we can add a new section for data structures/collections?

mpasa avatar Jan 02 '19 08:01 mpasa

Interesting thought. I like the idea of a section on data structures and collections - and actually started off with one - but with the collection redesign looming close, I'm worried that it'll be obsolete before it's even released :)

If you have suggestions for other things that should go in the collections section, please post them! Enough of them (that I can confirm still apply in 2.13) and I'll get to it.

nrinaudo avatar Jan 02 '19 09:01 nrinaudo

Yes, maybe it's better to wait for 2.13 with the new collections. RC1 is due by January 30, so I don't think we will have to wait a lot.

mpasa avatar Jan 02 '19 10:01 mpasa