[PATCH] D124643: [Object][DX] Initial DXContainer parsing support

Dan Liew via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon May 2 16:31:23 PDT 2022


delcypher added a comment.

In D124643#3486838 <https://reviews.llvm.org/D124643#3486838>, @nemanjai wrote:

> In D124643#3486603 <https://reviews.llvm.org/D124643#3486603>, @beanz wrote:
>
>> Bots should be fixed with rG55e13a6bc0d6a31afc258a012184253041b0eb8e <https://reviews.llvm.org/rG55e13a6bc0d6a31afc258a012184253041b0eb8e>.
>
> This isn't the only problem. There are also failures due to:
>
>   llvm-project/llvm/lib/Object/DXContainer.cpp:42:12: error: call to deleted constructor of 'llvm::Error'
>       return Err;
>              ^~~
>
> See https://lab.llvm.org/buildbot/#/builders/21/builds/40034/steps/5/logs/stdio

@beanz

I'm also seeing this build error when we try to merge this change into Apple's llvm-project fork.

  /am_github_build_tester/llvm-project/llvm/lib/Object/DXContainer.cpp:42:12: error: call to deleted constructor of 'llvm::Error'
      return Err;
             ^~~
  /am_github_build_tester/llvm-project/llvm/include/llvm/Support/Error.h:184:3: note: 'Error' has been explicitly marked deleted here
    Error(const Error &Other) = delete;
    ^
  /am_github_build_tester/llvm-project/llvm/include/llvm/Support/Error.h:491:18: note: passing argument to parameter 'Err' here
    Expected(Error Err)
                   ^
  1 error generated.

Could you take a look? It looks like the copy constructor and assignment operator are deliberately deleted. However the move constructor and move assignment operator are implemented so I'm guessing you might be able to do

  if (Error Err = Container.parseHeader())
     return std::move(Err);

I'm a little surprised by this error though because the pattern you're using is what's in the `llvm:Error` documentation: https://llvm.org/doxygen/classllvm_1_1Error.html . It kind of suggests those comments are out-of-date.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D124643/new/

https://reviews.llvm.org/D124643



More information about the llvm-commits mailing list