[PATCH] D24176: Remove temoprary files.

Rui Ueyama via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 2 09:47:14 PDT 2016


ruiu added a comment.

I think TemporaryFile class is well exercised by existing lit tests, but I can add a unit test if you want.


================
Comment at: COFF/DriverUtils.cpp:286
@@ +285,3 @@
+public:
+  TemporaryFile(StringRef Prefix, StringRef Extn) {
+    SmallString<128> S;
----------------
I forgot to remove it when I added the second parameter. Removed.

================
Comment at: COFF/DriverUtils.cpp:300
@@ +299,3 @@
+      return;
+    if (sys::fs::remove(Path))
+      fatal("failed to remove " + Path);
----------------
I think the right thing to do here is to check the return value of remove(), so did I.


https://reviews.llvm.org/D24176





More information about the llvm-commits mailing list