From 1b7dd8d7e375bf9389d1dda3deac131e01b74606 Mon Sep 17 00:00:00 2001 From: Benjamin Kramer Date: Tue, 20 Oct 2015 07:50:21 +0000 Subject: [PATCH] Put back dead code that's used out-of-tree. Partially reverts r250418. llvm-svn: 250803 --- clang/lib/CodeGen/CodeGenABITypes.cpp | 30 ++++++++++++++++++++++++++ clang/lib/Tooling/Core/CMakeLists.txt | 1 + clang/unittests/Tooling/CMakeLists.txt | 1 + 3 files changed, 32 insertions(+) diff --git a/clang/lib/CodeGen/CodeGenABITypes.cpp b/clang/lib/CodeGen/CodeGenABITypes.cpp index 022cbe70b3da..85495eeaedf0 100644 --- a/clang/lib/CodeGen/CodeGenABITypes.cpp +++ b/clang/lib/CodeGen/CodeGenABITypes.cpp @@ -36,3 +36,33 @@ CodeGenABITypes::CodeGenABITypes(ASTContext &C, llvm::Module &M, // Explicitly out-of-line because ~CodeGenModule() is private but // CodeGenABITypes.h is part of clang's API. CodeGenABITypes::~CodeGenABITypes() = default; + +const CGFunctionInfo & +CodeGenABITypes::arrangeObjCMessageSendSignature(const ObjCMethodDecl *MD, + QualType receiverType) { + return CGM->getTypes().arrangeObjCMessageSendSignature(MD, receiverType); +} + +const CGFunctionInfo & +CodeGenABITypes::arrangeFreeFunctionType(CanQual Ty) { + return CGM->getTypes().arrangeFreeFunctionType(Ty); +} + +const CGFunctionInfo & +CodeGenABITypes::arrangeFreeFunctionType(CanQual Ty) { + return CGM->getTypes().arrangeFreeFunctionType(Ty); +} + +const CGFunctionInfo & +CodeGenABITypes::arrangeCXXMethodType(const CXXRecordDecl *RD, + const FunctionProtoType *FTP) { + return CGM->getTypes().arrangeCXXMethodType(RD, FTP); +} + +const CGFunctionInfo &CodeGenABITypes::arrangeFreeFunctionCall( + CanQualType returnType, ArrayRef argTypes, + FunctionType::ExtInfo info, RequiredArgs args) { + return CGM->getTypes().arrangeLLVMFunctionInfo( + returnType, /*IsInstanceMethod=*/false, /*IsChainCall=*/false, argTypes, + info, args); +} diff --git a/clang/lib/Tooling/Core/CMakeLists.txt b/clang/lib/Tooling/Core/CMakeLists.txt index c8c75f95f3cb..d89b2e4578e3 100644 --- a/clang/lib/Tooling/Core/CMakeLists.txt +++ b/clang/lib/Tooling/Core/CMakeLists.txt @@ -1,6 +1,7 @@ set(LLVM_LINK_COMPONENTS support) add_clang_library(clangToolingCore + Lookup.cpp Replacement.cpp LINK_LIBS diff --git a/clang/unittests/Tooling/CMakeLists.txt b/clang/unittests/Tooling/CMakeLists.txt index 2ae3a3e31ed1..33b2046ae928 100644 --- a/clang/unittests/Tooling/CMakeLists.txt +++ b/clang/unittests/Tooling/CMakeLists.txt @@ -6,6 +6,7 @@ set(LLVM_LINK_COMPONENTS add_clang_unittest(ToolingTests CommentHandlerTest.cpp CompilationDatabaseTest.cpp + LookupTest.cpp ToolingTest.cpp RecursiveASTVisitorTest.cpp RecursiveASTVisitorTestCallVisitor.cpp