[llvm-commits] CVS: llvm/test/FrontendObjC/2007-05-02-Strong.m
Devang Patel
dpatel at apple.com
Wed May 2 17:42:40 PDT 2007
Changes in directory llvm/test/FrontendObjC:
2007-05-02-Strong.m added (r1.1)
---
Log message:
New test.
---
Diffs of the changes: (+23 -0)
2007-05-02-Strong.m | 23 +++++++++++++++++++++++
1 files changed, 23 insertions(+)
Index: llvm/test/FrontendObjC/2007-05-02-Strong.m
diff -c /dev/null llvm/test/FrontendObjC/2007-05-02-Strong.m:1.1
*** /dev/null Wed May 2 19:42:32 2007
--- llvm/test/FrontendObjC/2007-05-02-Strong.m Wed May 2 19:42:22 2007
***************
*** 0 ****
--- 1,23 ----
+ // RUN: %llvmgcc -c %s -fobjc-gc -o /dev/null
+ typedef int NSInteger;
+ typedef struct _NSRect {
+ int origin;
+ int size;
+ } NSRect;
+
+ __attribute__((objc_gc(strong))) NSRect *_cachedRectArray;
+ extern const NSRect NSZeroRect;
+ @interface A{
+ }
+ -(void)bar:(NSInteger *)rectCount;
+ @end
+
+ @implementation A
+
+ -(void)bar:(NSInteger *)rectCount {
+ NSRect appendRect = NSZeroRect;
+
+ _cachedRectArray[*rectCount - 1] = NSZeroRect;
+ }
+
+ @end
More information about the llvm-commits
mailing list