summaryrefslogtreecommitdiffstats
path: root/clang/lib/AST
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2009-03-14 00:27:40 +0000
committerTed Kremenek <kremenek@apple.com>2009-03-14 00:27:40 +0000
commitd0fa573a7d544939a0584d61c2df30811a77eb5a (patch)
tree967e71875ba5c229e010ef7eb54c0eb26696bab4 /clang/lib/AST
parent5bbe1d7ba74ed004b5f297185bf8f08e313b0c58 (diff)
downloadbcm5719-llvm-d0fa573a7d544939a0584d61c2df30811a77eb5a.tar.gz
bcm5719-llvm-d0fa573a7d544939a0584d61c2df30811a77eb5a.zip
Remove dead DeclarationName constructors that involving knowing about the
internal implementation of Selector. llvm-svn: 66996
Diffstat (limited to 'clang/lib/AST')
-rw-r--r--clang/lib/AST/DeclarationName.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/clang/lib/AST/DeclarationName.cpp b/clang/lib/AST/DeclarationName.cpp
index c1077c189b6..3815a08a652 100644
--- a/clang/lib/AST/DeclarationName.cpp
+++ b/clang/lib/AST/DeclarationName.cpp
@@ -63,16 +63,19 @@ DeclarationName::DeclarationName(Selector Sel) {
switch (Sel.getNumArgs()) {
case 0:
Ptr = reinterpret_cast<uintptr_t>(Sel.getAsIdentifierInfo());
+ assert((Ptr & PtrMask) == 0 && "Improperly aligned IdentifierInfo");
Ptr |= StoredObjCZeroArgSelector;
break;
case 1:
Ptr = reinterpret_cast<uintptr_t>(Sel.getAsIdentifierInfo());
+ assert((Ptr & PtrMask) == 0 && "Improperly aligned IdentifierInfo");
Ptr |= StoredObjCOneArgSelector;
break;
default:
Ptr = Sel.InfoPtr & ~Selector::ArgFlags;
+ assert((Ptr & PtrMask) == 0 && "Improperly aligned MultiKeywordSelector");
Ptr |= StoredDeclarationNameExtra;
break;
}
OpenPOWER on IntegriCloud