Skip to content

Commit f611935

Browse files
author
Jonah Cohen
committed
Fix autovector iterator increment/decrement comments
Summary: The prefix and postfix operators were mixed up in the autovector class. Test Plan: Inspection Reviewers: sdong, kailiu Reviewed By: kailiu Differential Revision: https://reviews.facebook.net/D21873
1 parent 58b0f9d commit f611935

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

util/autovector.h

+4-4
Original file line numberDiff line numberDiff line change
@@ -67,26 +67,26 @@ class autovector {
6767
iterator_impl& operator=(const iterator_impl&) = default;
6868

6969
// -- Advancement
70-
// iterator++
70+
// ++iterator
7171
self_type& operator++() {
7272
++index_;
7373
return *this;
7474
}
7575

76-
// ++iterator
76+
// iterator++
7777
self_type operator++(int) {
7878
auto old = *this;
7979
++index_;
8080
return old;
8181
}
8282

83-
// iterator--
83+
// --iterator
8484
self_type& operator--() {
8585
--index_;
8686
return *this;
8787
}
8888

89-
// --iterator
89+
// iterator--
9090
self_type operator--(int) {
9191
auto old = *this;
9292
--index_;

0 commit comments

Comments
 (0)