template string not terminated when containing optional chaining
Categories
(DevTools :: Source Editor, defect)
Tracking
(firefox85 fixed)
Tracking | Status | |
---|---|---|
firefox85 | --- | fixed |
People
(Reporter: matze.kind, Assigned: bomsy)
References
Details
Attachments
(2 files)
User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:82.0) Gecko/20100101 Firefox/82.0
Steps to reproduce:
Have a template string with optional chaining inside, e.g.
const a = asdf${a?.b}1234
Look at the code iIn the debugger view
Actual results:
the closing curly bracket is not beeing detected as the terminator for the JS part, so any code that follows that statement is displayed in blue (as string content).
Expected results:
the closing curly bracket should terminate the js part and the next ` the template string, so that the following code is parsed as code
Comment 1•5 years ago
|
||
Bugbug thinks this bug should belong to this component, but please revert this change in case of error.
Comment 2•5 years ago
|
||
Thanks for the report!
I can reproduce the problem on my machine (Win10, Nightly)
@Hubert, could this be CodeMirror issue?
Honza
Assignee | ||
Comment 3•5 years ago
|
||
Thanks Honza.
Yeah ... looks like it.
i filed an issue
https://github.com/codemirror/CodeMirror/issues/6500
Assignee | ||
Comment 4•5 years ago
|
||
Updated•5 years ago
|
Updated•5 years ago
|
Comment 5•5 years ago
|
||
The component has been changed since the backlog priority was decided, so we're resetting it.
For more information, please visit auto_nag documentation.
Comment 7•5 years ago
|
||
bugherder |
Description
•