|
Boost-Commit : |
From: d.frey_at_[hidden]
Date: 2008-08-07 16:47:58
Author: daniel_frey
Date: 2008-08-07 16:47:58 EDT (Thu, 07 Aug 2008)
New Revision: 48025
URL: http://svn.boost.org/trac/boost/changeset/48025
Log:
added/switched "euclidean" spelling
Text files modified:
trunk/boost/operators.hpp | 33 ++++++++++++++++++++++++++++++++-
trunk/libs/utility/operators.htm | 38 +++++++++++++++++++++++---------------
trunk/libs/utility/operators_test.cpp | 4 ++--
3 files changed, 57 insertions(+), 18 deletions(-)
Modified: trunk/boost/operators.hpp
==============================================================================
--- trunk/boost/operators.hpp (original)
+++ trunk/boost/operators.hpp 2008-08-07 16:47:58 EDT (Thu, 07 Aug 2008)
@@ -8,6 +8,7 @@
// See http://www.boost.org/libs/utility/operators.htm for documentation.
// Revision History
+// 07 Aug 08 Added "euclidean" spelling. (Daniel Frey)
// 03 Apr 08 Make sure "convertible to bool" is sufficient
// for T::operator<, etc. (Daniel Frey)
// 24 May 07 Changed empty_base to depend on T, see
@@ -582,7 +583,35 @@
: totally_ordered1<T
, euclidian_ring_operators1<T, B
> > {};
-
+
+template <class T, class U, class B = ::boost::detail::empty_base<T> >
+struct euclidean_ring_operators2
+ : ring_operators2<T, U
+ , dividable2<T, U
+ , dividable2_left<T, U
+ , modable2<T, U
+ , modable2_left<T, U, B
+ > > > > > {};
+
+template <class T, class B = ::boost::detail::empty_base<T> >
+struct euclidean_ring_operators1
+ : ring_operators1<T
+ , dividable1<T
+ , modable1<T, B
+ > > > {};
+
+template <class T, class U, class B = ::boost::detail::empty_base<T> >
+struct ordered_euclidean_ring_operators2
+ : totally_ordered2<T, U
+ , euclidean_ring_operators2<T, U, B
+ > > {};
+
+template <class T, class B = ::boost::detail::empty_base<T> >
+struct ordered_euclidean_ring_operators1
+ : totally_ordered1<T
+ , euclidean_ring_operators1<T, B
+ > > {};
+
template <class T, class P, class B = ::boost::detail::empty_base<T> >
struct input_iteratable
: equality_comparable1<T
@@ -839,6 +868,8 @@
BOOST_OPERATOR_TEMPLATE(ordered_field_operators)
BOOST_OPERATOR_TEMPLATE(euclidian_ring_operators)
BOOST_OPERATOR_TEMPLATE(ordered_euclidian_ring_operators)
+BOOST_OPERATOR_TEMPLATE(euclidean_ring_operators)
+BOOST_OPERATOR_TEMPLATE(ordered_euclidean_ring_operators)
BOOST_OPERATOR_TEMPLATE2(input_iteratable)
BOOST_OPERATOR_TEMPLATE1(output_iteratable)
BOOST_OPERATOR_TEMPLATE2(forward_iteratable)
Modified: trunk/libs/utility/operators.htm
==============================================================================
--- trunk/libs/utility/operators.htm (original)
+++ trunk/libs/utility/operators.htm 2008-08-07 16:47:58 EDT (Thu, 07 Aug 2008)
@@ -1420,9 +1420,9 @@
<tr>
<td><code><a name=
- "euclidian_ring_operators1">euclidian_ring_operators<T></a></code><br>
+ "euclidean_ring_operators1">euclidean_ring_operators<T></a></code><br>
- <code>euclidian_ring_operators1<T></code></td>
+ <code>euclidean_ring_operators1<T></code></td>
<td>
<ul>
@@ -1439,9 +1439,9 @@
<tr>
<td><code><a name=
- "euclidian_ring_operators2">euclidian_ring_operators<T,
+ "euclidean_ring_operators2">euclidean_ring_operators<T,
U></a></code><br>
- <code>euclidian_ring_operators2<T, U></code></td>
+ <code>euclidean_ring_operators2<T, U></code></td>
<td>
<ul>
@@ -1464,14 +1464,14 @@
<tr>
<td><code><a name=
- "ordered_euclidian_ring_operators1">ordered_euclidian_ring_operators<T></a></code><br>
+ "ordered_euclidean_ring_operators1">ordered_euclidean_ring_operators<T></a></code><br>
- <code>ordered_euclidian_ring_operators1<T></code></td>
+ <code>ordered_euclidean_ring_operators1<T></code></td>
<td>
<ul>
<li><code><a href=
- "#euclidian_ring_operators1">euclidian_ring_operators<T></a></code></li>
+ "#euclidean_ring_operators1">euclidean_ring_operators<T></a></code></li>
<li><code><a href=
"#totally_ordered1">totally_ordered<T></a></code></li>
@@ -1481,14 +1481,14 @@
<tr>
<td><code><a name=
- "ordered_euclidian_ring_operators2">ordered_euclidian_ring_operators<T,
+ "ordered_euclidean_ring_operators2">ordered_euclidean_ring_operators<T,
U></a></code><br>
- <code>ordered_euclidian_ring_operators2<T, U></code></td>
+ <code>ordered_euclidean_ring_operators2<T, U></code></td>
<td>
<ul>
<li><code><a href=
- "#euclidian_ring_operators2">euclidian_ring_operators<T,
+ "#euclidean_ring_operators2">euclidean_ring_operators<T,
U></a></code></li>
<li><code><a href="#totally_ordered2">totally_ordered<T,
@@ -1498,6 +1498,15 @@
</tr>
</table>
+ <h4>Spelling: euclidean vs. euclidian</h4>
+
+ <p>Older versions of the Boost.Operators library used
+ "<code>euclidian</code>", but it was pointed out that
+ "<code>euclidean</code>" is the more common spelling.
+ To be compatible with older version, the library now supports
+ both spellings.
+ </p>
+
<h3><a name="ex_oprs">Example</a> Templates</h3>
<p>The arithmetic operator class templates <code><a href=
@@ -1576,9 +1585,8 @@
<p>The <cite>operators_test.cpp</cite>
program demonstrates the use of the arithmetic operator templates, and
- can also be used to verify correct operation. Check the <a href=
- "../../status/compiler_status.html">compiler status report</a> for the
- test results with selected platforms.</p>
+ can also be used to verify correct operation. Check the compiler status
+ report for the test results with selected platforms.</p>
<h2><a name="deref">Dereference</a> Operators and Iterator Helpers</h2>
@@ -2119,10 +2127,10 @@
backward-compatible.</p>
<hr>
- <p>Revised: 29 Oct 2004</p>
+ <p>Revised: 7 Aug 2008</p>
<p>Copyright © Beman Dawes, David Abrahams, 1999-2001.</p>
- <p>Copyright © Daniel Frey, 2002-2004.</p>
+ <p>Copyright © Daniel Frey, 2002-2008.</p>
<p>Use, modification, and distribution is subject to the Boost Software
License, Version 1.0. (See accompanying file
<a href="../../LICENSE_1_0.txt">LICENSE_1_0.txt</a> or copy at
Modified: trunk/libs/utility/operators_test.cpp
==============================================================================
--- trunk/libs/utility/operators_test.cpp (original)
+++ trunk/libs/utility/operators_test.cpp 2008-08-07 16:47:58 EDT (Thu, 07 Aug 2008)
@@ -258,8 +258,8 @@
// U must be convertible to T
template <class T, class U>
class Wrapped6
- : boost::ordered_euclidian_ring_operators2<Wrapped6<T, U>, U>
- , boost::ordered_euclidian_ring_operators1<Wrapped6<T, U> >
+ : boost::ordered_euclidean_ring_operators2<Wrapped6<T, U>, U>
+ , boost::ordered_euclidean_ring_operators1<Wrapped6<T, U> >
{
public:
explicit Wrapped6( T v = T() ) : _value(v) {}
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