Subject: [PATCH] Fix C++17 compilation warnings regarding the use of the deprecated std::iterator.
---
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
diff --git a/lemon/maps.h b/lemon/maps.h
a
|
b
|
|
1969 | 1969 | /// be accessed in the <tt>[beginValue, endValue)</tt> range. |
1970 | 1970 | /// They are considered with multiplicity, so each value is |
1971 | 1971 | /// traversed for each item it is assigned to. |
1972 | | class ValueIt |
1973 | | : public std::iterator<std::forward_iterator_tag, Value> { |
| 1972 | class ValueIt { |
1974 | 1973 | friend class CrossRefMap; |
1975 | 1974 | private: |
1976 | 1975 | ValueIt(typename Container::const_iterator _it) |
1977 | 1976 | : it(_it) {} |
1978 | 1977 | public: |
| 1978 | using iterator_category = std::forward_iterator_tag; |
| 1979 | using value_type = Value; |
| 1980 | using difference_type = void; |
| 1981 | using pointer = void; |
| 1982 | using reference = void; |
1979 | 1983 | |
1980 | 1984 | /// Constructor |
1981 | 1985 | ValueIt() {} |
… |
… |
|
3131 | 3135 | /// This iterator is an STL compatible forward |
3132 | 3136 | /// iterator on the values of the map. The values can |
3133 | 3137 | /// be accessed in the <tt>[beginValue, endValue)</tt> range. |
3134 | | class ValueIt |
3135 | | : public std::iterator<std::forward_iterator_tag, Value> { |
| 3138 | class ValueIt { |
3136 | 3139 | friend class IterableValueMap; |
3137 | 3140 | private: |
3138 | 3141 | ValueIt(typename std::map<Value, Key>::const_iterator _it) |
3139 | 3142 | : it(_it) {} |
3140 | 3143 | public: |
| 3144 | using iterator_category = std::forward_iterator_tag; |
| 3145 | using value_type = Value; |
| 3146 | using difference_type = void; |
| 3147 | using pointer = void; |
| 3148 | using reference = void; |
3141 | 3149 | |
3142 | 3150 | /// Constructor |
3143 | 3151 | ValueIt() {} |