[libcxx] r337886 - Fix missing includes in format_string.hpp helper

Eric Fiselier via cfe-commits cfe-commits at lists.llvm.org
Tue Jul 24 21:21:59 PDT 2018


Author: ericwf
Date: Tue Jul 24 21:21:59 2018
New Revision: 337886

URL: http://llvm.org/viewvc/llvm-project?rev=337886&view=rev
Log:
Fix missing includes in format_string.hpp helper

Modified:
    libcxx/trunk/test/support/format_string.hpp

Modified: libcxx/trunk/test/support/format_string.hpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/support/format_string.hpp?rev=337886&r1=337885&r2=337886&view=diff
==============================================================================
--- libcxx/trunk/test/support/format_string.hpp (original)
+++ libcxx/trunk/test/support/format_string.hpp Tue Jul 24 21:21:59 2018
@@ -5,23 +5,24 @@
 #include <string>
 #include <memory>
 #include <array>
+#include <cstdarg>
 
 namespace format_string_detail {
 inline std::string format_string_imp(const char* msg, ...) {
   // we might need a second shot at this, so pre-emptivly make a copy
   struct GuardVAList {
-    va_list& target;
+    va_list& xtarget;
     bool active;
-    GuardVAList(va_list& target) : target(target), active(true) {}
+    GuardVAList(va_list& val) : xtarget(val), active(true) {}
 
     void clear() {
       if (active)
-        va_end(target);
+        va_end(xtarget);
       active = false;
     }
     ~GuardVAList() {
       if (active)
-        va_end(target);
+        va_end(xtarget);
     }
   };
   va_list args;




More information about the cfe-commits mailing list