diff options
| author | Ted Kremenek <kremenek@apple.com> | 2009-12-23 01:19:20 +0000 |
|---|---|---|
| committer | Ted Kremenek <kremenek@apple.com> | 2009-12-23 01:19:20 +0000 |
| commit | 343b51271d3cf7a32a0897766e5bf0e0a09484d1 (patch) | |
| tree | 7f4425ba9a775412af506ba190702191e45636e3 /clang/test/Analysis | |
| parent | 1f76b51d3fa553c49f76c536f5307b495f2b7189 (diff) | |
| download | bcm5719-llvm-343b51271d3cf7a32a0897766e5bf0e0a09484d1.tar.gz bcm5719-llvm-343b51271d3cf7a32a0897766e5bf0e0a09484d1.zip | |
Also treat the type of the subexpression as a pointer in GRExprEngine::VisitCast when the expression is handled as an lvalue.
llvm-svn: 91969
Diffstat (limited to 'clang/test/Analysis')
| -rw-r--r-- | clang/test/Analysis/misc-ps-region-store.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/clang/test/Analysis/misc-ps-region-store.cpp b/clang/test/Analysis/misc-ps-region-store.cpp index e1750139c2f..be150c92cc3 100644 --- a/clang/test/Analysis/misc-ps-region-store.cpp +++ b/clang/test/Analysis/misc-ps-region-store.cpp @@ -23,3 +23,14 @@ int test2_b_aux(const short &n); int test2_b(int n) { return test2_b_aux(n); } + +// Test getting the lvalue of a derived and converting it to a base. This +// previously crashed. +class Test3_Base {}; +class Test3_Derived : public Test3_Base {}; + +int test3_aux(Test3_Base &x); +int test3(Test3_Derived x) { + return test3_aux(x); +} + |

