Details
-
Bug
-
Resolution: Done
-
Not Evaluated
-
Qt Creator 4.8.1
-
None
-
Qt 5.12.0, Qt Creator 4.8.1, Mac OS 10.14.3, Apple LLVM version 10.0.0 (clang-1000.11.45.5)
Description
Qt Creator gives me a syntax error for the following code:
function someFunction(someVar, anotherVar = false) // "=" is underlined and "Syntax error" is shown { if (anotherVar === true) { console.log(someVar); } }
I might be wrong, but default parameters for JS functions were added in ECMAScript 6, and Qt now supports ECMAScript 7, so it should not be a syntax error.