On Thu, Mar 7, 2019 at 2:54 PM Simon King <simon.k...@uni-jena.de> wrote:
>
> Hi Erik,
>
> On 2019-03-07, E. Madison Bray <erik.m.b...@gmail.com> wrote:
> > This is completely normal:
> > https://en.wikipedia.org/wiki/Rounding#Round_half_to_even
>
> Thanks for the pointer.
>
> >> If I understand correctly, Sage currently uses .round() for customised
> >> rounding. Would it be a good idea to add a .__round__() method to
> >> sage.structure.element.Element that by default tries to return
> >> self.round()?
> >
> > No, I don't think that would be useful--I don't think that really
> > solves any problem here or answers any of my questions, sorry.
>
> I thought it would make it possible to replace Sage's custom round()
> function by Python-3's default round() function.

Ah, I think maybe I see what you were going for there.  Yes, that
might help a little bit in some cases actually, such as if some
Element is passed to Python's built-in round(), but that could also be
handled on a case-by-case basis...  I don't think we necessarily need
or want to remove Sage's own round() function though.  As I wrote
previously, it's worth keeping for the better docs alone.

It also doesn't help with the question of what to do with RealNumber.__round__()

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to