John H Palmieri <jhpalmier...@gmail.com> writes: > The functions like "is_Integer" are deprecated. If you compare the alternative > > isinstance(5/1, Integer) > > with > > 5/1 in ZZ > > I definitely want the first to return False, and I'm also happy if the second > returns True. It makes more sense to me for the second to have a mathematical, > abstract, meaning, because it is more natural and more likely for a user to > execute. I think we should view our users as mathematicians first, so I like > things as they are. > > (Another way to say it is that "x in Y" should take coercions and related > operations into account, as "5/1 in ZZ" does. If there is a canonical > one-to-one map from S to T, then every element of S should be "in" T. Every > element of a group should be "in" the corresponding group algebra, etc.)
Once you change is_Integer(5/1) to isinstance(5/1, Integer), it becomes abundantly clear which one is the literal containment check and which is the mathematical containment check. So I guess what it boils down to is that we should get rid of deprecated stuff :) -Keshav ---- Join us in #sagemath on irc.freenode.net ! -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org