diff options
author | John McCall <rjmccall@apple.com> | 2009-12-07 02:54:59 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2009-12-07 02:54:59 +0000 |
commit | a93c934af4fbf97cbe8e649d82e68ccacfe57c95 (patch) | |
tree | be955fa39337ec24a6853245d8114ef49ce93d70 /lib/Sema/SemaDeclAttr.cpp | |
parent | c08582ba5eef9383702fd3e434de1a6f2f470e3c (diff) |
DeclaratorInfo -> TypeSourceInfo. Makes an effort to rename associated variables,
but the results are imperfect.
For posterity, I did:
cat <<EOF > $cmdfile
s/DeclaratorInfo/TypeSourceInfo/g
s/DInfo/TInfo/g
s/TypeTypeSourceInfo/TypeSourceInfo/g
s/SourceTypeSourceInfo/TypeSourceInfo/g
EOF
find lib -name '*.cpp' -not -path 'lib/Parse/*' -exec sed -i '' -f $cmdfile '{}' \;
find lib -name '*.h' -exec sed -i '' -f $cmdfile '{}' \;
find include -name '*.h' -not -path 'include/clang/Parse/*' -not -path 'include/clang/Basic/*' -exec sed -i '' -f $cmdfile '{}' \;
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90743 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaDeclAttr.cpp')
-rw-r--r-- | lib/Sema/SemaDeclAttr.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/Sema/SemaDeclAttr.cpp b/lib/Sema/SemaDeclAttr.cpp index 2e641d9041..23dccdf62e 100644 --- a/lib/Sema/SemaDeclAttr.cpp +++ b/lib/Sema/SemaDeclAttr.cpp @@ -195,7 +195,7 @@ static void HandleExtVectorTypeAttr(Scope *scope, Decl *d, QualType T = S.BuildExtVectorType(curType, S.Owned(sizeExpr), Attr.getLoc()); if (!T.isNull()) { // FIXME: preserve the old source info. - tDecl->setTypeDeclaratorInfo(S.Context.getTrivialDeclaratorInfo(T)); + tDecl->setTypeSourceInfo(S.Context.getTrivialTypeSourceInfo(T)); // Remember this typedef decl, we will need it later for diagnostics. S.ExtVectorDecls.push_back(tDecl); @@ -1624,7 +1624,7 @@ static void HandleModeAttr(Decl *D, const AttributeList &Attr, Sema &S) { // Install the new type. if (TypedefDecl *TD = dyn_cast<TypedefDecl>(D)) { // FIXME: preserve existing source info. - TD->setTypeDeclaratorInfo(S.Context.getTrivialDeclaratorInfo(NewTy)); + TD->setTypeSourceInfo(S.Context.getTrivialTypeSourceInfo(NewTy)); } else cast<ValueDecl>(D)->setType(NewTy); } @@ -1977,11 +1977,11 @@ NamedDecl * Sema::DeclClonePragmaWeak(NamedDecl *ND, IdentifierInfo *II) { if (FunctionDecl *FD = dyn_cast<FunctionDecl>(ND)) { NewD = FunctionDecl::Create(FD->getASTContext(), FD->getDeclContext(), FD->getLocation(), DeclarationName(II), - FD->getType(), FD->getDeclaratorInfo()); + FD->getType(), FD->getTypeSourceInfo()); } else if (VarDecl *VD = dyn_cast<VarDecl>(ND)) { NewD = VarDecl::Create(VD->getASTContext(), VD->getDeclContext(), VD->getLocation(), II, - VD->getType(), VD->getDeclaratorInfo(), + VD->getType(), VD->getTypeSourceInfo(), VD->getStorageClass()); } return NewD; |