Hi Jeroen, On 2015-11-23, Jeroen Demeyer <jdeme...@cage.ugent.be> wrote: > Sage has a lot of classes like Element, ModuleElement, RingElement, > CommutativeRingElement, ... > > I have often wondered if we really need all these classes. What's the > compelling reason that we don't have just Element? All these different > classes are really just frontends to the coercion model implementing > various arithmetic methods. Of course, you could argue that Element > should not have __add__ and __mul__ (since not all elements can be added > or multiplied). But it doesn't really hurt to have them and raise > NotImplementedError (unless I'm missing something). > > Unifying all these Element classes will simplify element.pyx a lot for > the better. It would also make it easier to add support for new > methods: for example __floordiv__ still doesn't use the coercion model.
I have a ticket that goes into that direction. I think #18756 or #18758 or both. But currently I have no resources to work on them, and at least one of them needs work. Best regards, Simon -- 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 http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.