-
Notifications
You must be signed in to change notification settings - Fork 26.5k
fix(compiler): exclude more safe reads expression from 2way-binding #62852
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
3b62a2c
to
10b10db
Compare
This change will require a G3 cleanup, it raised valid errors. |
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.
Let's have tests for these:
(foo?.bar).baz // not null-safe and would crash at runtime, but may not report an error without `strictNullChecks`
(foo?.bar ?? bar).baz // This is safe and should be allowed
10b10db
to
38fb1a9
Compare
@JoostK, good point. Your 1st example will won't throw with the implementation currently in PR. Will look to support it. |
Priori to this fix the parser would allow safereads in accestor receievers (but the direct one). fixes angular#62837
38fb1a9
to
75929cf
Compare
This PR was merged into the repository by commit 5b25d93. The changes were merged into the following branches: main, 20.1.x |
Priori to this fix the parser would allow safereads in accestor receievers (but the direct one).
fixes #62837