HomePhabricator

[analyzer] Don't look through casts when creating pointer temporaries.

Authored by jordan_rose on Feb 25 2013, 5:21 PM.

Description

[analyzer] Don't look through casts when creating pointer temporaries.

Normally, we need to look through derived-to-base casts when creating
temporary object regions (added in r175854). However, if the temporary
is a pointer (rather than a struct/class instance), we need to /preserve/
the base casts that have been applied.

This also ensures that we really do create a new temporary region when
we need to: MaterializeTemporaryExpr and lvalue CXXDefaultArgExprs.

Fixes PR15342, although the test case doesn't include the crash because
I couldn't isolate it.

llvm-svn: 176069

Details

Committed
jordan_roseFeb 25 2013, 5:21 PM
Parents
rGc948709cda56: [analyzer] StackAddrEscapeChecker: strip qualifiers from temporary types.
Branches
Unknown
Tags
Unknown