Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 181507 Details for
Bug 227529
dev-lang/maude-2.3.0 fails to build with gcc 4.3
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
maude-2.3.0-gcc43.patch
maude-2.3.0-gcc43.patch (text/plain), 3.12 KB, created by
Ryan Hill (RETIRED)
on 2009-02-10 05:01:14 UTC
(
hide
)
Description:
maude-2.3.0-gcc43.patch
Filename:
MIME Type:
Creator:
Ryan Hill (RETIRED)
Created:
2009-02-10 05:01:14 UTC
Size:
3.12 KB
patch
obsolete
>--- Maude-2.3/src/BuiltIn/stringOpSymbol.cc 2003-11-10 18:33:00.000000000 -0600 >+++ Maude-2.4/src/BuiltIn/stringOpSymbol.cc 2008-09-11 19:03:36.000000000 -0600 >@@ -220,7 +220,9 @@ StringOpSymbol::eqRewrite(DagNode* subje > case CODE('f', 'l'): > { > bool error; >- //double fl = stringToDouble(left.c_str(), error); >+#ifdef ROPE_C_STR_BROKEN >+ // >+ // This kudge doesn't seem to be need nowadays, but copy() doesn't work. > // > // This messing about is needed because Rope::c_str() > // fails in libstdc++-v3 >@@ -231,7 +233,9 @@ StringOpSymbol::eqRewrite(DagNode* subje > t[len] = '\0'; > double fl = stringToDouble(t, error); > delete [] t; >- // >+#else >+ double fl = stringToDouble(left.c_str(), error); >+#endif > if (error) > goto fail; > return floatSymbol->rewriteToFloat(subject, context, fl); >@@ -282,6 +286,7 @@ StringOpSymbol::eqRewrite(DagNode* subje > break; > default: > CantHappen("bad string op"); >+ r = false; // avoid compiler warning > } > Assert(trueTerm.getTerm() != 0 && falseTerm.getTerm() != 0, > "null true/false for relational op"); >@@ -358,6 +363,7 @@ StringOpSymbol::eqRewrite(DagNode* subje > break; > default: > CantHappen("bad string op"); >+ r = 0; // avoid compiler warning > } > Assert(notFoundTerm.getTerm() != 0, "null notFound for find op"); > if (r == NONE) >@@ -591,6 +597,13 @@ StringOpSymbol::ropeToNumber(const crope > if (!isalnum(subject[j])) > return false; > } >+ // >+ // We have detected a fraction form. >+ // >+#ifdef ROPE_C_STR_BROKEN >+ // >+ // This kudge doesn't seem to be need nowadays, but copy() doesn't work. >+ // > char* t = new char[len]; // longer than needed but who cares > int dLen = len - (i + 1); > subject.copy(i + 1, dLen, t); >@@ -609,20 +622,34 @@ StringOpSymbol::ropeToNumber(const crope > } > delete [] t; > return true; >+#else >+ return mpz_set_str(denominator.get_mpz_t(), subject.substr(i + 1).c_str(), base) == 0 && >+ mpz_set_str(numerator.get_mpz_t(), subject.substr(0,i).c_str(), base) == 0; >+#endif > } > else > return false; > } > } >+ // >+ // We have a regular integer form. >+ // >+ denominator = 0; >+#ifdef ROPE_C_STR_BROKEN >+ // >+ // This kudge doesn't seem to be need nowadays, but copy() doesn't work. >+ // > char* t = new char[len + 1]; > subject.copy(t); > t[len] = '\0'; > if (mpz_set_str(numerator.get_mpz_t(), t, base) == 0) > { > delete [] t; >- denominator = 0; > return true; > } > delete [] t; >- return false; >+ return false; >+#else >+ return mpz_set_str(numerator.get_mpz_t(), subject.c_str(), base) == 0; >+#endif > } >--- Maude-2.3/src/Utility/macros.hh 2007-01-11 21:13:21.000000000 -0600 >+++ Maude-2.4/src/Utility/macros.hh 2008-09-04 13:52:55.000000000 -0600 >@@ -50,10 +50,10 @@ > #if HAVE_CTYPE_H > #include <ctype.h> > #endif >-#if HAVE_STRINGS_H >-#include <strings.h> >-#elif HAVE_STRING_H >+#if HAVE_STRING_H > #include <string.h> >+#elif HAVE_STRINGS_H >+#include <strings.h> > #endif > #if HAVE_UNISTD_H > #include <unistd.h> // needed by solaris
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 227529
:
159951
| 181507