[cfe-commits] [libcxx] r134947 - /libcxx/trunk/include/locale

Sean Hunt scshunt at csclub.uwaterloo.ca
Mon Jul 11 17:55:04 PDT 2011


Author: coppro
Date: Mon Jul 11 19:55:04 2011
New Revision: 134947

URL: http://llvm.org/viewvc/llvm-project?rev=134947&view=rev
Log:
Make sure that __time_put constructors properly on non-Apple platforms.

Modified:
    libcxx/trunk/include/locale

Modified: libcxx/trunk/include/locale
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/include/locale?rev=134947&r1=134946&r2=134947&view=diff
==============================================================================
--- libcxx/trunk/include/locale (original)
+++ libcxx/trunk/include/locale Mon Jul 11 19:55:04 2011
@@ -2516,7 +2516,11 @@
 {
     locale_t __loc_;
 protected:
+#ifdef _LIBCPP_STABLE_APPLE_ABI
     _LIBCPP_ALWAYS_INLINE __time_put() : __loc_(0) {}
+#else   // _LIBCPP_STABLE_APPLE_ABI
+    _LIBCPP_ALWAYS_INLINE __time_put() : __loc_(__cloc()) {}
+#endif  // _LIBCPP_STABLE_APPLE_ABI
     __time_put(const char* __nm);
     __time_put(const string& __nm);
     ~__time_put();





More information about the cfe-commits mailing list