aboutsummaryrefslogtreecommitdiff
path: root/test/Analysis/lvalue.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'test/Analysis/lvalue.cpp')
-rw-r--r--test/Analysis/lvalue.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/Analysis/lvalue.cpp b/test/Analysis/lvalue.cpp
new file mode 100644
index 000000000000..f19c59d9d258
--- /dev/null
+++ b/test/Analysis/lvalue.cpp
@@ -0,0 +1,6 @@
+// RUN: %clang_cc1 -analyze -analyzer-check-objc-mem -analyzer-store=region -verify %s
+
+int f1() {
+ int x = 0, y = 1;
+ return x += y; // Should bind a location to 'x += y'. No crash.
+}