Bill Allombert on Tue, 16 Apr 2019 14:18:13 +0200


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: Muller implementation don't know where is the problem


On Mon, Apr 15, 2019 at 11:05:26PM +0200, Eduardo Morras wrote:
> On Sun, 14 Apr 2019 13:37:17 +0200
> Bill Allombert <Bill.Allombert@math.u-bordeaux.fr> wrote:
> 
> > Hello Eduardo,
> > 
> > I found three problems:
> > >   
> > >   for(i=1,10000000 
> > 
> > You need a comma here
> 
> Yes, you're right, I didn't see it. 
> 
> > >     if(x >= y,
> > >       res = x + c,
> > >       res = y + c
> > >     )
> > 
> > You need a semicolon here
> 
> Yes, that too!
> 
> > Hope this help,
> > Bill
> 
> Thanks a lot, I spend 2 days with those stupid errors. 

I am sorry to hear this. The GP parser should really report more helpful
error messages in this case. Unfortunately this is difficult to do while
keeping backward compatibility with GP 2.3. Functions like "print" has 
support for comma-less concatenation:

? f(y)=print("y="y" x="y^2+1);
? f(5)
y=5 x=26

which interfers with the normal parsing error detection mechanism.

Cheers,
Bill