ANN: ClojureScript 1.9.493, another bugfix release

211 views
Skip to first unread message

David Nolen

unread,
Feb 24, 2017, 4:47:03 PM2/24/17
to clojure, clojur...@googlegroups.com
ClojureScript, the Clojure compiler that emits JavaScript source code.


Leiningen dependency information:

[org.clojure/clojurescript "1.9.493"]

This is a bugfix release.

As always, feedback welcome!

### Fixes
* CLJS-1948: Possible race condition in compiler w/ parallel-build true
* CLJS-1941: `cljs.compiler/cljs-files-in` shouldn't return `.cljc` files if a `.cljs` file exists for the namespace
* CLJS-1940: Undeclared var warning when invoking a protocol method on a `js` interop form
* CLJS-1951: Missing 0 and 1 arity versions of interleave
* CLJS-1952: Bump Closure Compiler to Feb 2017 release
* CLJS-1937: Self-host: undeclared cljs.core$macros/mod when compiling cljs/core.cljs
* CLJS-1936: cljs.analyzer declares vars which are only used in Clojure
* CLJS-1949: Self-host: cljs.compiler/munge doesn't preserve JVM compiler semantics
* CLJS-1950: Eliminate instances of #^
* CLJS-1943: Self-host: `cljs.pprint`'s macros can't be compiled
* CLJS-1945: cljs.spec/every-impl kind-fn kind-form dead code
* CLJS-1944: Can't spec generate non-vector collections
* CLJS-1946: Self-hosted: don't emit `goog.require` calls for foreign libs if optimizations different than `:none`
* CLJS-1636: Mark some symbols in core macros ns as private
* CLJS-1939: Fix Node load_file call for foreign-deps
* CLJS-1942: Self-host: `cljs.env.macros` and `cljs.analyzer.macros` can't be loaded
* CLJS-1935: When calling cljs.spec/valid?, subsequent predicates of cljs.spec/and are evaluated even when early predicate is unsatisfied

David Nolen

unread,
Feb 24, 2017, 7:21:35 PM2/24/17
to clojure, clojur...@googlegroups.com
Just cut 1.9.494 to back out some macros that were made unintentionally private.

Rangel Spasov

unread,
Feb 24, 2017, 11:46:03 PM2/24/17
to ClojureScript, clo...@googlegroups.com
Hey guys,

I'm getting this error. It seems that it's happening inside the transpiled core.async sources. The error carrot at line 1444 points at the semicolon, pretty strange.


Feb 24, 2017 8:38:19 PM com.google.javascript.jscomp.LoggerErrorManager println
SEVERE: /Users/raspasov/projects/project123/target/ios/cljs/core/async.js:1444: ERROR - Parse error. No newline allowed before '=>'
var inst_33727 = async(inst_33726); (^ points at the semicolon)

Feb 24, 2017 8:38:19 PM com.google.javascript.jscomp.LoggerErrorManager printSummary
WARNING: 1 error(s), 4 warning(s)
ERROR: JSC_PARSE_ERROR. Parse error. No newline allowed before '=>' at /Users/raspasov/projects/project123/target/ios/cljs/core/async.js line 1444 : 34

I tried both :parallel-build true/false but it doesn't make a difference. It works fine on [org.clojure/clojurescript "1.9.473"]


Here's how the async.js source looks like around line 1444.

return cljs.core.cst$kw$recur;
} else {
if((state_val_33738 === (2))){
var state_33737__$1 = state_33737;
return cljs.core.async.impl.ioc_helpers.take_BANG_(state_33737__$1,(4),jobs);
} else {
if((state_val_33738 === (3))){
var inst_33735 = (state_33737[(2)]);
var state_33737__$1 = state_33737;
return cljs.core.async.impl.ioc_helpers.return_chan(state_33737__$1,inst_33735);
} else {
if((state_val_33738 === (4))){
var inst_33726 = (state_33737[(2)]);
var inst_33727 = async(inst_33726); <<<<<<<<<<<<<<<< This is the error line number 1444
var state_33737__$1 = state_33737;
if(cljs.core.truth_(inst_33727)){
var statearr_33743_33989 = state_33737__$1;
(statearr_33743_33989[(1)] = (5));

} else {
var statearr_33744_33990 = state_33737__$1;
(statearr_33744_33990[(1)] = (6));

}

return cljs.core.cst$kw$recur;
} else {
if((state_val_33738 === (5))){
var state_33737__$1 = state_33737;
var statearr_33745_33992 = state_33737__$1;
(statearr_33745_33992[(2)] = null);

(statearr_33745_33992[(1)] = (2));


return cljs.core.cst$kw$recur;
} else {
if((state_val_33738 === (6))){
var state_33737__$1 = state_33737;
var statearr_33746_33993 = state_33737__$1;
(statearr_33746_33993[(2)] = null);

(statearr_33746_33993[(1)] = (7));


return cljs.core.cst$kw$recur;
} else {
if((state_val_33738 === (7))){
var inst_33733 = (state_33737[(2)]);
var state_33737__$1 = state_33737;
var statearr_33747_33994 = state_33737__$1;
(statearr_33747_33994[(2)] = inst_33733);

(statearr_33747_33994[(1)] = (3));


return cljs.core.cst$kw$recur;
} else {
return null;

Rangel Spasov

unread,
Feb 24, 2017, 11:51:10 PM2/24/17
to ClojureScript, clo...@googlegroups.com
Forgot to add: this is my :compiler settings map.

{:output-to "index.ios.js"
:main "env.ios.main"
:output-dir "target/ios"
:static-fns true
:optimize-constants true
:parallel-build true
;:pretty-print true
;:pseudo-names true
:source-map "cljs-source-map.js"
:optimizations :advanced
:externs ["externs/externs.js"]
:closure-defines {"goog.DEBUG" false}}

Rangel Spasov

unread,
Feb 26, 2017, 4:48:06 PM2/26/17
to ClojureScript, clo...@googlegroups.com
I did some digging/manual shrinking.

It seems that any core.async code with the latest version of ClojureScript does not compile under :advanced. I suspect the problem lies with the bump of Google Closure dependency and/or core.async.

I made a repo showing a minimal case:

https://github.com/raspasov/cljs-1.9.494-core-async-broken

David Nolen

unread,
Mar 1, 2017, 1:38:22 PM3/1/17
to clojur...@googlegroups.com
This is a known issue with the latest Closure Compiler release. You will need to specify the previous version of Closure Compiler via your dependency tool.

David

--
Note that posts from new members are moderated - please be patient with your first post.
---
You received this message because you are subscribed to the Google Groups "ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email to clojurescript+unsubscribe@googlegroups.com.
To post to this group, send email to clojur...@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.

Reply all
Reply to author
Forward
0 new messages