You've already forked linux-packaging-mono
Imported Upstream version 5.18.0.246
Former-commit-id: 0c7ce5b1a7851e13f22acfd379b7f9fb304e4833
This commit is contained in:
parent
a7724cd563
commit
279aa8f685
33
external/llvm/unittests/ExecutionEngine/Orc/LazyEmittingLayerTest.cpp
vendored
Normal file
33
external/llvm/unittests/ExecutionEngine/Orc/LazyEmittingLayerTest.cpp
vendored
Normal file
@ -0,0 +1,33 @@
|
||||
//===- LazyEmittingLayerTest.cpp - Unit tests for the lazy emitting layer -===//
|
||||
//
|
||||
// The LLVM Compiler Infrastructure
|
||||
//
|
||||
// This file is distributed under the University of Illinois Open Source
|
||||
// License. See LICENSE.TXT for details.
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
#include "llvm/ExecutionEngine/Orc/LazyEmittingLayer.h"
|
||||
#include "llvm/ExecutionEngine/RuntimeDyld.h"
|
||||
#include "gtest/gtest.h"
|
||||
|
||||
namespace {
|
||||
|
||||
struct MockBaseLayer {
|
||||
typedef int ModuleHandleT;
|
||||
ModuleHandleT addModule(
|
||||
std::shared_ptr<llvm::Module>,
|
||||
std::unique_ptr<llvm::RuntimeDyld::MemoryManager> MemMgr,
|
||||
std::unique_ptr<llvm::JITSymbolResolver> Resolver) {
|
||||
EXPECT_FALSE(MemMgr);
|
||||
return 42;
|
||||
}
|
||||
};
|
||||
|
||||
TEST(LazyEmittingLayerTest, Empty) {
|
||||
MockBaseLayer M;
|
||||
llvm::orc::LazyEmittingLayer<MockBaseLayer> L(M);
|
||||
cantFail(L.addModule(std::unique_ptr<llvm::Module>(), nullptr));
|
||||
}
|
||||
|
||||
}
|
Reference in New Issue
Block a user