File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
src/compiler/scala/tools/nsc/transform/patmat Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -17,8 +17,8 @@ trait Logic extends Debugging {
17
17
import PatternMatchingStats ._
18
18
19
19
private def max (xs : Seq [Int ]) = if (xs isEmpty) 0 else xs max
20
- private def alignedColumns (cols : Seq [AnyRef ]): Seq [String ] = {
21
- def toString (x : AnyRef ) = if (x eq null ) " " else x.toString
20
+ private def alignedColumns (cols : Seq [Any ]): Seq [String ] = {
21
+ def toString (x : Any ) = if (x == null ) " " else x.toString
22
22
if (cols.isEmpty || cols.tails.isEmpty) cols map toString
23
23
else {
24
24
val colLens = cols map (c => toString(c).length)
@@ -33,7 +33,7 @@ trait Logic extends Debugging {
33
33
}
34
34
}
35
35
36
- def alignAcrossRows (xss : List [List [AnyRef ]], sep : String , lineSep : String = " \n " ): String = {
36
+ def alignAcrossRows (xss : List [List [Any ]], sep : String , lineSep : String = " \n " ): String = {
37
37
val maxLen = max(xss map (_.length))
38
38
val padded = xss map (xs => xs ++ List .fill(maxLen - xs.length)(null ))
39
39
padded.transpose.map(alignedColumns).transpose map (_.mkString(sep)) mkString(lineSep)
You can’t perform that action at this time.
0 commit comments