Diagnose parameter names that shadow the names of inherited fields under -Wshadow...
authorAaron Ballman <aaron@aaronballman.com>
Fri, 2 Nov 2018 21:04:44 +0000 (21:04 +0000)
committerAaron Ballman <aaron@aaronballman.com>
Fri, 2 Nov 2018 21:04:44 +0000 (21:04 +0000)
commitb55cd69a675e0f1e3eba5677a76fc146b21c871f
treea1f12db0a3ec4fd2ee3bd9d9a82b400acdc5400e
parent17a7b49e959c5b95d56afca7e6fc8bdcfe2d0938
Diagnose parameter names that shadow the names of inherited fields under -Wshadow-field.

This addresses PR34120. Note, unlike GCC, we take into account the accessibility of the field when deciding whether to warn or not.

llvm-svn: 346041
clang/include/clang/Basic/DiagnosticSemaKinds.td
clang/include/clang/Sema/Sema.h
clang/lib/Sema/SemaDecl.cpp
clang/lib/Sema/SemaDeclCXX.cpp
clang/test/SemaCXX/warn-shadow.cpp