#17119: Disallow pari(None)
-------------------------------------+-------------------------------------
Reporter: jdemeyer | Owner:
Type: enhancement | Status: needs_review
Priority: major | Milestone: sage-6.4
Component: interfaces | Resolution:
Keywords: | Merged in:
Authors: Jeroen Demeyer | Reviewers:
Report Upstream: N/A | Work issues:
Branch: | Commit:
u/jdemeyer/ticket/17119 | 4476266587733622582d32b1b7015c56ae97bf69
Dependencies: | Stopgaps:
-------------------------------------+-------------------------------------
Comment (by jdemeyer):
> - Always convert `gnil` to Python `None`, and make `pari(None)` return
`None`.
That wouldn't work with composite objects: what should `pari([None, 1])`
be then?
> - Allow wrapping `gnil` (and possibly other PARI objects that are not on
the stack) in a Sage `gen` without copying it, so PARI recognises it as
`gnil`.
Theoretically perhaps the best, but hard to do.
> - Stop treating `gnil` specially, identifying it with `gen_0`.
I don't like this. It would lead to things like
{{{
sage: pari("print(12345)")
12345
0
}}}
So... I still think it's best to disallow `pari(None)`. I see no use case
for it and the times where it did come up where all mistakes.
--
Ticket URL: <http://trac.sagemath.org/ticket/17119#comment:6>
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/d/optout.