Skip to content

Resolve Kotlin suspend bridge methods - #37138

Open
erishforG wants to merge 1 commit into
spring-projects:mainfrom
erishforG:fix/kotlin-suspend-bridge-resolution
Open

Resolve Kotlin suspend bridge methods#37138
erishforG wants to merge 1 commit into
spring-projects:mainfrom
erishforG:fix/kotlin-suspend-bridge-resolution

Conversation

@erishforG

Copy link
Copy Markdown

Resolve BridgeMethodResolver candidate selection for multi-level generic Kotlin suspend overrides.

When both methods use the Kotlin suspend ABI, compare their logical Kotlin return types. All other methods retain the existing JVM return-type check, preserving covariant-return disambiguation.

Add regression coverage for both specialized and root bridges in a multi-level generic suspend hierarchy.

Tests:

  • ./gradlew :spring-core:test --tests org.springframework.core.BridgeMethodResolverKotlinTests --rerun-tasks --no-daemon
  • ./gradlew :spring-core:check --no-daemon

Closes gh-37125

Compare logical return types for Kotlin suspending functions when
matching candidates in multi-level generic hierarchies.

Keep the existing JVM return type check for all other methods.

Closes spring-projectsgh-37125

Signed-off-by: erishforG <erish2150@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

status: waiting-for-triage An issue we've not yet triaged or decided on

Projects

None yet

Development

Successfully merging this pull request may close these issues.

BridgeMethodResolver does not resolve bridge methods for multi-level generic Kotlin suspend overrides

2 participants