@@ -613,7 +613,7 @@ res4: Capped2[Int] = Capped2(2, 3, 4, 5)
613613This implementation now behaves correctly, but we can still improve
614614a few things. Since our collection is strict, we can take advantage
615615of the better performance offered by
616- of strict implementations for transformation operations.
616+ strict implementations of transformation operations.
617617
618618### Final version of ` Capped ` class ###
619619
@@ -1077,7 +1077,7 @@ The final [`RNA` class](#final-version-of-rna-strands-class):
10771077 operations to take advantage of strict builders,
10781078- uses a strict mode for overloads of transformation operations that return
10791079 an ` RNA ` ,
1080- - has a companion object that extends ` SpecificFactory [Base, RNA]` , which makes
1080+ - has a companion object that extends ` SpecificIterableFactory [Base, RNA]` , which makes
10811081 it possible to use it as a parameter of a ` to ` call (to convert any collection
10821082 of bases to an ` RNA ` ),
10831083- moves the ` newSpecificBuilder ` and ` fromSpecificIterable ` implementations
@@ -1159,8 +1159,8 @@ class PrefixMap[A]
11591159 with mutable.MapOps [String , A , mutable.Map , PrefixMap [A ]]
11601160 with StrictOptimizedIterableOps [(String , A ), mutable.Iterable , PrefixMap [A ]] {
11611161
1162- var suffixes : immutable.Map [Char , PrefixMap [A ]] = immutable.Map .empty
1163- var value : Option [A ] = None
1162+ private var suffixes : immutable.Map [Char , PrefixMap [A ]] = immutable.Map .empty
1163+ private var value : Option [A ] = None
11641164
11651165 def get (s : String ): Option [A ] =
11661166 if (s.isEmpty) value
@@ -1369,13 +1369,13 @@ publication.
13691369
13701370## Appendix: Methods to overload to support the “same result type” principle ##
13711371
1372- You want to add overloads to specialize a transformation operations such that they return a more specific result. Examples are:
1372+ You want to add overloads to specialize transformation operations such that they return a more specific result type . Examples are:
13731373- ` map ` , on ` StringOps ` , when the mapping function returns a ` Char ` , should return a ` String ` (instead of an ` IndexedSeq ` ),
13741374- ` map ` , on ` Map ` , when the mapping function returns a pair, should return a ` Map ` (instead of an ` Iterable ` ),
13751375- ` map ` , on ` SortedSet ` , when an implicit ` Ordering ` is available for the resulting element type, should return a
13761376` SortedSet ` (instead of a ` Set ` ).
13771377
1378- The following table lists transformation operations that might return a too wide type. You might want to overload
1378+ The following table lists transformation operations that might return an undesirably wide type. You might want to overload
13791379these operations to return a more specific type.
13801380
13811381 Collection | Operations
0 commit comments