components/gnump/patches/010-osmpf.cc.patch
author Stefan Teleman <stefan.teleman@oracle.com>
Mon, 09 May 2011 11:36:28 -0700
changeset 219 22d9e175d379
permissions -rw-r--r--
7041521 GNU MP to Userland 7041522 GNU MPFR to Userland 7041472 appending $(CFLAGS) to $(CXXFLAGS) is wrong and must be removed

--- cxx/osmpf.cc.orig	2007-09-01 03:09:03.000000000 -0700
+++ cxx/osmpf.cc	2008-04-18 10:08:31.565184503 -0700
@@ -19,15 +19,14 @@
 
 #include <clocale>
 #include <iostream>
+using namespace std;
+
 #include <stdarg.h>    /* for va_list and hence doprnt_funs_t */
 #include <string.h>
 
 #include "gmp.h"
 #include "gmp-impl.h"
 
-using namespace std;
-
-
 /* The gmp_asprintf support routines never give an error, so
    __gmp_doprnt_mpf shouldn't fail and it's return can just be checked with
    an ASSERT.  */
@@ -44,7 +43,14 @@
 
 #if HAVE_STD__LOCALE
   char  point[2];
-  point[0] = use_facet< numpunct<char> >(o.getloc()).decimal_point();
+  point[0] =
+#ifndef _RWSTD_NO_TEMPLATE_ON_RETURN_TYPE
+      use_facet< numpunct<char> >(o.getloc())
+#else
+      use_facet(o.getloc(),(numpunct<char>*)0)
+#endif
+      .decimal_point();
+
   point[1] = '\0';
 #else
   const char *point = localeconv()->decimal_point;