I think attributes are considered more pythonic for many things than > methods. We insist on methods for many things in Sage because you can > document methods (but it's hard and not intrinsically supported by > python to document and introspect attribute documentation). > Well, it is supported if you make the attribute a property. Since most of those things are already functions it would be very easy sage: class test(object): ....: @property ....: def documented(self): ....: """some doc""" ....: pass ....: sage: l=test() sage: l.documented? http://docs.python.org/library/functions.html#property -- 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
- [sage-devel] Is it OK to replace certain cached methods by... Simon King
- [sage-devel] Re: Is it OK to replace certain cached m... Jason Grout
- [sage-devel] Make lazy attributes transparent for... Simon King
- [sage-devel] Re: Is it OK to replace certain cach... Maarten Derickx
- [sage-devel] Re: Is it OK to replace certain ... Simon King
- [sage-devel] Re: Is it OK to replace cert... Jason Grout
- [sage-devel] Re: Is it OK to replace... Simon King
- [sage-devel] Re: Is it OK to replace... Simon King
- [sage-devel] Re: Is it OK to replace certain cached m... Maarten Derickx
- [sage-devel] Re: Is it OK to replace certain cach... Jason Grout
- [sage-devel] Re: Is it OK to replace certain cach... Simon King
- [sage-devel] Re: Is it OK to replace certain cach... Simon King
- Re: [sage-devel] Re: Is it OK to replace cert... Florent Hivert
- [sage-devel] Re: Is it OK to replace cert... Simon King