Argyrios Kyrtzidis | c4d2c90 | 2011-02-28 19:49:42 +0000 | [diff] [blame] | 1 | // RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-store region -analyzer-inline-call -cfg-add-implicit-dtors -verify %s |
Zhongxing Xu | b13453b | 2010-11-20 06:53:12 +0000 | [diff] [blame] | 2 | |
3 | class A { | ||||
4 | public: | ||||
5 | ~A() { | ||||
6 | int *x = 0; | ||||
7 | *x = 3; // expected-warning{{Dereference of null pointer}} | ||||
8 | } | ||||
9 | }; | ||||
10 | |||||
11 | int main() { | ||||
12 | A a; | ||||
13 | } |