Microsoft/TypeScript
GitHub ã§èŠãThe parsed identifier is incomplete due to updateSourceFile.
Open
#60,773 opened on 2024幎12æ16æ¥
BugDomain: ParserHelp Wanted
Repository metrics
- Stars
- Â (48,455 stars)
- PR merge metrics
-  (å¹³åããŒãž 6d 17h) (30d ã§ 9 merged PRs)
説æ
ð Search Terms
updateSourceFile
ð Version & Regression Information
5.6.0
⯠Playground Link
No response
ð» Code
// Your code here
ð Actual behavior
class Test { testMethod() { let newLocal = "kk" let a = 123 let b = 12 } }
After the value of variable b is changed, the identifiers set of sourceFile parsed by the updateSourceFile method contains only Test, testMethod, and b. Variables a and newLocal are lost.
ð Expected behavior
the identifiers set of sourceFile contains Test, testMethod, b, a and newLocal.
Additional information about the issue
No response