Files
clang-p2996/llvm/lib/ExecutionEngine/Orc/NullResolver.cpp
Lang Hames d4df0f1733 [ORC] Simplify VSO::lookupFlags to return the flags map.
This discards the unresolved symbols set and returns the flags map directly
(rather than mutating it via the first argument).

The unresolved symbols result made it easy to chain lookupFlags calls, but such
chaining should be rare to non-existant (especially now that symbol resolvers
are being deprecated) so the simpler method signature is preferable.

llvm-svn: 337594
2018-07-20 18:31:52 +00:00

39 lines
1.1 KiB
C++

//===---------- NullResolver.cpp - Reject symbol lookup requests ----------===//
//
// 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/NullResolver.h"
#include "llvm/Support/ErrorHandling.h"
namespace llvm {
namespace orc {
SymbolFlagsMap NullResolver::lookupFlags(const SymbolNameSet &Symbols) {
return SymbolFlagsMap();
}
SymbolNameSet
NullResolver::lookup(std::shared_ptr<AsynchronousSymbolQuery> Query,
SymbolNameSet Symbols) {
assert(Symbols.empty() && "Null resolver: Symbols must be empty");
return Symbols;
}
JITSymbol NullLegacyResolver::findSymbol(const std::string &Name) {
llvm_unreachable("Unexpected cross-object symbol reference");
}
JITSymbol
NullLegacyResolver::findSymbolInLogicalDylib(const std::string &Name) {
llvm_unreachable("Unexpected cross-object symbol reference");
}
} // End namespace orc.
} // End namespace llvm.