ClojureScript

Flag to disable minification in advanced mode

Details

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

Description

Problem:
Some code has different semantics when compiled in advanced mode.
Clojurescript tries to minimize those cases, but examples are usage of aget or forgotten externs files.
There exits closure compiler options to generate names based on original expressions, even with advanced optimizations.
However, there exists no clojurescript compiler option for that.

Proposal:
Add a :debug compiler option to clojurescript, which can be set to true to turn the following closure compiler options on:

  • generatePseudoNames true
  • anonymousFunctionNaming AnonymousFunctionNamingPolicy/UNMAPPED

Attached patch implements this, as a result the compiled test suite is indeed quite readable.

Activity

Hide
David Nolen added a comment -

I'd rather see a patch that supplies :anon-fn-naming-policy as a compiler option. Thanks.

Show
David Nolen added a comment - I'd rather see a patch that supplies :anon-fn-naming-policy as a compiler option. Thanks.
Hide
David Nolen added a comment -

Dependencies between tickets is highly undesirable as there's no guarantee when a particular patch will get reviewed and applied.

Show
David Nolen added a comment - Dependencies between tickets is highly undesirable as there's no guarantee when a particular patch will get reviewed and applied.
Hide
Herwig Hochleitner added a comment -

Patch 0001 depends on patches 0001 and 0002 from CLJS-480 because of changes to the test script.

Show
Herwig Hochleitner added a comment - Patch 0001 depends on patches 0001 and 0002 from CLJS-480 because of changes to the test script.

People

Vote (0)
Watch (1)

Dates

  • Created:
    Updated:
    Resolved: