Message143021
> some simple examples showing the syntax would go a long way.
Sorry, there as just too many ways to go and we are intentionally not stating which way is preferred. I've seen many variants a:[Integral] for a list of integers, a:(int,str) for a 2-tuple of an int and a string, a:(str,file,None) for something that is a string or a file or None, a:'light_years' to indicate units of measure, a:range_check(10.5, 20.1) for range validation, and some variants for converters, adapters, factory functions, documentation aids, etc.
If you want to advance the state of the art, perhaps write a blog post on what you consider to be a best practice. If a consensus emerges, we
will follow. |
|
Date |
User |
Action |
Args |
2011-08-26 16:49:11 | rhettinger | set | recipients:
+ rhettinger, eric.araujo, docs@python, JJeffries |
2011-08-26 16:49:11 | rhettinger | set | messageid: <1314377351.18.0.963573194409.issue12195@psf.upfronthosting.co.za> |
2011-08-26 16:49:10 | rhettinger | link | issue12195 messages |
2011-08-26 16:49:09 | rhettinger | create | |
|