@@ -58,8 +58,8 @@ namespace ilist_detail {
5858template <bool IsExplicit> struct explicitness {
5959 static const bool is_explicit = IsExplicit;
6060};
61- typedef explicitness<true > is_explicit ;
62- typedef explicitness<false > is_implicit ;
61+ using is_explicit = explicitness<true >;
62+ using is_implicit = explicitness<false >;
6363
6464// / Check whether an option is valid.
6565// /
@@ -103,12 +103,12 @@ struct is_valid_option<ilist_sentinel_tracking<EnableSentinelTracking>>
103103template <class ... Options> struct extract_tag ;
104104template <class Tag , class ... Options>
105105struct extract_tag <ilist_tag<Tag>, Options...> {
106- typedef Tag type;
106+ using type = Tag ;
107107};
108108template <class Option1 , class ... Options>
109109struct extract_tag <Option1, Options...> : extract_tag<Options...> {};
110110template <> struct extract_tag <> {
111- typedef void type;
111+ using type = void ;
112112};
113113template <class Tag > struct is_valid_option <ilist_tag<Tag>> : std::true_type {};
114114
@@ -134,11 +134,13 @@ struct is_valid_option<ilist_iterator_bits<IteratorBits>> : std::true_type {};
134134template <class ... Options> struct extract_parent ;
135135template <class ParentTy , class ... Options>
136136struct extract_parent <ilist_parent<ParentTy>, Options...> {
137- typedef ParentTy type;
137+ using type = ParentTy ;
138138};
139139template <class Option1 , class ... Options>
140140struct extract_parent <Option1, Options...> : extract_parent<Options...> {};
141- template <> struct extract_parent <> { typedef void type; };
141+ template <> struct extract_parent <> {
142+ using type = void ;
143+ };
142144template <class ParentTy >
143145struct is_valid_option <ilist_parent<ParentTy>> : std::true_type {};
144146
@@ -154,28 +156,27 @@ struct check_options : std::conjunction<is_valid_option<Options>...> {};
154156template <class T , bool EnableSentinelTracking, bool IsSentinelTrackingExplicit,
155157 class TagT , bool HasIteratorBits, class ParentTy >
156158struct node_options {
157- typedef T value_type;
158- typedef T *pointer ;
159- typedef T &reference ;
160- typedef const T *const_pointer ;
161- typedef const T &const_reference ;
159+ using value_type = T ;
160+ using pointer = T *;
161+ using reference = T &;
162+ using const_pointer = const T *;
163+ using const_reference = const T &;
162164
163165 static const bool enable_sentinel_tracking = EnableSentinelTracking;
164166 static const bool is_sentinel_tracking_explicit = IsSentinelTrackingExplicit;
165167 static const bool has_iterator_bits = HasIteratorBits;
166- typedef TagT tag;
167- typedef ParentTy parent_ty;
168- typedef ilist_node_base<enable_sentinel_tracking, parent_ty> node_base_type ;
169- typedef ilist_base<enable_sentinel_tracking, parent_ty> list_base_type ;
168+ using tag = TagT ;
169+ using parent_ty = ParentTy ;
170+ using node_base_type = ilist_node_base<enable_sentinel_tracking, parent_ty>;
171+ using list_base_type = ilist_base<enable_sentinel_tracking, parent_ty>;
170172};
171173
172174template <class T , class ... Options> struct compute_node_options {
173- typedef node_options<T, extract_sentinel_tracking<Options...>::value,
174- extract_sentinel_tracking<Options...>::is_explicit,
175- typename extract_tag<Options...>::type,
176- extract_iterator_bits<Options...>::value,
177- typename extract_parent<Options...>::type>
178- type;
175+ using type = node_options<T, extract_sentinel_tracking<Options...>::value,
176+ extract_sentinel_tracking<Options...>::is_explicit,
177+ typename extract_tag<Options...>::type,
178+ extract_iterator_bits<Options...>::value,
179+ typename extract_parent<Options...>::type>;
179180};
180181
181182} // end namespace ilist_detail
0 commit comments