blob: 2a39c66fcb1b60acd686efeb400d5ac54df13aae [file] [log] [blame]
Jordan Roseee049592012-08-21 21:44:07 +00001// RUN: %clang_cc1 -analyze -analyzer-checker=core -verify %s
Zhongxing Xu15f6b422010-03-02 10:08:30 +00002
3// Test parameter 'a' is registered to LiveVariables analysis data although it
4// is not referenced in the function body.
Zhongxing Xu97ccfa52010-03-03 01:02:48 +00005// Before processing 'return 1;', in RemoveDeadBindings(), we query the liveness
6// of 'a', because we have a binding for it due to parameter passing.
Zhongxing Xu15f6b422010-03-02 10:08:30 +00007int f1(int a) {
8 return 1;
9}
10
11void f2() {
12 int x;
13 x = f1(1);
14}