Skip to content

fix(Context)!: correct signature of Context.get#5017

Merged
jdrueckert merged 4 commits intodevelopfrom
feat/contextGetValue
May 22, 2022
Merged

fix(Context)!: correct signature of Context.get#5017
jdrueckert merged 4 commits intodevelopfrom
feat/contextGetValue

Conversation

@keturn
Copy link
Member

@keturn keturn commented May 18, 2022

T get(Class<? extends T> type) would mean that type could be a subclass of the return value.
e.g. returning a Number when asked for a Float.

That's the opposite of what we wanted!

Might break binary compatibility and trigger a lot of recompiling. I don't expect it to break source compatibility with any current code.

Also:
feat(Context): add non-null and Optional get methods

keturn added 2 commits May 18, 2022 12:45
T get(Class<? extends T> type) would mean that `type` could be a subclass of the return value.
e.g. returning a Number when asked for a Float.

That's the opposite of what we wanted!
@keturn keturn added the Size: S Small effort likely only affecting a single area and requiring little to no research label May 18, 2022
@github-actions github-actions bot added the Type: Bug Issues reporting and PRs fixing problems label May 18, 2022
Object is automatically the lower bound of `?`
@jdrueckert jdrueckert changed the title fix(Context)! correct signature of Context.get fix(Context)!: correct signature of Context.get May 22, 2022
@jdrueckert jdrueckert merged commit 22bf4a4 into develop May 22, 2022
@jdrueckert jdrueckert deleted the feat/contextGetValue branch May 22, 2022 21:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Size: S Small effort likely only affecting a single area and requiring little to no research Type: Bug Issues reporting and PRs fixing problems

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants