Closed
Bug 921163
Opened 10 years ago
Closed 10 years ago
pretty printing shouldn't lose comments
Categories
(DevTools :: Debugger, defect, P3)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: fitzgen, Unassigned)
References
Details
Right now we use Reflect.jsm to parse our source, which doesn't add comment nodes to its AST, and so when we pass the AST to escodegen, we lose comments. I see three ways to try and fix this, moving forward: 1. Add an option to Reflect.jsm to include comment nodes. 2. We will probably include the Acorn parser in devtools soon, which can optionally include comment nodes. We could use this instead of Reflect.jsm to parse code. 3. Use some post processing hueristics to attempt to place comments back into the code. I am in favor of 2.
Reporter | ||
Updated•10 years ago
|
Priority: -- → P3
Reporter | ||
Comment 2•10 years ago
|
||
Fixed when we introduced https://github.com/mozilla/pretty-fast
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Updated•5 years ago
|
Product: Firefox → DevTools
You need to log in
before you can comment on or make changes to this bug.
Description
•