use using instead of typedef

This commit is contained in:
Max Kellermann 2020-03-16 21:01:46 +01:00 committed by Max Kellermann
parent ad00926e1b
commit b282682ba5

View File

@ -46,7 +46,7 @@ template<typename T>
class BasicIterableSplitString { class BasicIterableSplitString {
typedef BasicStringView<T> StringView; typedef BasicStringView<T> StringView;
typedef typename StringView::value_type value_type; using value_type = typename StringView::value_type;
StringView s; StringView s;
value_type separator; value_type separator;
@ -89,7 +89,7 @@ public:
} }
public: public:
typedef std::forward_iterator_tag iterator_category; using iterator_category = std::forward_iterator_tag;
Iterator &operator++() { Iterator &operator++() {
Next(); Next();
@ -113,8 +113,8 @@ public:
} }
}; };
typedef Iterator iterator; using iterator = Iterator;
typedef Iterator const_iterator; using const_iterator = Iterator;
const_iterator begin() const { const_iterator begin() const {
return {s, separator}; return {s, separator};