]> granicus.if.org Git - clang/commit
Sema: Don't dyn_cast a null pointer in CheckUsingDeclQualifier
authorDavid Majnemer <david.majnemer@gmail.com>
Wed, 17 Dec 2014 02:41:36 +0000 (02:41 +0000)
committerDavid Majnemer <david.majnemer@gmail.com>
Wed, 17 Dec 2014 02:41:36 +0000 (02:41 +0000)
commit65c422ad3f0e74a95af524bab4bd98eb10615025
treee1a7f870f50752ac56567324be8c8ca772514a48
parenteadec62aaac4c96da5d94e6cfdbeafc5f83f5171
Sema: Don't dyn_cast a null pointer in CheckUsingDeclQualifier

This code was written with the intent that a pointer could be null but
we dyn_cast'd it anyway.  Change the dyn_cast to a dyn_cast_or_null.

This fixes PR21933.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@224411 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Sema/SemaDeclCXX.cpp
test/CXX/dcl.dcl/basic.namespace/namespace.udecl/p8-cxx0x.cpp