qepcad-B/qepcad-B-parens.patch
2014-02-14 12:17:12 -07:00

133 lines
5.8 KiB
Diff

--- ./extensions/lift2D/IBPRRIOAP.c.orig 2012-03-16 06:49:32.000000000 -0600
+++ ./extensions/lift2D/IBPRRIOAP.c 2013-08-30 16:03:12.403968400 -0600
@@ -95,7 +95,7 @@ Step3: /* Isolate the roots of B(alpha,y
goto Return; }
/* get trend of first root */
- if (PDEG(B) % 2 == 0 && s == 1 || PDEG(B) % 2 == 1 && s == -1)
+ if ((PDEG(B) % 2 == 0 && s == 1) || (PDEG(B) % 2 == 1 && s == -1))
t1 = -1;
else
t1 = 1;
--- ./extensions/lift2D/modIBPRRIOAP.c.orig 2012-03-16 06:49:32.000000000 -0600
+++ ./extensions/lift2D/modIBPRRIOAP.c 2013-08-30 16:02:49.164007931 -0600
@@ -97,7 +97,7 @@ Step3: /* Isolate the roots of B(alpha,y
goto Return; }
/* get trend of first root */
- if (PDEG(B) % 2 == 0 && s == 1 || PDEG(B) % 2 == 1 && s == -1)
+ if ((PDEG(B) % 2 == 0 && s == 1) || (PDEG(B) % 2 == 1 && s == -1))
t1 = -1;
else
t1 = 1;
--- ./extensions/adj2d/truthbytop/BOUNDARY2D.c.orig 2012-03-16 06:49:32.000000000 -0600
+++ ./extensions/adj2d/truthbytop/BOUNDARY2D.c 2013-08-30 16:14:29.779797280 -0600
@@ -80,7 +80,7 @@ Step6: /* Split cell list by dimension.
tc++;
else
fc++; }
- if (tc > 0 && fc > 0 || GVERTEXLABEL(v,G) == TRUE && tc == 0)
+ if ((tc > 0 && fc > 0) || (GVERTEXLABEL(v,G) == TRUE && tc == 0))
GNEWLABEL(v,TRUE,G);
else
GNEWLABEL(v,FALSE,G); }
--- ./source/db/SINGULAR.c.orig 2012-03-16 06:49:30.000000000 -0600
+++ ./source/db/SINGULAR.c 2013-08-30 16:04:35.516826349 -0600
@@ -58,7 +58,7 @@ void SingularServer::reportStats(ostream
char peekNonWS(istream &in)
{
- char c; while((c = in.peek()) && c == ' ' || c == '\t' || c == '\n') in.get(); return c;
+ char c; while(c = in.peek() && (c == ' ' || c == '\t' || c == '\n')) in.get(); return c;
}
--- ./source/db/convenientstreams.h.orig 2012-03-16 06:49:30.000000000 -0600
+++ ./source/db/convenientstreams.h 2013-08-30 16:05:34.707724662 -0600
@@ -31,7 +31,7 @@ public:
string s = "";
char c = in.get();
if (opt == skipleadingws)
- while(c != EOF && (isspace(c) || c == '\\' && isspace(in.peek()))) c = in.get();
+ while(c != EOF && (isspace(c) || (c == '\\' && isspace(in.peek())))) c = in.get();
// States : 0 = normal, 1 = in comment, 2 = just read a backslash
int state = 0;
do {
--- ./source/proj/GROUPSAMEPJ.c.orig 2012-03-16 06:49:30.000000000 -0600
+++ ./source/proj/GROUPSAMEPJ.c 2013-08-30 16:10:24.459222092 -0600
@@ -46,7 +46,7 @@ BDigit PRJPNTEQUAL(Word A, Word B)
Word KR = LIST2(SECOND(aK),LIST2(1,1));
Word sL = AFSIGN(aM,aI,AFPEMV(1,aM,G,KL));
Word sR = AFSIGN(aM,aI,AFPEMV(1,aM,G,KR));
- return EQUAL(KL,KR) && sL == 0 || sL == 1 && sR == -1 || sL == -1 && sR == 1;
+ return (EQUAL(KL,KR) && sL == 0) || (sL == 1 && sR == -1) || (sL == -1 && sR == 1);
}
/* One primitive, the other not */
@@ -75,10 +75,10 @@ Step1: /* Group. */
{
ADV(Jt,&J2,&Jt);
Jt2 = LELTI(J2,PO_POLY);
- if (LELTI(J1,PO_TYPE) == PO_POINT && LELTI(J2,PO_TYPE) == PO_POINT
- && PRJPNTEQUAL(Js1,Jt2) ||
- LELTI(J1,PO_TYPE) != PO_POINT && LELTI(J2,PO_TYPE) != PO_POINT
- && EQUAL(Js1,Jt2))
+ if ((LELTI(J1,PO_TYPE) == PO_POINT && LELTI(J2,PO_TYPE) == PO_POINT
+ && PRJPNTEQUAL(Js1,Jt2)) ||
+ (LELTI(J1,PO_TYPE) != PO_POINT && LELTI(J2,PO_TYPE) != PO_POINT
+ && EQUAL(Js1,Jt2)))
{
SLELTI(J2,PO_PARENT,CONC(LELTI(J2,PO_PARENT),LELTI(J1,PO_PARENT)));
t = 1;
--- ./source/proj/PROJMCECmod.c.orig 2012-03-16 06:49:30.000000000 -0600
+++ ./source/proj/PROJMCECmod.c 2013-08-30 16:12:22.235018024 -0600
@@ -67,7 +67,7 @@ Step1: /* Obtain coefficients. */
t = 1; }
/* If r = 2 OR r-1 is in free variable space, the leading coefficient is always enough! */
- if (t && (r == 2 || (PCMZERROR && r-1 <= GVNFV))
+ if ((t && (r == 2 || (PCMZERROR && r-1 <= GVNFV)))
|| (experimentalExtensionFlag && qfrCheckNonNullified(r,Ap1,GVNA.W,GVNQFF.W,GVVL.W))
)
t = 0;
@@ -101,7 +101,7 @@ Step1: /* Obtain coefficients. */
tf = tf || (Q == FULLDE || Q == FULLDA);
/* Test 3: in free variable space when the PCMZERROR option is used */
- tf = tf || PCMZERROR && rp <= GVNFV;
+ tf = tf || (PCMZERROR && rp <= GVNFV);
/* Test 4: has no common zero with the system of all other coefficients */
if (!tf)
--- ./source/proj/PROJMCmod.c.orig 2012-03-16 06:49:30.000000000 -0600
+++ ./source/proj/PROJMCmod.c 2013-08-30 16:11:49.731074222 -0600
@@ -57,7 +57,7 @@ Step1: /* Obtain coefficients. */
t = 1; }
/* If r = 2 OR r-1 is in free variable space, the leading coefficient is always enough! */
- if (t && (r == 2 || (PCMZERROR && r-1 <= GVNFV))
+ if ((t && (r == 2 || (PCMZERROR && r-1 <= GVNFV)))
|| (experimentalExtensionFlag && qfrCheckNonNullified(r,Ap1,GVNA.W,GVNQFF.W,GVVL.W))
)
t = 0;
@@ -91,7 +91,7 @@ Step1: /* Obtain coefficients. */
tf = tf || (Q == FULLDE || Q == FULLDA);
/* Test 3: in free variable space when the PCMZERROR option is used */
- tf = tf || PCMZERROR && rp <= GVNFV;
+ tf = tf || (PCMZERROR && rp <= GVNFV);
/* Test 4: has no common zero with the system of all other coefficients */
if (!tf)
--- ./source/ticad/INITPCAD.c.orig 2012-03-16 06:49:30.000000000 -0600
+++ ./source/ticad/INITPCAD.c 2013-08-30 16:13:07.946938949 -0600
@@ -14,7 +14,7 @@ Word QepcadCls::INITPCAD()
Word D, tv;
Step0: /* Determine truth value! */
- if (GVNA == FALSE || GVNA != NIL && LELTI(GVNA,1) == NEOP && LELTI(GVNA,2) == 0) tv = NA;
+ if (GVNA == FALSE || (GVNA != NIL && LELTI(GVNA,1) == NEOP && LELTI(GVNA,2) == 0)) tv = NA;
else if (LELTI(GVNQFF,1) == NEOP && LELTI(GVNQFF,2) == 0) tv = FALSE;
else if (LELTI(GVNQFF,1) == EQOP && LELTI(GVNQFF,2) == 0) tv = TRUE;
else tv = UNDET;