diff options
Diffstat (limited to 'llvm/include/llvm/CodeGen/DIE.h')
| -rw-r--r-- | llvm/include/llvm/CodeGen/DIE.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/llvm/include/llvm/CodeGen/DIE.h b/llvm/include/llvm/CodeGen/DIE.h index 270fa5c7c8d..5a8f4915f5e 100644 --- a/llvm/include/llvm/CodeGen/DIE.h +++ b/llvm/include/llvm/CodeGen/DIE.h @@ -499,7 +499,16 @@ public: const std::vector<std::unique_ptr<DIE>> &getChildren() const { return Children; } - const SmallVectorImpl<DIEValue> &getValues() const { return Values; } + + typedef SmallVectorImpl<DIEValue>::const_iterator value_iterator; + typedef iterator_range<value_iterator> value_range; + + value_iterator begin_values() const { return Values.begin(); } + value_iterator end_values() const { return Values.end(); } + value_range values() const { + return llvm::make_range(begin_values(), end_values()); + } + void setValue(unsigned I, DIEValue New) { assert(I < Values.size()); Values[I] = New; |

