declare the "_,__, __ _" vars for both expression and statment cases

Change 20091124-hqm-v by [email protected] on 2009-11-24 14:46:43 EST
    in /Users/hqm/openlaszlo/trunk6
    for http://svn.openlaszlo.org/openlaszlo/trunk

Summary: fix for evaluating function expressions in debugger in swf10

New Features:

Bugs Fixed: LPP-8633

Technical Reviewer: ptw
QA Reviewer: (pending)
Doc Reviewer: (pending)

Documentation:

Release Notes:

Overview:
    

Details:
    
compiling with(Debug.environment) {} is causing some weird error in swf10 in 
the debug eval script 
that we're generating.

In order to be able to access the debugger globals '_', '__', '___',
we define these as local vars in the runTopLevelDefinitions
method, and copy the values from Debug.environment before executing the user's 
script fragment.


Tests:

+ In debugger in swf10 eval the expression 
(function (x) { return x.foo })(3)
and get a useful error

+ enter the number "259" in the debugger,
and then enter the expression "_ + 1", the value should come back as 260. 



Files:
M       WEB-INF/lps/lfc/kernel/swf9/LFCApplication.as
M       WEB-INF/lps/server/src/org/openlaszlo/compiler/Compiler.java

Changeset: http://svn.openlaszlo.org/openlaszlo/patches/20091124-hqm-v.tar

_______________________________________________
Laszlo-reviews mailing list
[email protected]
http://www.openlaszlo.org/mailman/listinfo/laszlo-reviews

Reply via email to