summaryrefslogtreecommitdiffstats
path: root/clang/Sema/SemaDecl.cpp
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2008-02-27 22:18:07 +0000
committerTed Kremenek <kremenek@apple.com>2008-02-27 22:18:07 +0000
commit49b61ab6bd8170e34c482f61fe4fe9d905fbef44 (patch)
tree9eb3f7038f8aa1c91c2bc1957baca4ea4056a4c7 /clang/Sema/SemaDecl.cpp
parent26854f242ecc308439873582396d329959cc756f (diff)
downloadbcm5719-llvm-49b61ab6bd8170e34c482f61fe4fe9d905fbef44.tar.gz
bcm5719-llvm-49b61ab6bd8170e34c482f61fe4fe9d905fbef44.zip
Added parsing of attributes for functions.
llvm-svn: 47693
Diffstat (limited to 'clang/Sema/SemaDecl.cpp')
-rw-r--r--clang/Sema/SemaDecl.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/clang/Sema/SemaDecl.cpp b/clang/Sema/SemaDecl.cpp
index e841787a58d..df6dd5c2e18 100644
--- a/clang/Sema/SemaDecl.cpp
+++ b/clang/Sema/SemaDecl.cpp
@@ -732,8 +732,10 @@ Sema::ActOnDeclarator(Scope *S, Declarator &D, DeclTy *lastDecl) {
FunctionDecl *NewFD = new FunctionDecl(D.getIdentifierLoc(), II, R, SC,
D.getDeclSpec().isInlineSpecified(),
LastDeclarator);
- // FIXME: Handle attributes: should delete anything left.
- D.getDeclSpec().SetAttributes(0);
+ // Handle attributes.
+
+ HandleDeclAttributes(NewFD, D.getDeclSpec().getAttributes(),
+ D.getAttributes());
// Merge the decl with the existing one if appropriate. Since C functions
// are in a flat namespace, make sure we consider decls in outer scopes.
OpenPOWER on IntegriCloud