[Python-Dev] A Desperate Plea For Introspection (aka: BDFAP Needed) (original) (raw)
Yury Selivanov yselivanov.ml at gmail.com
Fri Jun 22 23:04:03 CEST 2012
- Previous message: [Python-Dev] A Desperate Plea For Introspection (aka: BDFAP Needed)
- Next message: [Python-Dev] A Desperate Plea For Introspection (aka: BDFAP Needed)
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 2012-06-22, at 4:58 PM, Ethan Furman wrote:
That looks strange to me -- I suggest putting brackets around each one, like:
replace(*, [name=,] [kind=,] [default=,] [annotation=]) -> Parameter
Isn't it too much? The PEP clearly indicates '=' is just a notation for an optional parameter.
If it's that much of an issue - We can use '=_void' instead, as it is in the implementation, and describe how it works. But that's just noise, that will distract the reader from the PEP.
which is still a bit noisy. At the risk of raising the ire of those who don't condone the use of '...' :) how about:
replace(*, [name=...,] [kind=...,] [default=...,] [annotation=...] ) -> Parameter
That may confuse someone, as ... - Ellipsis is a legitimate object to be used as a default value or annotation:
def foo(bar:...=...)->...:
pass
I'd keep it simple ;)
- Yury
- Previous message: [Python-Dev] A Desperate Plea For Introspection (aka: BDFAP Needed)
- Next message: [Python-Dev] A Desperate Plea For Introspection (aka: BDFAP Needed)
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]