diff options
Diffstat (limited to 'include/llvm/IR/Metadata.h')
-rw-r--r-- | include/llvm/IR/Metadata.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/llvm/IR/Metadata.h b/include/llvm/IR/Metadata.h index 92f701e01ff3..3c753260190e 100644 --- a/include/llvm/IR/Metadata.h +++ b/include/llvm/IR/Metadata.h @@ -1223,6 +1223,7 @@ public: // FIXME: Fix callers and remove condition on N. unsigned size() const { return N ? N->getNumOperands() : 0u; } + bool empty() const { return N ? N->getNumOperands() == 0 : true; } T *operator[](unsigned I) const { return cast_or_null<T>(N->getOperand(I)); } // FIXME: Fix callers and remove condition on N. |