]> granicus.if.org Git - clang/commit
Fix -Wdynamic-class-memaccess to skip invalid classes.
authorRichard Trieu <rtrieu@google.com>
Thu, 31 Mar 2016 04:18:07 +0000 (04:18 +0000)
committerRichard Trieu <rtrieu@google.com>
Thu, 31 Mar 2016 04:18:07 +0000 (04:18 +0000)
commitbb39104647b6bc81ba627642f31c4487eeb59e8e
tree85410fdf24987a21037322a69dc1589ae53f98d3
parentd157ba2e23a3f4e11bdc272ed111417fc40ffc1c
Fix -Wdynamic-class-memaccess to skip invalid classes.

This warning sometimes will infinitely recurse on CXXRecordDecl's from
ill-formed recursive classes that have fields of themselves.  Skip processing
these classes to prevent this from happening.
Fixes https://llvm.org/bugs/show_bug.cgi?id=27142

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@264991 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Sema/SemaChecking.cpp
test/SemaCXX/warn-bad-memaccess.cpp