]> granicus.if.org Git - clang/commit
[analyzer] Don't canonicalize the RecordDecl used in CXXBaseObjectRegion.
authorJordan Rose <jordan_rose@apple.com>
Fri, 22 Feb 2013 19:33:13 +0000 (19:33 +0000)
committerJordan Rose <jordan_rose@apple.com>
Fri, 22 Feb 2013 19:33:13 +0000 (19:33 +0000)
commitae7396c3891748762d01431e16541b3eb9125c4d
tree93129cef399c6865b1d692804cd767e26a652d52
parent4c67aa96401b67b5200e701cff87485067ab0792
[analyzer] Don't canonicalize the RecordDecl used in CXXBaseObjectRegion.

This Decl shouldn't be the canonical Decl; it should be the Decl used by
the CXXBaseSpecifier in the subclass. Unfortunately, that means continuing
to throw getCanonicalDecl() on all comparisons.

This fixes MemRegion::getAsOffset's use of ASTRecordLayout when redeclarations
are involved.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@175913 91177308-0d34-0410-b5e6-96231b3b80d8
lib/StaticAnalyzer/Core/MemRegion.cpp
test/Analysis/derived-to-base.cpp