diff --git a/lldb/source/Expression/REPL.cpp b/lldb/source/Expression/REPL.cpp index a60780b9c3bdb8..751fdb9665d950 100644 --- a/lldb/source/Expression/REPL.cpp +++ b/lldb/source/Expression/REPL.cpp @@ -475,7 +475,7 @@ void REPL::IOHandlerComplete(IOHandler &io_handler, // Strip spaces from the line and see if we had only spaces if (request.GetRawLineUntilCursor().trim().empty()) { // Only spaces on this line, so just indent - request.AddCompletion(m_indent_str); + request.AddCompletion(m_indent_str, "", CompletionMode::Partial); return; } diff --git a/lldb/source/Plugins/ExpressionParser/Swift/SwiftREPL.cpp b/lldb/source/Plugins/ExpressionParser/Swift/SwiftREPL.cpp index f6634f2baebd22..ae2db25cfc6b7c 100644 --- a/lldb/source/Plugins/ExpressionParser/Swift/SwiftREPL.cpp +++ b/lldb/source/Plugins/ExpressionParser/Swift/SwiftREPL.cpp @@ -553,10 +553,6 @@ int SwiftREPL::CompleteCode(const std::string ¤t_code, llvm::dyn_cast_or_null(&*type_system_or_err); if (target_swift_ast) m_swift_ast_sp.reset(new SwiftASTContext(*target_swift_ast)); - auto &ctx = *m_swift_ast_sp.get()->GetASTContext(); - swift::registerIDERequestFunctions(ctx.evaluator); - swift::registerTypeCheckerRequestFunctions(ctx.evaluator); - swift::createTypeChecker(ctx); } SwiftASTContext *swift_ast = m_swift_ast_sp.get(); diff --git a/lldb/source/Symbol/SwiftASTContext.cpp b/lldb/source/Symbol/SwiftASTContext.cpp index f4ceb3a3193c70..b5b611a44f0cd4 100644 --- a/lldb/source/Symbol/SwiftASTContext.cpp +++ b/lldb/source/Symbol/SwiftASTContext.cpp @@ -3467,6 +3467,7 @@ swift::ASTContext *SwiftASTContext::GetASTContext() { // Set up the required state for the evaluator in the TypeChecker. (void)swift::createTypeChecker(*m_ast_context_ap); + registerIDERequestFunctions(m_ast_context_ap->evaluator); registerParseRequestFunctions(m_ast_context_ap->evaluator); registerTypeCheckerRequestFunctions(m_ast_context_ap->evaluator);