elementtype.c revision 65d39251ff57b8e33cf6d3a7fcc6aa1c6f8cdc68
1// RUN: %clang_cc1 -analyze -analyzer-checker=core.experimental -analyzer-check-objc-mem -analyzer-store=region %s
2
3typedef struct added_obj_st {
4  int type;
5} ADDED_OBJ;
6
7// Test if we are using the canonical type for ElementRegion.
8void f() {
9  ADDED_OBJ *ao[4]={((void*)0),((void*)0),((void*)0),((void*)0)};
10  if (ao[0] != ((void*)0))   {
11    ao[0]->type=0;
12  }
13}
14