You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Infinite recursion in KotlinDetector.hasSerializableAnnotation #37127
KotlinDetector.hasSerializableAnnotation goes into infinite recursion when fed a self-referential generic type such as Guava's ImmutableEnumSet. Minimal reproducing example:
importcom.google.common.collect.Sets;
importorg.springframework.core.KotlinDetector;
importorg.springframework.core.ResolvableType;
publicclassKotlinDetectorReproducer {
enumFoo {
BAR,
BAZ, // Makes sure that `immutableEnumSet` doesn't produce a singleton set object
}
publicstaticvoidmain(String[] args) {
KotlinDetector.hasSerializableAnnotation(
ResolvableType.forInstance(Sets.immutableEnumSet(Foo.BAR, Foo.BAZ))
);
}
}
Activity
bclozel commentedon Aug 11, 2026
Superseded by #37128