Skip to content

fix(37287): False positive for TS2448 "use before declaration" in 3.8.3 --target esnext #37323

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

Merged
merged 1 commit into from
Mar 19, 2020

Conversation

a-tarasyuk
Copy link
Contributor

@a-tarasyuk a-tarasyuk commented Mar 10, 2020

Fixes #37287

@RyanCavanaugh RyanCavanaugh requested a review from sandersn March 10, 2020 15:24

a()
>a() : any
>a : () => any

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting that this is the result type; I guess because --strictNullChecks is off by default in tests?

Might be better to change from () => null to () => 0 just to make sure the types propagate properly (or enable --strict)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think types matter that much for this test since it's just trying to show the absence of an error.


a()
>a() : any
>a : () => any
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think types matter that much for this test since it's just trying to show the absence of an error.

@sandersn sandersn merged commit ac3dc0c into microsoft:master Mar 19, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

False positive for TS2448 "use before declaration" in 3.8.3 --target esnext
3 participants