[libcxx-commits] [PATCH] D97456: [libcxx] [test] Fix the get_temp_file_name() function for mingw

Martin Storsjö via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Thu Feb 25 04:50:14 PST 2021


mstorsjo updated this revision to Diff 326361.
mstorsjo edited the summary of this revision.
mstorsjo added a comment.

Removed the superfluous `defined(__MINGW32__)`.


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

https://reviews.llvm.org/D97456

Files:
  libcxx/test/support/platform_support.h


Index: libcxx/test/support/platform_support.h
===================================================================
--- libcxx/test/support/platform_support.h
+++ libcxx/test/support/platform_support.h
@@ -56,8 +56,10 @@
 #include <codecvt>
 #include <locale>
 #include <string>
-#if defined(_WIN32) || defined(__MINGW32__)
+#if defined(_WIN32)
+#   define WIN32_LEAN_AND_MEAN // Reduce overhead of including windows.h
 #   include <io.h> // _mktemp_s
+#   include <windows.h> // MAX_PATH, GetTempPath, GetTempFileName
 #else
 #   include <unistd.h> // close
 #endif


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D97456.326361.patch
Type: text/x-patch
Size: 565 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20210225/12c6965c/attachment-0001.bin>


More information about the libcxx-commits mailing list