[PATCH] D102679: [llvm] Make Sequence reverse-iterable
Clement Courbet via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri May 21 07:30:36 PDT 2021
courbet added inline comments.
================
Comment at: llvm/include/llvm/ADT/Sequence.h:93
+ // Dereference
+ T operator*() const { return Value; }
+ T operator[](difference_type Offset) const { return Op::add(Value, Offset); }
----------------
This is formally OK given that the return value `T` verifies `__Referenceable<T>`, but is there any reason not to return a `const T&` ?
(Again, this is mostly a theoretical argument, feel free to ignore.)
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D102679/new/
https://reviews.llvm.org/D102679
More information about the llvm-commits
mailing list