[all-commits] [llvm/llvm-project] d1ba26: [LLVM][Clang] Enable strict mode for `getTrailingO...
Rahul Joshi via All-commits
all-commits at lists.llvm.org
Mon Jun 30 07:23:58 PDT 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: d1ba2692ee523de2da502753e8e666d2ef530df3
https://github.com/llvm/llvm-project/commit/d1ba2692ee523de2da502753e8e666d2ef530df3
Author: Rahul Joshi <rjoshi at nvidia.com>
Date: 2025-06-30 (Mon, 30 Jun 2025)
Changed paths:
M clang/include/clang/AST/OpenMPClause.h
M clang/lib/AST/Expr.cpp
M llvm/include/llvm/Support/TrailingObjects.h
M llvm/unittests/Support/TrailingObjectsTest.cpp
Log Message:
-----------
[LLVM][Clang] Enable strict mode for `getTrailingObjects` (#144930)
Disallow calls to templated `getTrailingObjects` if there is a single
trailing type (strict mode). Add `getTrailingObjectsNonStrict` for cases
when it's not possible to know statically if there will be a single or
multiple trailing types (like in OpenMPClause.h) to bypass the struct
checks.
This will ensure that future users of TrailingObjects class do not
accidently use the templated `getTrailingObjects` when they have a
single trailing type.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list