Drop the only dependency I had on boost.
This commit is contained in:
parent
ccb2fc7ae5
commit
8c917cf38b
1 changed files with 3 additions and 2 deletions
|
@ -32,8 +32,8 @@
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <ciso646>
|
#include <ciso646>
|
||||||
#include <climits>
|
#include <climits>
|
||||||
#include <boost/range/adaptor/reversed.hpp>
|
|
||||||
#include <cstddef>
|
#include <cstddef>
|
||||||
|
#include <iterator>
|
||||||
|
|
||||||
namespace dhandy {
|
namespace dhandy {
|
||||||
namespace customize {
|
namespace customize {
|
||||||
|
@ -96,7 +96,8 @@ namespace dhandy {
|
||||||
inline T string_to_int (const F& parFrom) {
|
inline T string_to_int (const F& parFrom) {
|
||||||
T retval(0);
|
T retval(0);
|
||||||
T mul(1);
|
T mul(1);
|
||||||
for (auto chara : boost::adaptors::reverse(parFrom)) {
|
for (auto it = std::rbegin(parFrom), itEND = std::rend(parFrom); it != itEND; ++it) {
|
||||||
|
const auto chara = *it;
|
||||||
retval += dhandy::customize::char_to_int<decltype(chara), T>::make(chara) * mul;
|
retval += dhandy::customize::char_to_int<decltype(chara), T>::make(chara) * mul;
|
||||||
mul *= Tag<T>::base;
|
mul *= Tag<T>::base;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue