-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
fix(typescript-estree): persisted parse and module none #1516
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
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
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.
I just assumed we always needed to set the parent pointers.
The thing I hate is that this method has side-effects, and we can't just call a method to set parent pointers.
cc @uniqueiniquity for "when we need to call it"
packages/typescript-estree/src/create-program/createWatchProgram.ts
Outdated
Show resolved
Hide resolved
packages/typescript-estree/src/create-program/createWatchProgram.ts
Outdated
Show resolved
Hide resolved
Typescript actually calls this function to "fix" parent nodes.
|
i'm tempted to remove calls to parent node from converter as we are already traversing nodes, currently in all other parsing modes we are setting up Update: |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Codecov Report
@@ Coverage Diff @@
## master #1516 +/- ##
==========================================
+ Coverage 95.42% 95.42% +<.01%
==========================================
Files 140 140
Lines 6400 6401 +1
Branches 1832 1832
==========================================
+ Hits 6107 6108 +1
Misses 108 108
Partials 185 185
|
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.
LGTM - thanks for fixing this
This PR fixes issue when persisted parse is called with module option set to "none",
fixes #1502