Why change the default? Global state is always a liability; Just don't do it. Make the field a parameter to your code:
def frobnicate(x,y, field=None) if field is None: from sage.structure.element import get_coercion_model field = get_coercion_model().common_parent(x, y) x, y = field(x), field(y) ... frobnicate(1, 2, field=RealField(100)) -- 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.