-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Missed nullness pattern in migration #44217
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
Comments
Likely missed that because we don't do promotion of instance variables. It's not safe to assume that Not saying that migration tools can't assume that the code is reasonable, though. It might make sense for the migration tool to assume that checks do promote field, and so |
cc/ @stereotype441 |
Agreed. This is one of the prinicpal improvements discussed in #40566. Glad to hear I'm not the only one who thinks this would be beneficial. |
Duplicate of #40566 |
When the migration tries to migrate code like
it proposes
that is, failing to see that the cast must be to a non-nullable type.
The text was updated successfully, but these errors were encountered: