Closed
Bug 1192329
Opened 8 years ago
Closed 8 years ago
Change JS shell to default to the standard version of JS (not 1.7+)
Categories
(Core :: JavaScript Engine, defect)
Core
JavaScript Engine
Tracking
()
RESOLVED
FIXED
mozilla44
Tracking | Status | |
---|---|---|
firefox44 | --- | fixed |
People
(Reporter: jorendorff, Assigned: mrrrgn)
References
Details
(Keywords: dev-doc-complete, Whiteboard: [mentor=jorendorff])
Attachments
(3 files)
2.18 KB,
patch
|
jorendorff
:
review+
|
Details | Diff | Splinter Review |
1.12 KB,
patch
|
jorendorff
:
review+
|
Details | Diff | Splinter Review |
987 bytes,
patch
|
jorendorff
:
review+
|
Details | Diff | Splinter Review |
As reported in bug 1146532: js> var yield; typein:1:4 SyntaxError: yield is a reserved identifier: Nonsense. The js shell should default to standard, Web-compatible JS. The version() shell builtin is still there for testing legacy features.
Updated•8 years ago
|
Keywords: dev-doc-needed
Assignee | ||
Updated•8 years ago
|
Assignee: nobody → winter2718
Assignee | ||
Comment 1•8 years ago
|
||
Snagging this ^.^
Comment 2•8 years ago
|
||
+1 I encountered this when working on let in V8. I mistakenly thought SpiderMonkey reserved let as a keyword for a while. I am using the easy workaround of writing a web page for it, but it'd be great if the js repl were fixed.
Reporter | ||
Updated•8 years ago
|
Whiteboard: [mentor=jorendorff]
Reporter | ||
Comment 3•8 years ago
|
||
Start by changing JSVERSION_LATEST to JSVERSION_DEFAULT throughout js/src/shell/js.cpp. If there's an interesting part, it'll involve fixing busted tests. Broad-spectrum restoration of the old gross version for particular directories of tests is OK: the goal of this bug is to fix the shell for people using it interactively.
Comment 4•8 years ago
|
||
This is a dupe of Bug 1173883...
Comment 5•8 years ago
|
||
Not really. Web console is not the same as the JS shell.
Assignee | ||
Comment 6•8 years ago
|
||
Attachment #8677863 -
Flags: review?(jorendorff)
Assignee | ||
Comment 7•8 years ago
|
||
Attachment #8677864 -
Flags: review?(jorendorff)
Assignee | ||
Comment 8•8 years ago
|
||
Sorry for the long turnaround time here. The changes to JSVERSION_DEFAULT in shell/js.cpp didn't break tests because the shell tests were already calling "version(0)" before running. I went ahead and removed that since it's unnecessary now.
Assignee | ||
Comment 9•8 years ago
|
||
A try push: https://treeherder.mozilla.org/#/jobs?repo=try&revision=31295dd54fc5
Reporter | ||
Comment 10•8 years ago
|
||
Comment on attachment 8677863 [details] [diff] [review] smshell.1.diff Review of attachment 8677863 [details] [diff] [review]: ----------------------------------------------------------------- Great! Glad this turned out to be easy for once.
Attachment #8677863 -
Flags: review?(jorendorff) → review+
Reporter | ||
Updated•8 years ago
|
Attachment #8677864 -
Flags: review?(jorendorff) → review+
Comment 11•8 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/a0ccab2a6e28 https://hg.mozilla.org/integration/mozilla-inbound/rev/cefec636b2d5
Assignee | ||
Comment 12•8 years ago
|
||
This fixes the asm tests by explicitly setting a version.
Attachment #8678298 -
Flags: review?(jorendorff)
Reporter | ||
Comment 14•8 years ago
|
||
Comment on attachment 8678298 [details] [diff] [review] smshell.3.diff I already gave this review on IRC, but it doesn't hurt to have it here too.
Attachment #8678298 -
Attachment is patch: true
Attachment #8678298 -
Flags: review?(jorendorff) → review+
Comment 15•8 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/a0ccab2a6e28 https://hg.mozilla.org/mozilla-central/rev/cefec636b2d5 https://hg.mozilla.org/mozilla-central/rev/cc0945ec65c6
Status: NEW → RESOLVED
Closed: 8 years ago
status-firefox44:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla44
Comment 16•8 years ago
|
||
Added a note to https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey/Introduction_to_the_JavaScript_shell and https://developer.mozilla.org/en-US/Firefox/Releases/44#JavaScript
Keywords: dev-doc-needed → dev-doc-complete
Assignee | ||
Comment 17•8 years ago
|
||
(In reply to Florian Scholz [:fscholz] (MDN) from comment #16) > Added a note to > https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey/ > Introduction_to_the_JavaScript_shell and > https://developer.mozilla.org/en-US/Firefox/Releases/44#JavaScript Ah, thank you! /me Takes note to always remember docs for the future. :)
You need to log in
before you can comment on or make changes to this bug.
Description
•