|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r64526 - sandbox/SOC/2010/quasi_random/libs/random/example/detail
From: jvd_at_[hidden]
Date: 2010-08-01 13:02:20
Author: qrng
Date: 2010-08-01 13:02:20 EDT (Sun, 01 Aug 2010)
New Revision: 64526
URL: http://svn.boost.org/trac/boost/changeset/64526
Log:
Fixed indentation
Text files modified:
sandbox/SOC/2010/quasi_random/libs/random/example/detail/constant_size_array.hpp | 24 ++++++++++----------
sandbox/SOC/2010/quasi_random/libs/random/example/detail/list_assignment.hpp | 48 ++++++++++++++++++++--------------------
2 files changed, 36 insertions(+), 36 deletions(-)
Modified: sandbox/SOC/2010/quasi_random/libs/random/example/detail/constant_size_array.hpp
==============================================================================
--- sandbox/SOC/2010/quasi_random/libs/random/example/detail/constant_size_array.hpp (original)
+++ sandbox/SOC/2010/quasi_random/libs/random/example/detail/constant_size_array.hpp 2010-08-01 13:02:20 EDT (Sun, 01 Aug 2010)
@@ -16,20 +16,20 @@
template<class T, std::size_t N>
struct constant_size_array : public boost::array<T, N>
{
- constant_size_array(std::size_t m)
- {
- // Assert that this array holds exactly the same
- // size of memory block as requested
- BOOST_ASSERT(m == N);
- }
+ constant_size_array(std::size_t m)
+ {
+ // Assert that this array holds exactly the same
+ // size of memory block as requested
+ BOOST_ASSERT(m == N);
+ }
- void resize(std::size_t) {
- BOOST_ASSERT("Cannot resize a constant sized array." == 0);
- }
+ void resize(std::size_t) {
+ BOOST_ASSERT("Cannot resize a constant sized array." == 0);
+ }
- void resize(std::size_t size, T init) {
- BOOST_ASSERT("Cannot resize a constant sized array." == 0);
- }
+ void resize(std::size_t size, T init) {
+ BOOST_ASSERT("Cannot resize a constant sized array." == 0);
+ }
};
} // namespace detail
Modified: sandbox/SOC/2010/quasi_random/libs/random/example/detail/list_assignment.hpp
==============================================================================
--- sandbox/SOC/2010/quasi_random/libs/random/example/detail/list_assignment.hpp (original)
+++ sandbox/SOC/2010/quasi_random/libs/random/example/detail/list_assignment.hpp 2010-08-01 13:02:20 EDT (Sun, 01 Aug 2010)
@@ -18,9 +18,9 @@
{
private:
typedef list_assignment<T, ForwardIterator>
- self_type;
+ self_type;
typedef scalar_or_list_assignment<T, ForwardIterator>
- switch_type;
+ switch_type;
ForwardIterator m_iterator_;
@@ -32,8 +32,8 @@
inline self_type operator,(T value)
{
- *m_iterator_ = value;
- return self_type(++m_iterator_);
+ *m_iterator_ = value;
+ return self_type(++m_iterator_);
}
};
@@ -45,35 +45,35 @@
friend class list_assignment<T, ForwardIterator>;
typedef scalar_or_list_assignment<T, ForwardIterator>
- self_t;
+ self_t;
typedef list_assignment<T, ForwardIterator>
- assign_from_list;
+ assign_from_list;
public:
explicit scalar_or_list_assignment(ForwardIterator first, ForwardIterator last, T value)
- : m_first(first)
- , m_last(last)
- , m_value(value)
+ : m_first(first)
+ , m_last(last)
+ , m_value(value)
{
- // Immediately initialize the first element
- // and move iterator position forward.
- *m_first = value; ++m_first;
+ // Immediately initialize the first element
+ // and move iterator position forward.
+ *m_first = value; ++m_first;
}
scalar_or_list_assignment(const self_t& rhs)
- : m_first(rhs.m_first)
- , m_last(rhs.m_last)
- , m_value(rhs.m_value)
+ : m_first(rhs.m_first)
+ , m_last(rhs.m_last)
+ , m_value(rhs.m_value)
{
- // This is, admitedly, not very pretty, but quite necessary
- // for optimization purposes; initialization would be O(n^2)
- // instead of O(n) otherwise.
- const_cast<self_t *>(&rhs)->disable();
+ // This is, admitedly, not very pretty, but quite necessary
+ // for optimization purposes; initialization would be O(n^2)
+ // instead of O(n) otherwise.
+ const_cast<self_t *>(&rhs)->disable();
}
~scalar_or_list_assignment()
{
- std::fill(m_first, m_last, m_value);
+ std::fill(m_first, m_last, m_value);
}
// Continues initialization of [first + 1, last)
@@ -81,13 +81,13 @@
// to the underlying data structure.
assign_from_list operator,(T value)
{
- *m_first = value; ++m_first;
- return assign_from_list(*this);
+ *m_first = value; ++m_first;
+ return assign_from_list(*this);
}
private:
void disable() {
- m_first = m_last;
+ m_first = m_last;
}
private:
@@ -102,7 +102,7 @@
template<class T, typename Iterator>
inline list_assignment<T, Iterator>::list_assignment(scalar_or_list_assignment<T, Iterator>& rhs)
- : m_iterator_(rhs.m_first)
+ : m_iterator_(rhs.m_first)
{
rhs.disable();
}
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