-
Notifications
You must be signed in to change notification settings - Fork 3
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
Detect awaited rhs values in top level declarations #6
Conversation
Update list of nodejs versions for CI tests
I’ve never written code for Babel visitors before so feel free to suggest improvements. |
This looks good for the specific issue you found. However, it seems this is a much more general issue - there's many other situations where it misses top level await. A couple examples are:
What I think we need to do is have Another option might be to have the visitor visit each of the function nodes, and track if we are inside a function or not to avoid walking up the parents. I'm not sure if this is more efficient, but it seems it could be significantly faster. |
@zodern Yes that thought occurred to me too but would you mind approving this PR as a step in the right direction? |
ping @zodern pls approve for this incremental improvement that should cover a lot of typical usages of TLA |
It looks good to me. I'll leave it up to Meteor if they want to temporarily use this before fully fixing the issue. |
This PR should cover this one and also cover a wider range of cases |
Brilliant! |
Now detects TLA for:
Includes changes in #5