summaryrefslogtreecommitdiff
path: root/test/ARCMT/autoreleases.m
diff options
context:
space:
mode:
Diffstat (limited to 'test/ARCMT/autoreleases.m')
-rw-r--r--test/ARCMT/autoreleases.m10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/ARCMT/autoreleases.m b/test/ARCMT/autoreleases.m
index a131bc53391d..543bcf6632af 100644
--- a/test/ARCMT/autoreleases.m
+++ b/test/ARCMT/autoreleases.m
@@ -64,3 +64,13 @@ void test(A *prevVal, A *newVal) {
[prevVal autorelease];
prevVal = [newVal retain];
}
+
+id test2(A* val) {
+ [[val retain] autorelease];
+ return val;
+}
+
+id test3() {
+ id a = [[A alloc] init];
+ [a autorelease];
+}