Bill Allombert on Tue, 10 Dec 2002 19:50:58 +0100


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

Re: trap() help


On Thu, Dec 05, 2002 at 12:11:06AM +0100, Karim BELABAS wrote:
> On Fri, 22 Nov 2002, Igor Schein wrote:
> > 2) I wanna trap all pari errors, but at the same time I don't wanna
> > trap ^C.  Is it possible?
> 
> No. Type ^C^D (= interrupt + EOF).

That does not work if you use an custom handler:

for(n=1,10000,if(trap(,0,galoisinit(x^32-n*x^2+1))!=0,print(p)))

You will need to type 10000 ^C if you want to stop the computation,
unless you are very lucky.

Cheers,
Bill