Revert "Maybe add new warning for shadowing simple tag types"
This reverts commit 2b43f500cfea10a8c59c986dcfc24fd08eecc77d.
This was accidentally committed because I failed to notice my client
wasn't clean prior to submitting a fix for a crasher.
llvm-svn: 197410
diff --git a/clang/lib/Sema/SemaDecl.cpp b/clang/lib/Sema/SemaDecl.cpp
index c4325c6..6eb8955 100644
--- a/clang/lib/Sema/SemaDecl.cpp
+++ b/clang/lib/Sema/SemaDecl.cpp
@@ -4398,14 +4398,8 @@
// tag type. Note that this does does not apply if we're declaring a
// typedef (C++ [dcl.typedef]p4).
if (Previous.isSingleTagDecl() &&
- D.getDeclSpec().getStorageClassSpec() != DeclSpec::SCS_typedef) {
- TagDecl *TD = Previous.getAsSingle<TagDecl>();
- Diag(D.getIdentifierLoc(), diag::warn_declaration_shadows_tag_type)
- << Name << TD->getKindName();
- Diag(TD->getLocation(), diag::note_shadowed_tag_type_declaration)
- << Name << TD->getKindName();
+ D.getDeclSpec().getStorageClassSpec() != DeclSpec::SCS_typedef)
Previous.clear();
- }
// Check that there are no default arguments other than in the parameters
// of a function declaration (C++ only).