Commit e9f980e
committed
Stop using scala.runtime.function.JFunction*mc*
Instead, use the equivalent classes in the Scala 2 standard library in
scala.runtime.java8.
The only difference is that these classes are written in Scala instead
of Java, which exposed a bug in the Scala2Unpickler: we were calling
`atPhaseNoLater(picklerPhase)`, but this doesn't actually do anything in
situation where the Pickler phase is not used (for example, when using
the `QuoteCompiler`), this is fixed by introducing a new
`atPhaseBeforeTransforms` which does the right thing.
Because the `FirstTransform` phase itself might not be present, this
also required fixing `Phase#next` and `Phase#prev` to work on `NoPhase`:
the issue was that `myBase.NoPhase` failed with an NPE which we fix by
making `NoPhase` a static object instead of a member of `PhasesBase`.
Since an instace of `Phase` contains mutable state this requires making
it `@sharable` to pass our tests, this is safe since we never mutate
anything in `NoPhase` (this also matches what we do for `NoSymbol` and
`NoDenotation`).1 parent d5721f4 commit e9f980e
File tree
94 files changed
+33
-18
lines changed- compiler/src/dotty/tools
- backend/sjs
- dotc
- core
- tasty
- unpickleScala2
- transform
- library/src-non-bootstrapped/scala/runtime/function
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
94 files changed
+33
-18
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4135 | 4135 | | |
4136 | 4136 | | |
4137 | 4137 | | |
4138 | | - | |
| 4138 | + | |
4139 | 4139 | | |
4140 | 4140 | | |
4141 | 4141 | | |
| |||
4144 | 4144 | | |
4145 | 4145 | | |
4146 | 4146 | | |
4147 | | - | |
| 4147 | + | |
4148 | 4148 | | |
4149 | 4149 | | |
4150 | 4150 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
64 | | - | |
| 64 | + | |
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
| |||
79 | 79 | | |
80 | 80 | | |
81 | 81 | | |
82 | | - | |
| 82 | + | |
83 | 83 | | |
84 | 84 | | |
85 | 85 | | |
| |||
112 | 112 | | |
113 | 113 | | |
114 | 114 | | |
115 | | - | |
| 115 | + | |
116 | 116 | | |
117 | 117 | | |
118 | 118 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
76 | 76 | | |
77 | 77 | | |
78 | 78 | | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
79 | 89 | | |
80 | 90 | | |
81 | 91 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| 19 | + | |
19 | 20 | | |
20 | 21 | | |
21 | 22 | | |
22 | 23 | | |
23 | 24 | | |
24 | 25 | | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
25 | 33 | | |
26 | 34 | | |
27 | 35 | | |
28 | 36 | | |
29 | 37 | | |
30 | 38 | | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | 39 | | |
39 | 40 | | |
40 | 41 | | |
| |||
198 | 199 | | |
199 | 200 | | |
200 | 201 | | |
| 202 | + | |
201 | 203 | | |
202 | 204 | | |
203 | 205 | | |
| |||
217 | 219 | | |
218 | 220 | | |
219 | 221 | | |
| 222 | + | |
220 | 223 | | |
221 | 224 | | |
222 | 225 | | |
| |||
239 | 242 | | |
240 | 243 | | |
241 | 244 | | |
| 245 | + | |
242 | 246 | | |
243 | 247 | | |
244 | 248 | | |
| |||
385 | 389 | | |
386 | 390 | | |
387 | 391 | | |
388 | | - | |
| 392 | + | |
389 | 393 | | |
390 | 394 | | |
391 | | - | |
| 395 | + | |
392 | 396 | | |
393 | 397 | | |
394 | 398 | | |
| |||
403 | 407 | | |
404 | 408 | | |
405 | 409 | | |
| 410 | + | |
406 | 411 | | |
407 | 412 | | |
408 | 413 | | |
| |||
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
116 | 116 | | |
117 | 117 | | |
118 | 118 | | |
119 | | - | |
| 119 | + | |
120 | 120 | | |
121 | 121 | | |
122 | 122 | | |
| |||
1392 | 1392 | | |
1393 | 1393 | | |
1394 | 1394 | | |
1395 | | - | |
| 1395 | + | |
1396 | 1396 | | |
1397 | 1397 | | |
1398 | 1398 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
608 | 608 | | |
609 | 609 | | |
610 | 610 | | |
611 | | - | |
| 611 | + | |
612 | 612 | | |
613 | 613 | | |
614 | 614 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
| 28 | + | |
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| |||
0 commit comments