[Development] Toolability of mixing QML and JS

Rutledge Shawn Shawn.Rutledge at digia.com
Wed Jun 26 14:40:56 CEST 2013


On 26 Jun 2013, at 2:31 PM, Bubke Marco wrote:

> Rutledge Shawn:
>> But you have the AST right?  So why not modify that and then regenerate the code by pretty-printing the expression?
> 
> At this level we have no AST.

So such a simple expression is already JS not QML, and therefore it's opaque to you?  But I would think there should be a nested AST of a different kind then, or at least you could get the other AST by sending that expression to the JS parser.  (Now that we own it, instead of the V8 black box)

> The value of x could changed in a different place too, so we could be never sure that
> parent.leftPadding = x - 30.

But in C++ in the code editor you can find all usages of a variable, doesn't that require a similar level of code understanding?




More information about the Development mailing list