forked from OSchip/llvm-project
Add const qualifier for FunctionInfoIndex in ModuleLinker and linkInModule() (NFC)
From: Mehdi Amini <mehdi.amini@apple.com> llvm-svn: 253840
This commit is contained in:
parent
ededfce1b7
commit
8220e8a830
|
@ -82,7 +82,7 @@ public:
|
||||||
/// function is imported from the source module.
|
/// function is imported from the source module.
|
||||||
/// Returns true on error.
|
/// Returns true on error.
|
||||||
bool linkInModule(Module *Src, unsigned Flags = Flags::None,
|
bool linkInModule(Module *Src, unsigned Flags = Flags::None,
|
||||||
FunctionInfoIndex *Index = nullptr,
|
const FunctionInfoIndex *Index = nullptr,
|
||||||
Function *FuncToImport = nullptr);
|
Function *FuncToImport = nullptr);
|
||||||
|
|
||||||
/// \brief Set the composite to the passed-in module.
|
/// \brief Set the composite to the passed-in module.
|
||||||
|
|
|
@ -428,7 +428,7 @@ class ModuleLinker {
|
||||||
|
|
||||||
/// Function index passed into ModuleLinker for using in function
|
/// Function index passed into ModuleLinker for using in function
|
||||||
/// importing/exporting handling.
|
/// importing/exporting handling.
|
||||||
FunctionInfoIndex *ImportIndex;
|
const FunctionInfoIndex *ImportIndex;
|
||||||
|
|
||||||
/// Function to import from source module, all other functions are
|
/// Function to import from source module, all other functions are
|
||||||
/// imported as declarations instead of definitions.
|
/// imported as declarations instead of definitions.
|
||||||
|
@ -448,7 +448,7 @@ class ModuleLinker {
|
||||||
public:
|
public:
|
||||||
ModuleLinker(Module *dstM, Linker::IdentifiedStructTypeSet &Set, Module *srcM,
|
ModuleLinker(Module *dstM, Linker::IdentifiedStructTypeSet &Set, Module *srcM,
|
||||||
DiagnosticHandlerFunction DiagnosticHandler, unsigned Flags,
|
DiagnosticHandlerFunction DiagnosticHandler, unsigned Flags,
|
||||||
FunctionInfoIndex *Index = nullptr,
|
const FunctionInfoIndex *Index = nullptr,
|
||||||
Function *FuncToImport = nullptr)
|
Function *FuncToImport = nullptr)
|
||||||
: DstM(dstM), SrcM(srcM), TypeMap(Set),
|
: DstM(dstM), SrcM(srcM), TypeMap(Set),
|
||||||
ValMaterializer(TypeMap, DstM, LazilyLinkGlobalValues, this),
|
ValMaterializer(TypeMap, DstM, LazilyLinkGlobalValues, this),
|
||||||
|
@ -2088,7 +2088,8 @@ void Linker::deleteModule() {
|
||||||
Composite = nullptr;
|
Composite = nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Linker::linkInModule(Module *Src, unsigned Flags, FunctionInfoIndex *Index,
|
bool Linker::linkInModule(Module *Src, unsigned Flags,
|
||||||
|
const FunctionInfoIndex *Index,
|
||||||
Function *FuncToImport) {
|
Function *FuncToImport) {
|
||||||
ModuleLinker TheLinker(Composite, IdentifiedStructTypes, Src,
|
ModuleLinker TheLinker(Composite, IdentifiedStructTypes, Src,
|
||||||
DiagnosticHandler, Flags, Index, FuncToImport);
|
DiagnosticHandler, Flags, Index, FuncToImport);
|
||||||
|
|
Loading…
Reference in New Issue