summaryrefslogtreecommitdiffstats
path: root/clang/lib/Parse/ParseDecl.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2010-01-13 21:24:21 +0000
committerDouglas Gregor <dgregor@apple.com>2010-01-13 21:24:21 +0000
commitf193416359009ebb6a9a4c197f42519b9b25f015 (patch)
tree3357111214e36dad605018d65562ee72a9b0b768 /clang/lib/Parse/ParseDecl.cpp
parent6f0bf8262231388a9fdcfed33ae3f470ba458d89 (diff)
downloadbcm5719-llvm-f193416359009ebb6a9a4c197f42519b9b25f015.tar.gz
bcm5719-llvm-f193416359009ebb6a9a4c197f42519b9b25f015.zip
Whenever completing ordinary names for an Objective-C source, also
provide completions for @ keywords. Previously, we only provided @-completions after an @ was actually typed, which is useful but probably not the common case. Also, make sure a few Objective-C 2.0 completions only show up when Objective-C 2.0 support is enabled (the default). llvm-svn: 93354
Diffstat (limited to 'clang/lib/Parse/ParseDecl.cpp')
-rw-r--r--clang/lib/Parse/ParseDecl.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/clang/lib/Parse/ParseDecl.cpp b/clang/lib/Parse/ParseDecl.cpp
index 66a69574433..b5ba8acafc8 100644
--- a/clang/lib/Parse/ParseDecl.cpp
+++ b/clang/lib/Parse/ParseDecl.cpp
@@ -835,7 +835,9 @@ void Parser::ParseDeclarationSpecifiers(DeclSpec &DS,
: Action::CCC_Template;
else if (DSContext == DSC_class)
CCC = Action::CCC_Class;
-
+ else if (ObjCImpDecl)
+ CCC = Action::CCC_ObjCImplementation;
+
Actions.CodeCompleteOrdinaryName(CurScope, CCC);
ConsumeToken();
}
OpenPOWER on IntegriCloud