Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r76173 - in trunk/boost/heap: . detail
From: tim_at_[hidden]
Date: 2011-12-26 10:31:04


Author: timblechmann
Date: 2011-12-26 10:31:03 EST (Mon, 26 Dec 2011)
New Revision: 76173
URL: http://svn.boost.org/trac/boost/changeset/76173

Log:
heap: convert for(;;) to while (true) to silence msvc warning

Text files modified:
   trunk/boost/heap/binomial_heap.hpp | 2 +-
   trunk/boost/heap/detail/heap_comparison.hpp | 8 ++++----
   trunk/boost/heap/detail/tree_iterator.hpp | 2 +-
   3 files changed, 6 insertions(+), 6 deletions(-)

Modified: trunk/boost/heap/binomial_heap.hpp
==============================================================================
--- trunk/boost/heap/binomial_heap.hpp (original)
+++ trunk/boost/heap/binomial_heap.hpp 2011-12-26 10:31:03 EST (Mon, 26 Dec 2011)
@@ -807,7 +807,7 @@
         if (it != trees.end())
             BOOST_HEAP_ASSERT(static_cast<node_pointer>(&*it)->child_count() >= n->child_count());
 
- for (;;) {
+ while(true) {
             BOOST_HEAP_ASSERT(!n->is_linked());
             if (it == trees.end())
                 break;

Modified: trunk/boost/heap/detail/heap_comparison.hpp
==============================================================================
--- trunk/boost/heap/detail/heap_comparison.hpp (original)
+++ trunk/boost/heap/detail/heap_comparison.hpp 2011-12-26 10:31:03 EST (Mon, 26 Dec 2011)
@@ -70,7 +70,7 @@
         Heap1 lhs_copy(lhs);
         Heap2 rhs_copy(rhs);
 
- for (;;) {
+ while (true) {
             if (!value_equality(lhs_copy, rhs_copy, lhs_copy.top(), rhs_copy.top()))
                 return false;
 
@@ -112,7 +112,7 @@
         typename Heap1::ordered_iterator it1_end = lhs.ordered_end();
         typename Heap1::ordered_iterator it2 = rhs.ordered_begin();
         typename Heap1::ordered_iterator it2_end = rhs.ordered_end();
- for(;;) {
+ while (true) {
             if (!value_equality(lhs, rhs, *it1, *it2))
                 return false;
 
@@ -165,7 +165,7 @@
         typename Heap1::ordered_iterator it1_end = lhs.ordered_end();
         typename Heap1::ordered_iterator it2 = rhs.ordered_begin();
         typename Heap1::ordered_iterator it2_end = rhs.ordered_end();
- for(;;) {
+ while (true) {
             if (value_compare(lhs, rhs, *it1, *it2))
                 return true;
 
@@ -202,7 +202,7 @@
         Heap1 lhs_copy(lhs);
         Heap2 rhs_copy(rhs);
 
- for (;;) {
+ while (true) {
             if (value_compare(lhs_copy, rhs_copy, lhs_copy.top(), rhs_copy.top()))
                 return true;
 

Modified: trunk/boost/heap/detail/tree_iterator.hpp
==============================================================================
--- trunk/boost/heap/detail/tree_iterator.hpp (original)
+++ trunk/boost/heap/detail/tree_iterator.hpp 2011-12-26 10:31:03 EST (Mon, 26 Dec 2011)
@@ -349,7 +349,7 @@
 
             ++next;
 
- for (;;) {
+ while (true) {
                 if (parent == NULL || next != parent->children.end())
                     break;
 


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk