Benjamin Peterson <benja...@python.org> added the comment: 2011/5/14 Darren Dale <rep...@bugs.python.org>: > > Darren Dale <dsdal...@gmail.com> added the comment: > > On Sat, May 14, 2011 at 5:55 PM, Benjamin Peterson > <rep...@bugs.python.org> wrote: >> >> Benjamin Peterson <benja...@python.org> added the comment: >> >> Okay: how about this. We retain the passing of @abstractmethod to >> abstractpropert(), but @abstractgetter decorates the method for you. > > That can work, although I would advise against it. I find it strange > that we would use @abstractmethod sometimes and not others. If that is > what it takes to get the patch accepted, so be it. But since I don't > understand the motivation behind this approach, I won't be the one to > document the special cases of when @abstractmethod is required and > when it is not.
It would just be a convenience. > It definitely is a common case, and always will be. You can't begin > using abstractproperty.abstract(getter/setter/deleter) until you have > an abstract property, which requires passing a (potentially abstract) > method to the constructor. What about @abstractproperty def something(): pass @abstractproperty.setter def set(): pass @abstractproperty.deleter def delete: pass requires you to pass a method (explicitly) to a constructor? ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue11610> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com