[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in ExprObjC (PR #143254)
via cfe-commits
cfe-commits at lists.llvm.org
Sat Jun 7 06:31:25 PDT 2025
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-clang
Author: Rahul Joshi (jurahul)
<details>
<summary>Changes</summary>
---
Full diff: https://github.com/llvm/llvm-project/pull/143254.diff
1 Files Affected:
- (modified) clang/include/clang/AST/ExprObjC.h (+2-4)
``````````diff
diff --git a/clang/include/clang/AST/ExprObjC.h b/clang/include/clang/AST/ExprObjC.h
index f87fa85569c44..3d9b3c4585e8a 100644
--- a/clang/include/clang/AST/ExprObjC.h
+++ b/clang/include/clang/AST/ExprObjC.h
@@ -217,12 +217,10 @@ class ObjCArrayLiteral final
SourceRange getSourceRange() const LLVM_READONLY { return Range; }
/// Retrieve elements of array of literals.
- Expr **getElements() { return getTrailingObjects<Expr *>(); }
+ Expr **getElements() { return getTrailingObjects(); }
/// Retrieve elements of array of literals.
- const Expr * const *getElements() const {
- return getTrailingObjects<Expr *>();
- }
+ const Expr *const *getElements() const { return getTrailingObjects(); }
/// getNumElements - Return number of elements of objective-c array literal.
unsigned getNumElements() const { return NumElements; }
``````````
</details>
https://github.com/llvm/llvm-project/pull/143254
More information about the cfe-commits
mailing list