Closed
Bug 938203
Opened 11 years ago
Closed 2 years ago
[meta] [prettify] support pretty printing ES6
Categories
(DevTools :: General, defect)
Tracking
(Not tracked)
RESOLVED
WORKSFORME
People
(Reporter: lp_, Unassigned)
References
(Blocks 1 open bug)
Details
(Keywords: meta)
In Scratchpad of current Nightly, given following codes, foo = (x) => x+1; let a = [1,2,3]; for (x of a) console.log(x); when "Pretty Print", these codes get wrong results as this: foo = (x) = > x + 1; leta = [ 1, 2, 3 ]; for (xofa) console.log(x); the ArrowExpression "=>" becomes "= >", with a space in the middle. "let a" becomes "leta", and "(x of a)" becomes "(xofa)". This means that currently the "Pretty Print" in Scratchpad cannot correctly print chrome://ping/content/xbl/scratchpad.js itself.
(wrong url) This means that currently the "Pretty Print" in Scratchpad cannot correctly print chrome://browser/content/devtools/scratchpad.js itself.
Comment 2•11 years ago
|
||
We recently switched to using acorn [1] for our parser, which only supports ES5. We hope to either add ES6 support or that the author will add ES6 support in the future, but there's a lot of new syntax in ES6.
OS: Windows XP → All
Hardware: x86 → All
Updated•11 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
Updated•11 years ago
|
Summary: Pretty Print give wrong result for some syntax (ArrowExpression, ForOfStatement, LetStatement, etc) → [prettify] support pretty printing ES6
Updated•11 years ago
|
Blocks: 1006524
Summary: [prettify] support pretty printing ES6 → [meta] [prettify] support pretty printing ES6
Updated•10 years ago
|
Updated•9 years ago
|
Updated•9 years ago
|
Blocks: dbg-prettyprint
Problem still exist. Same issue with "Pretty Print" scratchpad in FF57.
Updated•6 years ago
|
Product: Firefox → DevTools
Updated•2 years ago
|
Severity: normal → S3
Comment 8•2 years ago
|
||
I think we handled the cases that were problematic and it doesn't make sense to keep this meta around as we have Bug 1070862
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → WORKSFORME
You need to log in
before you can comment on or make changes to this bug.
Description
•