Skip to content

creating a build with --optimizations other than none fails #353

@johbra

Description

@johbra

Creating a build with
clojure -M -m figwheel.main --optimizations none --build-once anything
all works correctly.

Trying
clojure -M -m figwheel.main --optimizations whitespace --build-once anything
I get

SLF4J: No SLF4J providers were found.
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See https://www.slf4j.org/codes.html#noProviders for further details.
[Figwheel] Compiling build anything to "target/public/cljs-out/anything-main.js"
Feb. 14, 2026 11:44:41 PM com.google.javascript.jscomp.LoggerErrorManager println
SCHWERWIEGEND: /Users/jb/tmp/anti/target/public/cljs-out/anything/goog/i18n/numberformat.js:963:8: ERROR - [JSC_LANGUAGE_FEATURE] This language feature is only supported for ECMASCRIPT_2019 mode or better: Optional catch binding.
963| } catch {
^

Feb. 14, 2026 11:44:41 PM com.google.javascript.jscomp.LoggerErrorManager println
SCHWERWIEGEND: /Users/jb/tmp/anti/target/public/cljs-out/anything/goog/i18n/numberformat.js:1011:6: ERROR - [JSC_LANGUAGE_FEATURE] This language feature is only supported for ECMASCRIPT_2019 mode or better: Optional catch binding.
1011| } catch {
^

Feb. 14, 2026 11:44:41 PM com.google.javascript.jscomp.LoggerErrorManager printSummary
WARNUNG: 2 error(s), 0 warning(s)
ERROR: JSC_LANGUAGE_FEATURE. This language feature is only supported for ECMASCRIPT_2019 mode or better: Optional catch binding. at /Users/jb/tmp/anti/target/public/cljs-out/anything/goog/i18n/numberformat.js line 963 : 8
ERROR: JSC_LANGUAGE_FEATURE. This language feature is only supported for ECMASCRIPT_2019 mode or better: Optional catch binding. at /Users/jb/tmp/anti/target/public/cljs-out/anything/goog/i18n/numberformat.js line 1011 : 6
[Figwheel] Failed to compile build anything in 4.651 seconds.
[Figwheel:WARNING] Compile Exception: Closure compilation failed
[Figwheel:SEVERE]
Unexpected error compiling at (REPL:1).
Closure compilation failed

What is going wrong

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions