File tree Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,8 @@ import annotation.tailrec
12
12
* strengths and weaknesses of different collection architectures.
13
13
*
14
14
* For a test file, see tests/run/CollectionTests.scala.
15
+ *
16
+ * Strawman4 is like strawman1, but built over views instead of by-name iterators
15
17
*/
16
18
object CollectionStrawMan4 {
17
19
Original file line number Diff line number Diff line change @@ -12,6 +12,15 @@ import annotation.tailrec
12
12
* strengths and weaknesses of different collection architectures.
13
13
*
14
14
* For a test file, see tests/run/CollectionTests.scala.
15
+ *
16
+ * Strawman5 is like strawman4, but using inheritance through ...Like traits
17
+ * instead of decorators.
18
+ *
19
+ * Advantage: Much easier to specialize. See partition for strict (buildable) collections
20
+ * or drop for Lists.
21
+ *
22
+ * Disadvantage: More "weird" types in base traits; some awkwardness with
23
+ * @uncheckedVariance.
15
24
*/
16
25
object CollectionStrawMan5 {
17
26
You can’t perform that action at this time.
0 commit comments