Skip to content
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

fix(ivy): avoid implicit any errors in event handlers #33550

Closed
wants to merge 1 commit into from

Conversation

JoostK
Copy link
Member

@JoostK JoostK commented Nov 2, 2019

When template type checking is configured with strictDomEventTypes or
strictOutputEventTypes disabled, in compilation units that have
noImplicitAny enabled but strictNullChecks disabled, a template type
checking error could be produced for certain event handlers.

The error is avoided by letting an event handler in the generated TCB
always have an explicit any return type.

Fixes #33528

@JoostK JoostK added type: bug/fix action: review The PR is still awaiting reviews from at least one requested reviewer effort1: hours workaround1: obvious freq1: low severity2: inconvenient target: patch This PR is targeted for the next patch release area: compiler Issues related to `ngc`, Angular's template compiler labels Nov 2, 2019
@ngbot ngbot bot modified the milestone: needsTriage Nov 2, 2019
When template type checking is configured with `strictDomEventTypes` or
`strictOutputEventTypes` disabled, in compilation units that have
`noImplicitAny` enabled but `strictNullChecks` disabled, a template type
checking error could be produced for certain event handlers.

The error is avoided by letting an event handler in the generated TCB
always have an explicit `any` return type.

Fixes angular#33528
@JoostK JoostK marked this pull request as ready for review November 3, 2019 11:14
@JoostK JoostK requested a review from a team as a code owner November 3, 2019 11:14
@alxhub
Copy link
Member

alxhub commented Nov 6, 2019

Presubmit
No Ivy presubmit needed - template type-checking is disabled there, and this change only reduces errors anyway.

@alxhub alxhub added action: merge The PR is ready for merge by the caretaker and removed action: review The PR is still awaiting reviews from at least one requested reviewer labels Nov 6, 2019
@atscott atscott closed this in e2d7b25 Nov 6, 2019
atscott pushed a commit that referenced this pull request Nov 6, 2019
When template type checking is configured with `strictDomEventTypes` or
`strictOutputEventTypes` disabled, in compilation units that have
`noImplicitAny` enabled but `strictNullChecks` disabled, a template type
checking error could be produced for certain event handlers.

The error is avoided by letting an event handler in the generated TCB
always have an explicit `any` return type.

Fixes #33528

PR Close #33550
mohaxspb pushed a commit to mohaxspb/angular that referenced this pull request Nov 7, 2019
When template type checking is configured with `strictDomEventTypes` or
`strictOutputEventTypes` disabled, in compilation units that have
`noImplicitAny` enabled but `strictNullChecks` disabled, a template type
checking error could be produced for certain event handlers.

The error is avoided by letting an event handler in the generated TCB
always have an explicit `any` return type.

Fixes angular#33528

PR Close angular#33550
mohaxspb pushed a commit to mohaxspb/angular that referenced this pull request Nov 7, 2019
When template type checking is configured with `strictDomEventTypes` or
`strictOutputEventTypes` disabled, in compilation units that have
`noImplicitAny` enabled but `strictNullChecks` disabled, a template type
checking error could be produced for certain event handlers.

The error is avoided by letting an event handler in the generated TCB
always have an explicit `any` return type.

Fixes angular#33528

PR Close angular#33550
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Dec 7, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
action: merge The PR is ready for merge by the caretaker area: compiler Issues related to `ngc`, Angular's template compiler cla: yes effort1: hours freq1: low target: patch This PR is targeted for the next patch release type: bug/fix workaround1: obvious
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Ivy: fullTemplateTypeCheck errors with noImplicitAny and null in function expressions
3 participants