@@ -10,7 +10,7 @@ sealed trait Tuple extends Any {
10
10
if (stageIt) stagedToArray
11
11
else inline constValueOpt[BoundedSize [this .type ]] match {
12
12
case Some (0 ) =>
13
- $emptyArray
13
+ empty$ Array
14
14
case Some (1 ) =>
15
15
val t = asInstanceOf [Tuple1 [Object ]]
16
16
Array (t._1)
@@ -24,15 +24,15 @@ sealed trait Tuple extends Any {
24
24
val t = asInstanceOf [Tuple4 [Object , Object , Object , Object ]]
25
25
Array (t._1, t._2, t._3, t._4)
26
26
case Some (n) if n <= $MaxSpecialized =>
27
- $toArray (this , n)
27
+ to$ Array (this , n)
28
28
case Some (n) =>
29
29
asInstanceOf [TupleXXL ].elems
30
30
case None =>
31
31
dynamicToArray(this )
32
32
}
33
33
34
34
inline def stagedToArray : Array [Object ] =
35
- ~ StagedTuple .toArrayStaged('( this) , constValueOpt[BoundedSize[this.type]])
35
+ $ { StagedTuple .toArrayStaged(' { this } , constValueOpt[BoundedSize [this .type ]]) }
36
36
37
37
inline def *: [H ] (x : H ): H *: this .type =
38
38
if (stageIt) stagedCons[H ](x)
@@ -53,14 +53,14 @@ sealed trait Tuple extends Any {
53
53
val t = asInstanceOf [Tuple4 [_, _, _, _]]
54
54
Tuple5 (x, t._1, t._2, t._3, t._4).asInstanceOf [Result ]
55
55
case Some (n) =>
56
- fromArray[Result ]($consArray (x, toArray))
56
+ fromArray[Result ](cons$ Array (x, toArray))
57
57
case _ =>
58
58
dynamic_*: [this .type , H ](this , x)
59
59
}
60
60
}
61
61
62
62
inline def stagedCons [H ] (x : H ): H *: this .type =
63
- ~ StagedTuple .stagedCons('( this) , ' (x) , constValueOpt[BoundedSize [this .type ]])
63
+ $ { StagedTuple .stagedCons(' { this } , ' {x} , constValueOpt[BoundedSize [this .type ]]) }
64
64
65
65
inline def ++ (that : Tuple ): Concat [this .type , that.type ] =
66
66
if (stageIt) stagedConcat(that)
@@ -104,8 +104,8 @@ sealed trait Tuple extends Any {
104
104
}
105
105
106
106
inline def stagedConcat (that : Tuple ): Concat [this .type , that.type ] =
107
- ~ StagedTuple .stagedConcat('( this) , constValueOpt[BoundedSize[this.type]],
108
- ' ( that) , constValueOpt[BoundedSize[that.type]])
107
+ $ { StagedTuple .stagedConcat(' { this } , constValueOpt[BoundedSize [this .type ]],
108
+ ' { that} , constValueOpt[BoundedSize [that.type ]]) }
109
109
110
110
inline def genericConcat [T <: Tuple ](xs : Tuple , ys : Tuple ): Tuple =
111
111
fromArray[T ](xs.toArray ++ ys.toArray)
@@ -121,7 +121,7 @@ sealed trait Tuple extends Any {
121
121
}
122
122
123
123
inline def stagedSize : Size [this .type ] =
124
- ~ StagedTuple .sizeStaged[Size [this .type ]]('( this) , constValueOpt[BoundedSize[this.type]])
124
+ $ { StagedTuple .sizeStaged[Size [this .type ]](' { this } , constValueOpt[BoundedSize [this .type ]]) }
125
125
}
126
126
127
127
object Tuple {
@@ -167,9 +167,9 @@ object Tuple {
167
167
168
168
private [scala] type BoundedSize [X ] = BoundedSizeRecur [X , 23 ]
169
169
170
- val $emptyArray = Array [Object ]()
170
+ val empty$Array = Array [Object ]()
171
171
172
- def $toArray (xs : Tuple , n : Int ) = {
172
+ def to$Array (xs : Tuple , n : Int ) = {
173
173
val arr = new Array [Object ](n)
174
174
var i = 0
175
175
var it = xs.asInstanceOf [Product ].productIterator
@@ -180,7 +180,7 @@ object Tuple {
180
180
arr
181
181
}
182
182
183
- def $consArray [H ](x : H , elems : Array [Object ]): Array [Object ] = {
183
+ def cons$Array [H ](x : H , elems : Array [Object ]): Array [Object ] = {
184
184
val elems1 = new Array [Object ](elems.length + 1 )
185
185
elems1(0 ) = x.asInstanceOf [Object ]
186
186
System .arraycopy(elems, 0 , elems1, 1 , elems.length)
@@ -217,7 +217,7 @@ object Tuple {
217
217
}
218
218
219
219
inline def stagedFromArray [T <: Tuple ](xs : Array [Object ]): T =
220
- ~ StagedTuple .fromArrayStaged[T ]('(xs) , constValueOpt[BoundedSize[this.type]])
220
+ $ { StagedTuple .fromArrayStaged[T ](' {xs} , constValueOpt[BoundedSize [this .type ]]) }
221
221
222
222
def dynamicFromArray [T <: Tuple ](xs : Array [Object ]): T = xs.length match {
223
223
case 0 => ().asInstanceOf [T ]
@@ -248,7 +248,7 @@ object Tuple {
248
248
249
249
def dynamicToArray (self : Tuple ): Array [Object ] = (self : Any ) match {
250
250
case self : Unit =>
251
- $emptyArray
251
+ empty$ Array
252
252
case self : Tuple1 [_] =>
253
253
val t = self.asInstanceOf [Tuple1 [Object ]]
254
254
Array (t._1)
@@ -283,7 +283,7 @@ object Tuple {
283
283
case self : Tuple4 [_, _, _, _] =>
284
284
Tuple5 (x, self._1, self._2, self._3, self._4).asInstanceOf [Result ]
285
285
case _ =>
286
- dynamicFromArray[Result ]($consArray (x, dynamicToArray(self)))
286
+ dynamicFromArray[Result ](cons$ Array (x, dynamicToArray(self)))
287
287
}
288
288
}
289
289
@@ -340,7 +340,7 @@ sealed trait NonEmptyTuple extends Tuple {
340
340
}
341
341
342
342
inline def stagedHead : Head [this .type ] =
343
- ~ StagedTuple .headStaged[this .type ]('( this) , constValueOpt[BoundedSize[this.type]])
343
+ $ { StagedTuple .headStaged[this .type ](' { this } , constValueOpt[BoundedSize [this .type ]]) }
344
344
345
345
inline def tail : Tail [this .type ] =
346
346
if (stageIt) stagedTail
@@ -369,7 +369,7 @@ sealed trait NonEmptyTuple extends Tuple {
369
369
}
370
370
371
371
inline def stagedTail : Tail [this .type ] =
372
- ~ StagedTuple .tailStaged[this .type ]('( this) , constValueOpt[BoundedSize[this.type]])
372
+ $ { StagedTuple .tailStaged[this .type ](' { this } , constValueOpt[BoundedSize [this .type ]]) }
373
373
374
374
inline def fallbackApply (n : Int ) =
375
375
inline constValueOpt[n.type ] match {
@@ -429,9 +429,9 @@ sealed trait NonEmptyTuple extends Tuple {
429
429
}
430
430
431
431
inline def stagedApply (n : Int ): Elem [this .type , n.type ] =
432
- ~ StagedTuple .applyStaged[this .type , n.type ](
433
- ' ( this) , constValueOpt[Size[this.type]],
434
- ' (n) , constValueOpt[n.type])
432
+ $ { StagedTuple .applyStaged[this .type , n.type ](
433
+ ' { this } , constValueOpt[Size [this .type ]],
434
+ ' {n} , constValueOpt[n.type ]) }
435
435
}
436
436
437
437
object NonEmptyTuple {
0 commit comments