Revision: 15342
Author:   [email protected]
Date:     Wed Jun 26 09:18:00 2013
Log: Fix misleading names and comments in mute local variables debugger helper

[email protected]

Review URL: https://codereview.chromium.org/17644013
http://code.google.com/p/v8/source/detail?r=15342

Modified:
 /branches/bleeding_edge/src/mirror-debugger.js
 /branches/bleeding_edge/src/runtime.cc

=======================================
--- /branches/bleeding_edge/src/mirror-debugger.js      Tue Jun 25 06:48:43 2013
+++ /branches/bleeding_edge/src/mirror-debugger.js      Wed Jun 26 09:18:00 2013
@@ -1707,18 +1707,18 @@
                                     opt_context_object);
   // Silently ignore local variables changes if the frame is optimized.
   if (!this.isOptimizedFrame()) {
-    var local_scope_before = result_array[1];
-    var local_scope_after = result_array[2];
-    for (var n in local_scope_after) {
-      var value_before = local_scope_before[n];
-      var value_after = local_scope_after[n];
-      if (value_before !== value_after) {
+    var local_scope_on_stack = result_array[1];
+    var local_scope_modifed = result_array[2];
+    for (var n in local_scope_modifed) {
+      var value_on_stack = local_scope_on_stack[n];
+      var value_modifed = local_scope_modifed[n];
+      if (value_on_stack !== value_modifed) {
         %SetScopeVariableValue(this.break_id_,
                                this.details_.frameId(),
                                this.details_.inlinedFrameIndex(),
                                0,
                                n,
-                               value_after);
+                               value_modifed);
       }
     }
   }
=======================================
--- /branches/bleeding_edge/src/runtime.cc      Wed Jun 26 06:36:16 2013
+++ /branches/bleeding_edge/src/runtime.cc      Wed Jun 26 09:18:00 2013
@@ -12422,8 +12422,10 @@
// stack frame is currently stopped when we compile and run the (direct) eval.
 // Returns array of
 // #0: evaluate result
-// #1: local variables scope materizalized as object before evaluation
-// #2: local variables scope materizalized as object after evaluation
+// #1: local variables materizalized again as object after evaluation, contain
+//     original variable values as they remained on stack
+// #2: local variables materizalized as object before evaluation (and possibly
+//     modified by expression having been executed)
// Since user expression only reaches (and modifies) copies of local variables, // those copies are returned to the caller to allow tracking the changes and
 // manually updating the actual variables.
@@ -12533,14 +12535,14 @@
   }
   Handle<Object> evaluate_result(evaluate_result_object, isolate);

- Handle<JSObject> local_scope_after = MaterializeLocalScopeWithFrameInspector(
-      isolate, frame, &frame_inspector);
+  Handle<JSObject> local_scope_control_copy =
+      MaterializeLocalScopeWithFrameInspector(isolate, frame,
+                                              &frame_inspector);

-  Handle<FixedArray> resultArray =
-      isolate->factory()->NewFixedArray(3);
+  Handle<FixedArray> resultArray = isolate->factory()->NewFixedArray(3);
   resultArray->set(0, *evaluate_result);
+  resultArray->set(1, *local_scope_control_copy);
   resultArray->set(2, *local_scope);
-  resultArray->set(1, *local_scope_after);

   return *(isolate->factory()->NewJSArrayWithElements(resultArray));
 }

--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to