|
|
Subscribe / Log in / New account

When and how to evaluate Python annotations

When and how to evaluate Python annotations

Posted Jun 16, 2021 6:53 UTC (Wed) by cpitrat (subscriber, #116459)
In reply to: When and how to evaluate Python annotations by timrichardson
Parent article: When and how to evaluate Python annotations

No I didn't. I just pasted the wrong part of the article. Silly me!

What I wanted to ask is whether there's really any usage of annotations for something else than typing, so questioning rather the objections to this part:
"restrict annotations to just type hints"


to post comments

When and how to evaluate Python annotations

Posted Jun 16, 2021 11:18 UTC (Wed) by mathstuf (subscriber, #69389) [Link] (1 responses)

I remember seeing a macro system based on it. No idea how serious it was or how prevalent, but I really don't like the precedent of "here's an abstract ball, do what you want with it however you see it" then later the developers coming in and saying "so we said it was an abstract ball, but we're making it a bowling ball now; sorry to anyone who was playing basketball with it before, but you're going to have a bad time".

When and how to evaluate Python annotations

Posted Jun 16, 2021 11:31 UTC (Wed) by cpitrat (subscriber, #116459) [Link]

Yeah I get that. I'm quite curious about other applications and especially about whether they can mix with typing. I assume not, which by itself makes having annotations abstract in the first place a dubious choice.


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds