Reviewers: Mads Ager,

Description:
Fixed operator precedence bug in heap stat recording.

Please review this at http://codereview.chromium.org/465055

Affected files:
   M src/global-handles.cc


Index: src/global-handles.cc
diff --git a/src/global-handles.cc b/src/global-handles.cc
index  
f3b2b0c50cf100db90e3690ea7f4c9a43b32f67d..1a0c982936f7b45e2fd305a1cee75b8e09171c82
  
100644
--- a/src/global-handles.cc
+++ b/src/global-handles.cc
@@ -436,15 +436,15 @@ void GlobalHandles::RecordStats(HeapStats* stats) {
    *stats->near_death_global_handle_count = 0;
    *stats->destroyed_global_handle_count = 0;
    for (Node* current = head_; current != NULL; current = current->next()) {
-    *stats->global_handle_count++;
+    *stats->global_handle_count += 1;
      if (current->state_ == Node::WEAK) {
-      *stats->weak_global_handle_count++;
+      *stats->weak_global_handle_count += 1;
      } else if (current->state_ == Node::PENDING) {
-      *stats->pending_global_handle_count++;
+      *stats->pending_global_handle_count += 1;
      } else if (current->state_ == Node::NEAR_DEATH) {
-      *stats->near_death_global_handle_count++;
+      *stats->near_death_global_handle_count += 1;
      } else if (current->state_ == Node::DESTROYED) {
-      *stats->destroyed_global_handle_count++;
+      *stats->destroyed_global_handle_count += 1;
      }
    }
  }


-- 
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

Reply via email to