diff options
author | Douglas Gregor <dgregor@apple.com> | 2009-05-03 17:18:57 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2009-05-03 17:18:57 +0000 |
commit | f9aa5260a97b1e9b9f6e65a0c6a0c4d1e51996e0 (patch) | |
tree | a86fe4670a360b171ad344623876aaccdcc9315e /clang/lib/Sema/SemaDecl.cpp | |
parent | 4c78596182f50b693cb3fff80a42deab7a46ba9e (diff) | |
download | bcm5719-llvm-f9aa5260a97b1e9b9f6e65a0c6a0c4d1e51996e0.tar.gz bcm5719-llvm-f9aa5260a97b1e9b9f6e65a0c6a0c4d1e51996e0.zip |
One can use "class" and "struct" interchangeably to refer to a class
in C++. Fixes <rdar://problem/6815995>.
llvm-svn: 70784
Diffstat (limited to 'clang/lib/Sema/SemaDecl.cpp')
-rw-r--r-- | clang/lib/Sema/SemaDecl.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Sema/SemaDecl.cpp b/clang/lib/Sema/SemaDecl.cpp index 9647740b14c..69989b131df 100644 --- a/clang/lib/Sema/SemaDecl.cpp +++ b/clang/lib/Sema/SemaDecl.cpp @@ -3295,7 +3295,7 @@ Sema::DeclPtrTy Sema::ActOnTag(Scope *S, unsigned TagSpec, TagKind TK, if (TK == TK_Reference || isDeclInScope(PrevDecl, SearchDC, S)) { // Make sure that this wasn't declared as an enum and now used as a // struct or something similar. - if (PrevTagDecl->getTagKind() != Kind) { + if (!isAcceptableTagRedeclaration(PrevTagDecl->getTagKind(), Kind)) { bool SafeToContinue = (PrevTagDecl->getTagKind() != TagDecl::TK_enum && Kind != TagDecl::TK_enum); |