[examples] Fix incomplete_type on ZLinux when compiling RemoteJITUtils.

When compiling on ZLinux, we got this error:

/llvm-project/llvm/examples/OrcV2Examples/LLJITWithRemoteDebugging/ \
RemoteJITUtils.h:80:65:   required from here...
/usr/include/c++/7/bits/unique_ptr.h:76:22: error: invalid application of
'sizeof' to incomplete type 'llvm::orc::RemoteExecutorProcessControl'
  static_assert(sizeof(_Tp)>0,

This patch just removes nullptr from the initialization of
std::unique_ptr<RemoteExecutorProcessControl> to avoid the issue.

Patch by Tung D. Le (tung@jp.ibm.com). Thanks Tung!

Reviewed By: lhames

Differential Revision: https://reviews.llvm.org/D107247
This commit is contained in:
Lang Hames 2021-08-02 15:15:15 +10:00
parent a441de6d94
commit 07a5b7e5b1
1 changed files with 1 additions and 1 deletions

View File

@ -77,7 +77,7 @@ public:
virtual ~JITLinkExecutor();
protected:
std::unique_ptr<RemoteExecutorProcessControl> OwnedEPC{nullptr};
std::unique_ptr<RemoteExecutorProcessControl> OwnedEPC;
RemoteExecutorProcessControl *EPC{nullptr};
JITLinkExecutor();