blob: b0c2db438629a8129bcfa9b6375ef17ff8dd1a71 [file] [log] [blame]
Daniel Dunbard4270232009-01-20 23:17:32 +00001// RUN: clang -analyze -checker-simple -analyzer-store-region -verify %s
Zhongxing Xu20f01782008-11-24 02:19:49 +00002
3char f1() {
4 char* s = "abcd";
Ted Kremeneka7ac9442009-01-22 20:27:48 +00005 return s[6]; // expected-warning{{Load or store into an out-of-bound memory position.}}
Zhongxing Xu20f01782008-11-24 02:19:49 +00006}