[Zope3-dev] interface conventions: default=_RAISE_ERROR
Steve Alexander
steve@cat-box.net
Sat, 11 May 2002 00:54:49 +0100
Gary Poster wrote:
>
> Instead, my suggestion is to place
> _RAISE_ERROR=Object()
It needs to be object(), not Object()
> in the __init__ of the Interfaces package. An interface that wants to use
> the default marker would simply
> from Interface import Interface, _RAISE_ERROR
> and implementations could import from their interfaces or from the original
> declaration in the Interface package.
I really wouldn't bother. It saves very little typing, adds to the
complexity of finding out what things really mean, adds another
dependency, and saves a few hundred bytes at most per runtime.
--
Steve Alexander