Bug Report
π Search Terms
enum is missing member, property does not exist on type
π Version & Regression Information
- 4.8.0-beta (playground)
- 4.7.4 (playground)
- 4.6.2 (locally)
- 3.3.3333 (playground)
β― Playground Link
https://www.typescriptlang.org/play?ts=4.8.0-dev.20220721#code/KYOwrgtgBAolDeAoAggGgEKoMKsQX0QBNgBjAGwEMAnYKAN2qmAC5ZFgA6AIwoC8oA9AIAKVAPYAHYFQAuATygByHr0VRCY4AGcoIMTKYAPAJZaDYkFHlSlMRRyA
π» Code
enum E {
A,B,C,
}
declare var e: E
e.baz //Property 'baz' does not exist on type 'E'
π Actual behavior
Error Property 'baz' does not exist on type 'E' is shown and the quick fix recommended is Add missing enum member 'baz' but dotting off of a value whose type is enum shouldn't be a candidate for another member to put on that enum.
π Expected behavior
quick fix is not recommended.