[prev in list] [next in list] [prev in thread] [next in thread]
List: apache-stdcxx-commits
Subject: svn commit: r718628 - /stdcxx/branches/4.3.x/include/rw/_heap.cc
From: faridz () apache ! org
Date: 2008-11-18 15:09:07
Message-ID: 20081118150907.1876C2388892 () eris ! apache ! org
[Download RAW message or body]
Author: faridz
Date: Tue Nov 18 07:09:06 2008
New Revision: 718628
URL: http://svn.apache.org/viewvc?rev=718628&view=rev
Log:
2008-11-18 Farid Zaripov <faridz@apache.org>
Merged r718626 from 4.2.x branch.
STDCXX-1022
* include/rw/_heap.cc (__make_heap): Optimize the loop with fixing the ICE on MSVC.
Modified:
stdcxx/branches/4.3.x/include/rw/_heap.cc
Modified: stdcxx/branches/4.3.x/include/rw/_heap.cc
URL: http://svn.apache.org/viewvc/stdcxx/branches/4.3.x/include/rw/_heap.cc?rev=718628&r1=718627&r2=718628&view=diff
==============================================================================
--- stdcxx/branches/4.3.x/include/rw/_heap.cc (original)
+++ stdcxx/branches/4.3.x/include/rw/_heap.cc Tue Nov 18 07:09:06 2008
@@ -95,11 +95,10 @@
const _Dist __dist = __last - __first;
- for (_Dist __parent = (__dist - 2) / 2; ; --__parent) {
+ for (_Dist __parent = __dist / 2; 0 < __parent; ) {
+ --__parent;
__adjust_heap (__first, __parent, __dist, *(__first + __parent),
__comp);
- if (__parent == 0)
- return;
}
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic