-
Notifications
You must be signed in to change notification settings - Fork 10.3k
Add support for BindAsync without ParameterInfo #36505
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Co-authored-by: David Fowler <[email protected]>
@@ -128,12 +131,18 @@ public bool HasTryParseMethod(ParameterInfo parameter) | |||
return _stringMethodCallCache.GetOrAdd(type, Finder); | |||
} | |||
|
|||
public Expression? FindBindAsyncMethod(ParameterInfo parameter) | |||
public (Expression?, int) FindBindAsyncMethod(ParameterInfo parameter) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
public (Expression?, int) FindBindAsyncMethod(ParameterInfo parameter) | |
public (Expression? Expression, int ParamCount) FindBindAsyncMethod(ParameterInfo parameter) |
Would this be better @davidfowl ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think this changed much but it's fine
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice test coverage!
/backport to release/6.0 |
Started backporting to release/6.0: https://github.com/dotnet/aspnetcore/actions/runs/1239549193 |
Fixes #36415
Prefers
BindAsync(HttpContext, ParameterInfo)
overBindAsync(HttpContext)
.