Open dankurka opened 9 years ago
There's actually another pathology that I didn't mention in the original description:
3) Function invocation instrumentations don't match the execution order.
Here's an artificial example.
Suppose G is the line number of the invocation of g, F is the line number of the invocation
of f, and the original code is
f(x, g(y))
JsStackEmulator.java from GWT 2.5 instruments that code as follows:
location[stackIndex]=F, f(x, (location[stackIndex]=G,g(y)))
This is wrong because once control passes into f, the line number in the previous stack
frame will be G, while it should really be F.
Solution:
The patch I'm working on will introduce a temporary variable along with some cleverly-situated
comma expressions that will allow recording the line number of the original invocation
at the end of the argument list, such that the above example will be rewritten as follows:
f(x,(temp=(location[stackIndex]=G,g(y)),(location[stackIndex]=F,temp)))
Reported by alexander.epshteyn
on 2013-04-23 07:47:04
Correction: the ClickEvent example actually demonstrates problem #3, not #2.
Reported by alexander.epshteyn
on 2013-04-23 09:18:53
Hi Alexander,
please make sure to discuss this on gwt contrib as well. So that other can help you
figure this one out!
Reported by dankurka@google.com
on 2013-05-27 21:19:54
NeedsInfo
Originally reported on Google Code with ID 8112
Reported by
alexander.epshteyn
on 2013-04-21 20:06:53