Skip to content

Commit 3a3a1e4

Browse files
[CodeGen] Migrate away from PointerUnion::dyn_cast (NFC) (#123013)
Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with // isa<T>, cast<T> and the llvm::dyn_cast<T> Literal migration would result in dyn_cast_if_present (see the definition of PointerUnion::dyn_cast), but this patch uses dyn_cast because we expect Data to be nonnull.
1 parent 3fd296e commit 3a3a1e4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

clang/lib/CodeGen/CGOpenMPRuntime.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7768,7 +7768,7 @@ class MappableExprsHandler {
77687768
&Data : RecordLayout) {
77697769
if (Data.isNull())
77707770
continue;
7771-
if (const auto *Base = Data.dyn_cast<const CXXRecordDecl *>())
7771+
if (const auto *Base = dyn_cast<const CXXRecordDecl *>(Data))
77727772
getPlainLayout(Base, Layout, /*AsBase=*/true);
77737773
else
77747774
Layout.push_back(cast<const FieldDecl *>(Data));

0 commit comments

Comments
 (0)