Remove the expired std::iterator template (#554)

This commit is contained in:
An Tao 2020-08-26 20:53:04 +08:00 committed by GitHub
parent a10e6bfb1c
commit 4a9ba2088c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 13 deletions

View File

@ -23,15 +23,10 @@ namespace drogon
{
namespace orm
{
class ConstResultIterator
: public std::iterator<std::random_access_iterator_tag,
const Row,
Result::DifferenceType,
ConstResultIterator,
Row>,
protected Row
class ConstResultIterator : protected Row
{
public:
using iterator_category = std::random_access_iterator_tag;
using pointer = const Row *;
using reference = const Row &;
using value_type = const Row;

View File

@ -23,12 +23,7 @@ namespace drogon
{
namespace orm
{
class ConstRowIterator : public std::iterator<std::random_access_iterator_tag,
const Field,
Row::DifferenceType,
ConstRowIterator,
Field>,
protected Field
class ConstRowIterator : protected Field
{
public:
using pointer = const Field *;
@ -36,6 +31,7 @@ class ConstRowIterator : public std::iterator<std::random_access_iterator_tag,
using value_type = const Field;
using size_type = Row::SizeType;
using difference_type = Row::DifferenceType;
using iterator_category = std::random_access_iterator_tag;
// ConstRowIterator(const Field &t) noexcept : Field(t) {}
pointer operator->()