This patch fixes a bug where a temporary ObjC pointer is released before the end of the full expression.
This fixes PR50043.
rdar://77030453
Paths
| Differential D101502
[ObjC][ARC] Don't enter the cleanup scope if the initializer expression isn't an ExprWithCleanups ClosedPublic Authored by ahatanak on Apr 28 2021, 5:56 PM.
Details Summary This patch fixes a bug where a temporary ObjC pointer is released before the end of the full expression. This fixes PR50043. rdar://77030453
Diff Detail
Event TimelineThis revision is now accepted and ready to land.Apr 28 2021, 7:03 PM This revision was landed with ongoing or failed builds.Apr 29 2021, 4:07 PM Closed by commit rG2e1d9ebd46b8: [ObjC][ARC] Don't enter the cleanup scope if the initializer expression (authored by ahatanak). · Explain Why This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 341366 clang/lib/CodeGen/CGDecl.cpp
clang/test/CodeGenObjCXX/arc-blocks.mm
clang/test/CodeGenObjCXX/arc.mm
|
clang-tidy: warning: 'auto *EWC' can be declared as 'const auto *EWC' [llvm-qualified-auto]
not useful