|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r64015 - sandbox/SOC/2010/bits_and_ints/boost/integer
From: muriloufg_at_[hidden]
Date: 2010-07-14 14:22:21
Author: murilov
Date: 2010-07-14 14:22:20 EDT (Wed, 14 Jul 2010)
New Revision: 64015
URL: http://svn.boost.org/trac/boost/changeset/64015
Log:
Renamed swap() to swap_in_place() to avoid conflicts with another boost::swap() implementation
Added:
sandbox/SOC/2010/bits_and_ints/boost/integer/swap_in_place.hpp (contents, props changed)
Removed:
sandbox/SOC/2010/bits_and_ints/boost/integer/swap.hpp
Deleted: sandbox/SOC/2010/bits_and_ints/boost/integer/swap.hpp
==============================================================================
--- sandbox/SOC/2010/bits_and_ints/boost/integer/swap.hpp 2010-07-14 14:22:20 EDT (Wed, 14 Jul 2010)
+++ (empty file)
@@ -1,29 +0,0 @@
-// Boost integer/swap.hpp header file ------------------------------//
-
-// (C) Copyright Murilo Adriano Vasconcelos 2010.
-// Distributed under the Boost Software License, Version 1.0. (See
-// accompanying file LICENSE_1_0.txt or copy at
-// http://www.boost.org/LICENSE_1_0.txt
-
-// See http://www.boost.org for updates, documentation, and revision history.
-
-#ifndef BOOST_SWAP_INCLUDED
-#define BOOST_SWAP_INCLUDED
-
-namespace boost {
-
-/*
- * This function swaps the values of x and y without a temporary variable.
- */
-
-template <typename T>
-inline void swap(T& x, T& y)
-{
- x ^= y;
- y ^= x;
- x ^= y;
-} // swap
-
-} // boost
-
-#endif
Added: sandbox/SOC/2010/bits_and_ints/boost/integer/swap_in_place.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2010/bits_and_ints/boost/integer/swap_in_place.hpp 2010-07-14 14:22:20 EDT (Wed, 14 Jul 2010)
@@ -0,0 +1,29 @@
+// Boost integer/swap.hpp header file ------------------------------//
+
+// (C) Copyright Murilo Adriano Vasconcelos 2010.
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt
+
+// See http://www.boost.org for updates, documentation, and revision history.
+
+#ifndef BOOST_SWAP_IN_PLACE_INCLUDED
+#define BOOST_SWAP_IN_PLACE_INCLUDED
+
+namespace boost {
+
+/*
+ * This function swaps the values of x and y without a temporary variable.
+ */
+
+template <typename T>
+inline void swap_in_place(T& x, T& y)
+{
+ x ^= y;
+ y ^= x;
+ x ^= y;
+} // swap
+
+} // boost
+
+#endif
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