Closed Bug 973130 Opened 10 years ago Closed 10 years ago

js::ActivationIterator::settle contains extraneous code

Categories

(Core :: JavaScript Engine, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla30

People

(Reporter: jimb, Assigned: jimb)

Details

Attachments

(1 file)

The 'if' condition in this function can never be true, because it's negated
in the immediately preceding 'while' condition.
Attachment #8376632 - Flags: review?(hv1989)
Flags: in-testsuite-
Good catch! Now the patch itself is obvious r+, but I want to investigate this further. So I'll leave this review flag for myself. I want to convince myself the code (before and after this patch) is correct. I will try to do that on Wednesday.
Comment on attachment 8376632 [details] [diff] [review]
Remove extraneous code from ActivationIterator::settle.

Review of attachment 8376632 [details] [diff] [review]:
-----------------------------------------------------------------

Thanks! That is correct.

::: js/src/vm/Stack.cpp
@@ +1361,5 @@
>  }
>  
>  void
>  ActivationIterator::settle()
>  {

// Stop at the next active activation.
// No need to update jitTop_, since we don't iterate over an active jit activation.

Can you add the following comment?
Attachment #8376632 - Flags: review?(hv1989) → review+
(In reply to Hannes Verschore [:h4writer] from comment #2)
> Can you add the following comment?

Added.

https://hg.mozilla.org/integration/mozilla-inbound/rev/b3987040d624
Assignee: nobody → jimb
Target Milestone: --- → mozilla30
https://hg.mozilla.org/mozilla-central/rev/b3987040d624
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: