Details
-
Task
-
Resolution: Unresolved
-
P2: Important
-
None
-
None
-
None
Description
Nowadays, Qbs relies on QuickJS engine which supports ES2023. However, the Qbs' parser doesn't seem to understand the syntax.
As a user, I want to be able to use modern ES features including, but not limited to:
- template strings
- destructuring
- rest, spread, default
- arrow functions
- let and const
- for … of loop
- nullish coalescing ( and =)
- optional chaining ?.
- exponentiation **
- symbols
- modules
- etc.
Additionally and similarly to QML, anonymous functions and arrow functions should be allowed for properties of type script. Examples:
Rule { // ... prepare: (project, product, inputs, outputs, i, o, expDepOn) => { return [] } }
Module { setupRunEnvironment: (_, prd, cfg) => { ... } }
PathProbe { // ... nameFilter: f => !f.starsWith('.') // apparently, this is incorrect because the documentation on `PathProbe.nameFilter` does not explain how to properly use it }