[Python-3000] Draft pre-PEP: function annotations (original) (raw)
Paul Prescod paul at prescod.net
Sat Aug 12 21:38:06 CEST 2006
- Previous message: [Python-3000] Draft pre-PEP: function annotations
- Next message: [Python-3000] Draft pre-PEP: function annotations
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Phillip. I'm having trouble following the discussion. I briefly caught up when Talin got very concrete with syntax and I would appreciate if you could offer some correspondingly remedial training.
Talin's example is that metadata inventor A documents that his/her users should use this syntax for parameter docstrings:
def myfunc( x : "The x coordinate", y : "The y coordinate" ) ...
Then metadata inventor B documents this his/her users should use this syntax for getopt strings:
class MyHandler( CommandLineHandler ):
@getopt def list( infile:"i" = sys.stdin, outfile:"o" = sys.stdout ):
Now the user is faced with the challenge of making these two work together in order to get the best of both worlds. What does the user type?
The mechanism of overloading, function dispatching etc. is uninteresting to me until I understand what goes in the user's Python file. Syntax is important.
Paul Prescod -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.python.org/pipermail/python-3000/attachments/20060812/a022b238/attachment.htm
- Previous message: [Python-3000] Draft pre-PEP: function annotations
- Next message: [Python-3000] Draft pre-PEP: function annotations
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]