From f9e96843e8a0afd0d5f58ba224fb8d57cba8effa Mon Sep 17 00:00:00 2001 From: Ted Kremenek Date: Thu, 22 Jan 2009 20:36:33 +0000 Subject: [PATCH] Test more array logic in outofbound.c git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62782 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/Analysis/outofbound.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/Analysis/outofbound.c b/test/Analysis/outofbound.c index b0c2db4386..e496425eb9 100644 --- a/test/Analysis/outofbound.c +++ b/test/Analysis/outofbound.c @@ -2,5 +2,6 @@ char f1() { char* s = "abcd"; - return s[6]; // expected-warning{{Load or store into an out-of-bound memory position.}} + char c = s[4]; // no-warning + return s[5] + c; // expected-warning{{Load or store into an out-of-bound memory position.}} } -- 2.50.1