File tree Expand file tree Collapse file tree 2 files changed +10
-3
lines changed
internal/zinc-classpath/src/main/scala/sbt/internal/inc Expand file tree Collapse file tree 2 files changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -29,6 +29,9 @@ def mimaSettings: Seq[Setting[?]] = Seq(
29
29
" 1.5.0" ,
30
30
" 1.6.0" ,
31
31
" 1.7.0" ,
32
+ " 1.8.0" ,
33
+ " 1.9.0" ,
34
+ " 1.10.0" ,
32
35
)
33
36
val versions =
34
37
if (scalaVersion.value.startsWith(" 2.12." )) pre140 ++ post140
@@ -641,6 +644,9 @@ lazy val zincClasspath = (projectMatrix in internalPath / "zinc-classpath")
641
644
exclude[IncompatibleResultTypeProblem ](
642
645
" sbt.internal.inc.classpath.NativeCopyConfig.*"
643
646
),
647
+ exclude[IncompatibleResultTypeProblem ](
648
+ " sbt.internal.inc.ReflectUtilities.fields"
649
+ ),
644
650
exclude[IncompatibleSignatureProblem ](
645
651
" sbt.internal.inc.classpath.NativeCopyConfig.*"
646
652
),
Original file line number Diff line number Diff line change @@ -13,6 +13,7 @@ package sbt
13
13
package internal
14
14
package inc
15
15
16
+ import java .lang .reflect .Field
16
17
import scala .collection ._
17
18
18
19
object ReflectUtilities {
@@ -33,10 +34,10 @@ object ReflectUtilities {
33
34
34
35
def ancestry (clazz : Class [? ]): List [Class [? ]] =
35
36
if (clazz == classOf [AnyRef ] || ! classOf [AnyRef ].isAssignableFrom(clazz)) List (clazz)
36
- else clazz :: ancestry(clazz.getSuperclass);
37
+ else clazz :: ancestry(clazz.getSuperclass)
37
38
38
- def fields (clazz : Class [? ]) =
39
- mutable.OpenHashMap (ancestry(clazz).flatMap(_.getDeclaredFields).map(f => (f.getName, f)): _* )
39
+ def fields (clazz : Class [? ]): mutable. Map [ String , Field ] =
40
+ mutable.AnyRefMap (ancestry(clazz).flatMap(_.getDeclaredFields).map(f => (f.getName, f)): _* )
40
41
41
42
/**
42
43
* Collects all `val`s of type `T` defined on value `self`.
You can’t perform that action at this time.
0 commit comments