This revision was automatically updated to reflect the committed changes.
Closed by commit rL300340: [ObjC] Fix lifetime markers of loop variable in
EmitObjCForCollectionStmt [takeā¦ (authored by kuba.brecka).
Changed prior to commit:
https://reviews.llvm.org/D32029?vs=95271=95313#toc
rjmccall added a comment.
Those test changes are smaller than I thought they might be; great.
https://reviews.llvm.org/D32029
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
kubamracek updated this revision to Diff 95271.
kubamracek added a comment.
Trying a different approach: Keeping the loop variable alive for the whole
loop by extending ForScope and registering the cleanup function inside
EmitAutoVarAlloca.
https://reviews.llvm.org/D32029
Files:
kubamracek reopened this revision.
kubamracek added a comment.
This revision is now accepted and ready to land.
Reverted because this fails for-in.m by crashing the compiler when compiling:
void t2(NSArray *array) {
for (NSArray *array in array) { // expected-warning {{collection
This revision was automatically updated to reflect the committed changes.
Closed by commit rL300287: [ObjC] Fix lifetime markers of loop variable in
EmitObjCForCollectionStmt (authored by kuba.brecka).
Changed prior to commit:
https://reviews.llvm.org/D32029?vs=95157=95251#toc
Repository:
rjmccall accepted this revision.
rjmccall added a comment.
This revision is now accepted and ready to land.
Yes, looks good to me.
Repository:
rL LLVM
https://reviews.llvm.org/D32029
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
kubamracek added a comment.
Note that C++ foreach loops also generate lifetime.start and lifetime.end
inside of the loop body.
Repository:
rL LLVM
https://reviews.llvm.org/D32029
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
kubamracek created this revision.
kubamracek added a project: Sanitizers.
CodeGenFunction::EmitObjCForCollectionStmt currently emits lifetime markers for
the loop variable in an inconsistent way: `lifetime.start` is emitted before
the loop is entered, but `lifetime.end` is emitted inside the