#14894: Fix PARI error handling (needed for future upgrade to PARI 2.6)
--------------------------------------+----------------------------
Reporter: vbraun | Owner: jdemeyer
Type: defect | Status: needs_review
Priority: major | Milestone: sage-5.12
Component: packages: standard | Resolution:
Keywords: pari error signal | Merged in:
Authors: Peter Bruin | Reviewers:
Report Upstream: N/A | Work issues:
Branch: | Commit:
Dependencies: #12142, #14873 | Stopgaps:
--------------------------------------+----------------------------
Comment (by jdemeyer):
Replying to [comment:22 pbruin]:
> - reminiscent of `sig_on()` and `sig_off()`
In my opinion, not sufficiently reminiscent..., I still prefer
`pari_sig_on()` and `pari_sig_off()`.
> I see that this would be desirable because it saves typing a few lines
each time. On the other hand, I think the above code is bad style because
it explicity begins a block, but implicity ends it.
That might be true, but in this case I don't think it justifies the
overcomplication of two-liners like
{{{
sig_on()
return P.new_gen(gcos(x.g, pbw(precision)))
}}}
to the five-liner
{{{
cdef gen result_gen
sage_pari_catch()
result_gen = P.new_gen(gcos(x.g, pbw(precision)))
sage_pari_catch_end()
return result_gen
}}}
--
Ticket URL: <http://trac.sagemath.org/ticket/14894#comment:23>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/groups/opt_out.