ClojureScript

NPE when using :source-maps with :optimizations :whitespace on a second run

Details

  • Type: Defect Defect
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Completed
  • Affects Version/s: None
  • Fix Version/s: None
  • Component/s: None
  • Labels:
    None

Description

When compiling without cleaning previous compilation results (e.g. using cljsbuild and not removing target/) a NPE is generated.
Stacktrace looks like:

java.lang.NullPointerException
	at cljs.closure$optimize.doInvoke(closure.clj:738)
	at clojure.lang.RestFn.applyTo(RestFn.java:139)
	at clojure.core$apply.invoke(core.clj:619)
	at cljs.closure$build.invoke(closure.clj:985)
	at cljs.closure$build.invoke(closure.clj:944)

This cannot be reproduced consistently (probably depends on the nature of the change?).

Activity

Julien Eluard made changes -
Field Original Value New Value
Attachment cljs_ticket_634.patch [ 12359 ]
Hide
Julien Eluard added a comment -

Attached a patch. It might not be fixing the root issue but fixes the problem and is safe in all cases.

Show
Julien Eluard added a comment - Attached a patch. It might not be fixing the root issue but fixes the problem and is safe in all cases.
David Nolen made changes -
Priority Minor [ 4 ] Major [ 3 ]
Julien Eluard made changes -
Attachment cljs_ticket_634-2.patch [ 12378 ]
Hide
Julien Eluard added a comment -

Updated the patch as an extra parenthesis sneaked in.

Show
Julien Eluard added a comment - Updated the patch as an extra parenthesis sneaked in.
David Nolen made changes -
Resolution Completed [ 1 ]
Status Open [ 1 ] Resolved [ 5 ]
David Nolen made changes -
Status Resolved [ 5 ] Closed [ 6 ]

People

Vote (0)
Watch (1)

Dates

  • Created:
    Updated:
    Resolved: