Ted Kremenek | 565e465 | 2010-02-05 02:06:54 +0000 | [diff] [blame] | 1 | // RUN: %clang_cc1 -analyze -analyzer-experimental-internal-checks -analyzer-check-objc-mem -analyzer-store=basic -analyzer-constraints=basic %s -verify |
| 2 | // RUN: %clang_cc1 -analyze -analyzer-experimental-internal-checks -analyzer-check-objc-mem -analyzer-store=basic -analyzer-constraints=range %s -verify |
| 3 | // RUN: %clang_cc1 -analyze -analyzer-experimental-internal-checks -analyzer-check-objc-mem -analyzer-store=region -analyzer-constraints=basic %s -verify |
| 4 | // RUN: %clang_cc1 -analyze -analyzer-experimental-internal-checks -analyzer-check-objc-mem -analyzer-store=region -analyzer-constraints=range %s -verify |
Ted Kremenek | b6b81d1 | 2008-10-17 17:24:14 +0000 | [diff] [blame] | 5 | |
| 6 | // The point of this test cases is to exercise properties in the static |
| 7 | // analyzer |
| 8 | |
| 9 | @interface MyClass { |
| 10 | @private |
| 11 | id _X; |
| 12 | } |
| 13 | - (id)initWithY:(id)Y; |
Fariborz Jahanian | 6669db9 | 2008-11-25 17:56:43 +0000 | [diff] [blame] | 14 | @property(copy, readwrite) id X; |
Ted Kremenek | b6b81d1 | 2008-10-17 17:24:14 +0000 | [diff] [blame] | 15 | @end |
| 16 | |
| 17 | @implementation MyClass |
| 18 | @synthesize X = _X; |
| 19 | - (id)initWithY:(id)Y { |
| 20 | self.X = Y; |
| 21 | return self; |
| 22 | } |
| 23 | @end |