Antoine Pitrou wrote:

I don't see a problem for trivial functional wrappers to classes to be
capitalized like classes.

The problem is that the capitalization makes you
think it's a class, suggesting you can do things
with it that you actually can't, e.g. subclassing.

I can't think of any reason to do this. If you
don't want to promise that something is a class,
what possible reason is there for naming it like
one?

I can see a reason for doing the opposite, though:
if something happens to be a class, but you don't
want to promise that, you could expose it under
a lower-case name, that can be replaced with a
factory function later.

In this case, the thing to decide is whether
Event will always be a direct class instantiation.
If so, rename _Event to Event and expose it
directly. If not, rename Event to event.

--
Greg
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to