File tree Expand file tree Collapse file tree 1 file changed +8
-7
lines changed Expand file tree Collapse file tree 1 file changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -138,25 +138,26 @@ object Tuples {
138138
139139 rewrite def head : Any = {
140140 erased val resTpe = Typed (_head(xs))
141- rewrite _size(xs) match {
141+ val resVal = rewrite _size(xs) match {
142142 case 1 =>
143143 val t = xs.asInstanceOf [Tuple1 [_]]
144- t._1. asInstanceOf [resTpe. Type ]
144+ t._1
145145 case 2 =>
146146 val t = xs.asInstanceOf [Tuple2 [_, _]]
147- t._1. asInstanceOf [resTpe. Type ]
147+ t._1
148148 case 3 =>
149149 val t = xs.asInstanceOf [Tuple3 [_, _, _]]
150- t._1. asInstanceOf [resTpe. Type ]
150+ t._1
151151 case 4 =>
152152 val t = xs.asInstanceOf [Tuple4 [_, _, _, _]]
153- t._1. asInstanceOf [resTpe. Type ]
153+ t._1
154154 case n if n > 4 && n <= MaxSpecialized =>
155- xs.asInstanceOf [Product ].productElement(0 ). asInstanceOf [resTpe. Type ]
155+ xs.asInstanceOf [Product ].productElement(0 )
156156 case n if n > MaxSpecialized =>
157157 val t = xs.asInstanceOf [TupleXXL ]
158- t.elems(0 ). asInstanceOf [resTpe. Type ]
158+ t.elems(0 )
159159 }
160+ resVal.asInstanceOf [resTpe.Type ]
160161 }
161162
162163 rewrite def tail : Any = {
You can’t perform that action at this time.
0 commit comments