register import equals specifier#10710
Conversation
Note that you can mark them as "co-author" of the commit |
Co-authored-by: <jaejoon.choi>
|
Rebased |
| node.id = this.parseIdentifier(); | ||
| this.checkLVal( | ||
| node.id, | ||
| BIND_LEXICAL, |
There was a problem hiding this comment.
I'm not sure about which kind of binding this should be: https://www.typescriptlang.org/play/?esModuleInterop=false&target=99&module=1&ssl=3&ssc=17&pln=4&pc=17#code/JYWwDg9gTgLgBAQzgXjlApgRwK7AwCgCIFCBKAbgChKYBPMdRFOAO2xACN0oqAbdeAgBcrdlyjMATFUroAHpFhwA3kwC+5IA
There was a problem hiding this comment.
The binding type should be as same as import default specifier: https://www.typescriptlang.org/play/?esModuleInterop=false&target=99&module=1&ssl=1&ssc=1&pln=3&pc=1#code/JYWwDg9gTgLgBAQzgXjlApgRwK7AwCgCIYBPMdAZwGMpgwZCBKAbgChXTzEU4A7bEACN0UNgBt08BAC4+A4VB4AmNq3QAPSLDgBvbgF9mQA
The declaration conflict error is shadowed by the module-not-found.
In this PR we register the import equals specifier so that it would not throw if it appears in an export named declaration later.
Note that we does not support transforming ImportEqualsDeclaration yet, but we should be able to parse it.
Credits to @jj-choi