closure-compiler
closure-compiler copied to clipboard
suppress {es5Strict} does not work
File example.js:
/** @suppress {es5Strict} */
function hello() {
var a = "\306";
}
Command: java -jar closure-compiler.jar example.js
Output:
example.js:3:10: WARNING - [JSC_INVALID_OCTAL_LITERAL] This style of octal literal is not supported in strict mode.
3| var a = "\306";
^
0 error(s), 1 warning(s)
function hello(){};
Related bug: https://github.com/bazelbuild/rules_closure/issues/502
Can you confirm the version of the compiler you are using?
closure-compiler-v20210106.jar going to try a newer one (if any)
closure-compiler-v20210302.jar has the same problem
Ok, with strict mode input this is a parse error and thus not suppressible.