Second run of snippet containing kotlin.text.MatchGroupCollection.get
call fails with NoClassDefFoundError: kotlin/text/RegexExtensionsJDK8Kt
#413
Labels
Reproduction
Execute this code twice:
First execution is OK, second one fails with
Explanation
First compilation of the snippet produces call to
kotlin.text.jdk8.RegexExtensionsJDK8Kt.get(...)
, though the second compilation produces call tokotlin.text.RegexExtensionsJDK8Kt.get(...)
. Most likely, these calls are messed up because of unusual jvm annotations on the corresponding extension:So, kotlin package directive differs from the JVM's one. It might be a case for all similar situations, not only for this specific function
Workaround
Cast
MatchGroupCollection
toMatchNamedGroupCollection
explicitly and executeget()
on the resultThe text was updated successfully, but these errors were encountered: