<< Back to previous view

[CLJS-743] Allow language_in and language_out options to be passed to the Google Closure compiler Created: 04/Jan/14  Updated: 15/Sep/14  Resolved: 23/Feb/14

Status: Closed
Project: ClojureScript
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Enhancement Priority: Major
Reporter: Ivan Willig Assignee: Unassigned
Resolution: Completed Votes: 0
Labels: None

Attachments: Text File CLJS-743.patch    

 Description   

While I was messing around with ClojureScript and nodejs, I
noticed that the Google Closure compiler complains when JavaScript
reserved words are used. Newer versions of JavaScript engines allow
reserved words (like "static", "class") to be used as object
properties. The Closure Compiler knows this and does not complain when
you set the language_in option to the correct version of JavaScript.



 Comments   
Comment by David Nolen [ 07/Jan/14 7:07 AM ]

Excellent thanks.

Comment by David Nolen [ 09/Jan/14 5:17 PM ]

Ivan have you signed and sent in your CA?

Comment by Chas Emerick [ 20/Feb/14 9:23 AM ]

@iwillig Looking forward to seeing this, def send in that CA.

Comment by Ivan Willig [ 20/Feb/14 10:06 PM ]

I apologize for letting this slip, work got busy. CA is in the mail.

Comment by David Nolen [ 23/Feb/14 4:33 PM ]

fixed, https://github.com/clojure/clojurescript/commit/b33bde39fe838d367939b55b9dadb0480ea00a7c

Comment by Richard Hull [ 14/Sep/14 3:22 PM ]

Could the ECMASCRIPT6 and ECMASCRIPT6_STRICT enums be added please?
http://javadoc.closure-compiler.googlecode.com/git/com/google/javascript/jscomp/CompilerOptions.LanguageMode.html

Not really a major problem, but when I set :language-in to ECMASCRIPT5 without setting :language-out, I get the following:

com.google.javascript.jscomp.CompilerOptionsValidator$InvalidOptionsException: 
Can only convert code from ES6 to ES3. Cannot convert from ECMASCRIPT5 to ECMASCRIPT3.
Comment by David Nolen [ 15/Sep/14 12:17 PM ]

Richard please open a new ticket for this.

Generated at Tue Sep 23 07:20:10 CDT 2014 using JIRA 4.4#649-r158309.