[PATCH] D84858: [llvm-libtool-darwin] Refactor ArchiveWriter

Shoaib Meenai via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 10 19:44:43 PDT 2020


smeenai accepted this revision.
smeenai added a comment.

Looks great!



================
Comment at: llvm/lib/Object/ArchiveWriter.cpp:639
+                                     Deterministic, Thin))
+    return E;
 
----------------
I believe you need to explicitly call `Temp->discard()` in this path, otherwise you'll trip [this assert](https://github.com/llvm/llvm-project/blob/4aaa97700377a811dbcaf88a81ec068a5b517a4d/llvm/lib/Support/Path.cpp#L1171). Note that `discard()` itself can return an error, in which case you probably want to do `joinErrors`?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D84858



More information about the llvm-commits mailing list