[Python-ideas] What about allowing '?' in method names?
Tennessee Leeuwenburg
tleeuwenburg at gmail.com
Thu Aug 6 03:01:20 CEST 2009
this could be nicer than prefixing things with is, and makes things clearer
in some cases, e.g.
def shouldSomethingHappenFlag(self, context):
if 'relevant' in context:
return True
return False
vs
def shouldSomethingHappen?(self, context):
if 'relevant' in context:
return True
return False
I just think it looks nicer, and is a good hint that a true/false or other
kind of flag is likely to come back.
Cheers,
-T
--
--------------------------------------------------
Tennessee Leeuwenburg
http://myownhat.blogspot.com/
"Don't believe everything you think"
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20090806/50cde196/attachment.html>
More information about the Python-ideas
mailing list