NullResolver.h 1.2 KB

123456789101112131415161718192021222324252627282930313233343536
  1. //===------ NullResolver.h - Reject symbol lookup requests ------*- C++ -*-===//
  2. //
  3. // The LLVM Compiler Infrastructure
  4. //
  5. // This file is distributed under the University of Illinois Open Source
  6. // License. See LICENSE.TXT for details.
  7. //
  8. //===----------------------------------------------------------------------===//
  9. //
  10. // Defines a RuntimeDyld::SymbolResolver subclass that rejects all symbol
  11. // resolution requests, for clients that have no cross-object fixups.
  12. //
  13. //===----------------------------------------------------------------------===//
  14. #ifndef LLVM_EXECUTIONENGINE_ORC_NULLRESOLVER_H
  15. #define LLVM_EXECUTIONENGINE_ORC_NULLRESOLVER_H
  16. #include "llvm/ExecutionEngine/RuntimeDyld.h"
  17. namespace llvm {
  18. namespace orc {
  19. /// SymbolResolver impliementation that rejects all resolution requests.
  20. /// Useful for clients that have no cross-object fixups.
  21. class NullResolver : public RuntimeDyld::SymbolResolver {
  22. public:
  23. RuntimeDyld::SymbolInfo findSymbol(const std::string &Name) final;
  24. RuntimeDyld::SymbolInfo
  25. findSymbolInLogicalDylib(const std::string &Name) final;
  26. };
  27. } // End namespace orc.
  28. } // End namespace llvm.
  29. #endif // LLVM_EXECUTIONENGINE_ORC_NULLRESOLVER_H