mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-31 20:51:52 +01:00
[ORC] Fix the type of RTDyldObjectLinkingLayer::NotifyLoadedFtor.
Bug found by Stefan Granitz. Thanks Stefan! llvm-svn: 314436
This commit is contained in:
parent
aac52b0c56
commit
fdd0433d80
@ -99,8 +99,9 @@ public:
|
||||
using RTDyldObjectLinkingLayerBase::ObjectPtr;
|
||||
|
||||
/// @brief Functor for receiving object-loaded notifications.
|
||||
using NotifyLoadedFtor = std::function<void(ObjHandleT, const ObjectPtr &Obj,
|
||||
const LoadedObjectInfo &)>;
|
||||
using NotifyLoadedFtor =
|
||||
std::function<void(ObjHandleT, const ObjectPtr &Obj,
|
||||
const RuntimeDyld::LoadedObjectInfo &)>;
|
||||
|
||||
/// @brief Functor for receiving finalization notifications.
|
||||
using NotifyFinalizedFtor = std::function<void(ObjHandleT)>;
|
||||
|
@ -341,7 +341,7 @@ private:
|
||||
|
||||
void operator()(RTDyldObjectLinkingLayerBase::ObjHandleT H,
|
||||
const RTDyldObjectLinkingLayer::ObjectPtr &Obj,
|
||||
const LoadedObjectInfo &Info) const {
|
||||
const RuntimeDyld::LoadedObjectInfo &Info) const {
|
||||
M.UnfinalizedSections[H] = std::move(M.SectionsAllocatedSinceLastLoad);
|
||||
M.SectionsAllocatedSinceLastLoad = SectionAddrSet();
|
||||
M.MemMgr->notifyObjectLoaded(&M, *Obj->getBinary());
|
||||
|
@ -255,4 +255,12 @@ TEST_F(RTDyldObjectLinkingLayerExecutionTest, NoPrematureAllocation) {
|
||||
"(multiple unrelated objects loaded prior to finalization)";
|
||||
}
|
||||
|
||||
TEST_F(RTDyldObjectLinkingLayerExecutionTest, TestNotifyLoadedSignature) {
|
||||
RTDyldObjectLinkingLayer ObjLayer([]() { return nullptr; },
|
||||
[this](decltype(ObjLayer)::ObjHandleT,
|
||||
const decltype(ObjLayer)::ObjectPtr &obj,
|
||||
const RuntimeDyld::LoadedObjectInfo &info) {
|
||||
});
|
||||
}
|
||||
|
||||
} // end anonymous namespace
|
||||
|
Loading…
x
Reference in New Issue
Block a user