From 3545ff43f41ac1f2208c3a7fefcc87ddb8bdf360 Mon Sep 17 00:00:00 2001 From: Douglas Gregor Date: Mon, 21 Sep 2009 16:56:56 +0000 Subject: Refactor and simplify the CodeCompleteConsumer, so that all of the real work is performed within Sema. Addresses Chris's comments, but still retains the heavyweight list-of-multimaps data structure. llvm-svn: 82459 --- clang/lib/Sema/ParseAST.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'clang/lib/Sema/ParseAST.cpp') diff --git a/clang/lib/Sema/ParseAST.cpp b/clang/lib/Sema/ParseAST.cpp index be19b7e3d98..d09af0a450d 100644 --- a/clang/lib/Sema/ParseAST.cpp +++ b/clang/lib/Sema/ParseAST.cpp @@ -64,8 +64,10 @@ void clang::ParseAST(Preprocessor &PP, ASTConsumer *Consumer, } CodeCompleteConsumer *CodeCompleter = 0; - if (CreateCodeCompleter) + if (CreateCodeCompleter) { CodeCompleter = CreateCodeCompleter(S, CreateCodeCompleterData); + S.setCodeCompleteConsumer(CodeCompleter); + } Parser::DeclGroupPtrTy ADecl; -- cgit v1.2.3