diff --git a/clang/test/Analysis/objc-arc.m b/clang/test/Analysis/objc-arc.m index 6b22fd099b06..8e18877f29c6 100644 --- a/clang/test/Analysis/objc-arc.m +++ b/clang/test/Analysis/objc-arc.m @@ -147,3 +147,9 @@ void test_objc_unretainedObject() { (void) x; } +// Previously this resulted in a "return of stack address" warning. +id test_return() { + id x = (__bridge_transfer id) CFCreateString(); + return x; // no-warning +} +