On Wed, 23 Jun 2010 16:12:45 -0700 (PDT), Rob Beezer <goo...@beezer.cotse.net> wrote: > "Python doesn't have an "end" statement!", I hear you say. > > Try in the notebook, as a colleague new to Sage basically did with a > more serious purpose, > > a = 3 > if a == 1: > a = a+1 > else: > a = 6 > end > a += 1 > > "end" is a Sage function that constructs an endomorphism. So the > "statement" above is harmless. Is this enough reason to give this > function a new, less-confusion-causing name?
For some reason this post made me smile :) Here are a couple of thoughts: * the whole body of end(X, f) is: return End(X)(f) I would not be upset if end were done away with completely; I think End(X)(f) is more explicit and the thing I would try for if I had to build that endomorphism. * it's amazing that this is the first time I hear about this; has anyone seen this before? this suggests at least two scenarios: ** this "mistake" really is very rare, in which case it's not clear whether we should act on it ** this "mistake" is a bit more widespread, but since you don't get an error you won't notice it; in this case, if we remove "end" we need to deprecate it first, otherwise a bunch of people's code won't work any more :) Best, Alex -- Alex Ghitza -- http://aghitza.org/ Lecturer in Mathematics -- The University of Melbourne -- Australia -- 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