[Lldb-commits] [PATCH] D111136: [lldb] [DynamicRegisterInfo] Support iterating over Registers()
Pavel Labath via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Tue Oct 5 05:31:08 PDT 2021
labath added inline comments.
================
Comment at: lldb/include/lldb/Target/DynamicRegisterInfo.h:81
+ typedef std::vector<lldb_private::RegisterInfo> reg_collection;
+ llvm::iterator_range<reg_collection::iterator> Registers() {
+ return llvm::iterator_range<reg_collection::iterator>(m_regs);
----------------
llvm (and, surprisingly, lldb -- I guess because its a new feature) follows c++ naming conventions for methods like these.
================
Comment at: lldb/include/lldb/Target/DynamicRegisterInfo.h:82
+ llvm::iterator_range<reg_collection::iterator> Registers() {
+ return llvm::iterator_range<reg_collection::iterator>(m_regs);
+ }
----------------
Could this return const iterators? It seems we already have some non-const accessors, but I'd rather not propagate that..
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D111136/new/
https://reviews.llvm.org/D111136
More information about the lldb-commits
mailing list