[Python-Dev] Type hints -- a mediocre programmer's reaction (original) (raw)
Paul Sokolovsky pmiscml at gmail.com
Tue Apr 21 17:39:21 CEST 2015
- Previous message (by thread): [Python-Dev] Type hints -- a mediocre programmer's reaction
- Next message (by thread): [Python-Dev] Type hints -- a mediocre programmer's reaction
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hello,
On Tue, 21 Apr 2015 08:05:59 -0700 Nikolaus Rath <Nikolaus at rath.org> wrote:
On Apr 20 2015, Chris Angelico <rosuav at gmail.com> wrote: > Maybe it'd be of value to have a quick "code stripper" that takes > away all the annotations, plus any other junk/framing that you're > not interested in, and gives you something you can browse in a text > editor?
If you need to preprocess your source code to make it suitable for human consumption something is very wrong with your language design. I can't believe you're seriously suggesting this.
I'm sure that was irony, d'oh. Just as my suggestion to have stickers "This system runs free of type annotations" for the most zealous anti-annotations folks.
The proposed type annotations are very readable. Not as readable as C's type syntax, but ok. Sorry, irony again. I remember myself as a 10-years old kid, trying to wrap my head about C's types syntax, and not getting anything of it. So, please contrast it to C - PEP484 gives very readable syntax, and even both human- and machine-readable. If you feel like writing 3-story type annotation, just resist the temptation, "Any" is your best friend.
-- Best regards, Paul mailto:pmiscml at gmail.com
- Previous message (by thread): [Python-Dev] Type hints -- a mediocre programmer's reaction
- Next message (by thread): [Python-Dev] Type hints -- a mediocre programmer's reaction
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]