diff --git a/docs/emcc.txt b/docs/emcc.txt index 560542e38a35f..10b216fde55f2 100644 --- a/docs/emcc.txt +++ b/docs/emcc.txt @@ -252,7 +252,7 @@ Options that are modified or new in *emcc* are listed below: "--closure 0|1|2" [link] Runs the *Closure Compiler*. Possible values are: - * "0": No closure compiler (default in "-O2" and below). + * "0": No closure compiler (default). * "1": Run closure compiler. This greatly reduces the size of the support JavaScript code (everything but the WebAssembly or @@ -277,9 +277,6 @@ Options that are modified or new in *emcc* are listed below: before the closure-compiled code runs, because then it will reuse that variable. - * Closure is only run if JavaScript opts are being done ("-O2" or - above). - "--closure-args=" [link] Pass arguments to the *Closure compiler*. This is an alternative to "EMCC_CLOSURE_ARGS". diff --git a/site/source/docs/tools_reference/emcc.rst b/site/source/docs/tools_reference/emcc.rst index 557eb6daa850a..8f107b8f73255 100644 --- a/site/source/docs/tools_reference/emcc.rst +++ b/site/source/docs/tools_reference/emcc.rst @@ -262,7 +262,7 @@ Options that are modified or new in *emcc* are listed below: [link] Runs the :term:`Closure Compiler`. Possible values are: - - ``0``: No closure compiler (default in ``-O2`` and below). + - ``0``: No closure compiler (default). - ``1``: Run closure compiler. This greatly reduces the size of the support JavaScript code (everything but the WebAssembly or asm.js). Note that this increases compile time significantly. - ``2``: Run closure compiler on *all* the emitted code, even on **asm.js** output in **asm.js** mode. This can further reduce code size, but does prevent a significant amount of **asm.js** optimizations, so it is not recommended unless you want to reduce code size at all costs. @@ -270,7 +270,6 @@ Options that are modified or new in *emcc* are listed below: - Consider using ``-sMODULARIZE`` when using closure, as it minifies globals to names that might conflict with others in the global scope. ``MODULARIZE`` puts all the output into a function (see ``src/settings.js``). - Closure will minify the name of `Module` itself, by default! Using ``MODULARIZE`` will solve that as well. Another solution is to make sure a global variable called `Module` already exists before the closure-compiled code runs, because then it will reuse that variable. - - Closure is only run if JavaScript opts are being done (``-O2`` or above). ``--closure-args=`` [link]