diff options
author | Tim Shen <timshen91@gmail.com> | 2016-08-09 20:22:55 +0000 |
---|---|---|
committer | Tim Shen <timshen91@gmail.com> | 2016-08-09 20:22:55 +0000 |
commit | 0c7496718623caaf71c4ff6b9354891fcabca07f (patch) | |
tree | 3042b7c9c4ddd5979f950eeedefe633f40554e93 | |
parent | ffb60901fe088950c7683e20e7c9b198695cdddc (diff) | |
download | bcm5719-llvm-0c7496718623caaf71c4ff6b9354891fcabca07f.tar.gz bcm5719-llvm-0c7496718623caaf71c4ff6b9354891fcabca07f.zip |
[ADT] Change iterator_adaptor_base's default template arguments to forward more underlying typedefs
Summary:
The corresponding LLVM change: D23217.
LazyVector::iterator breaks, because int isn't an iterator type.
Since iterator_adaptor_base shouldn't be blamed to break at the call to
iterator_traits<int>::xxx, I'd rather "fix" LazyVector::iterator.
The perfect solution is to model "relative pointer", but it's beyond the goal of this patch.
Reviewers: chandlerc, bkramer
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D23218
llvm-svn: 278156
-rw-r--r-- | clang/include/clang/AST/ExternalASTSource.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/clang/include/clang/AST/ExternalASTSource.h b/clang/include/clang/AST/ExternalASTSource.h index 81cf631c7a4..2e99f395f49 100644 --- a/clang/include/clang/AST/ExternalASTSource.h +++ b/clang/include/clang/AST/ExternalASTSource.h @@ -503,8 +503,9 @@ public: /// We define this as a wrapping iterator around an int. The /// iterator_adaptor_base class forwards the iterator methods to basic integer /// arithmetic. - class iterator : public llvm::iterator_adaptor_base< - iterator, int, std::random_access_iterator_tag, T, int> { + class iterator + : public llvm::iterator_adaptor_base< + iterator, int, std::random_access_iterator_tag, T, int, T *, T &> { LazyVector *Self; iterator(LazyVector *Self, int Position) |