Skip to content

Support variable resolution of wildcard types#24145

Merged
jhoeller merged 1 commit into
spring-projects:masterfrom
philwebb:resolvewildcards
Dec 6, 2019
Merged

Support variable resolution of wildcard types#24145
jhoeller merged 1 commit into
spring-projects:masterfrom
philwebb:resolvewildcards

Conversation

@philwebb

@philwebb philwebb commented Dec 5, 2019

Copy link
Copy Markdown
Member

Update ResolvableType so that variable referenced can be resolved
against wildcard types. Prior to this commit, given a type:

Map<String, ? extends List<? extends CharSequence>>

Calling type.getGeneric(1).asCollection().resolveGeneric() would
return null. This was because the List variable E referenced a
wildcard type which resolveVariable did not support.

Update `ResolvableType` so that variable referenced can be resolved
against wildcard types. Prior to this commit, given a type:

	Map<String, ? extends List<? extends CharSequence>>

Calling `type.getGeneric(1).asCollection().resolveGeneric()` would
return `null`. This was because the `List` variable `E` referenced a
wildcard type which `resolveVariable` did not support.

Closes spring-projectsgh-24145
@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged or decided on label Dec 5, 2019
@jhoeller jhoeller self-assigned this Dec 6, 2019
@jhoeller jhoeller added in: core Issues in core modules (aop, beans, core, context, expression) type: enhancement A general enhancement and removed status: waiting-for-triage An issue we've not yet triaged or decided on labels Dec 6, 2019
@jhoeller jhoeller added this to the 5.2.3 milestone Dec 6, 2019
@jhoeller jhoeller merged commit 7c84695 into spring-projects:master Dec 6, 2019
@spring-projects-issues spring-projects-issues added status: backported An issue that has been backported to maintenance branches and removed for: backport-to-5.1.x labels Dec 6, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

in: core Issues in core modules (aop, beans, core, context, expression) status: backported An issue that has been backported to maintenance branches type: enhancement A general enhancement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants