[Python-Dev] A Desperate Plea For Introspection (aka: BDFAP Needed)

Yury Selivanov yselivanov.ml at gmail.com
Fri Jun 22 22:44:39 CEST 2012


On 2012年06月22日, at 4:20 PM, Terry Reedy wrote:
> On 6/22/2012 3:24 PM, Yury Selivanov wrote:
>> On 2012年06月22日, at 3:18 PM, Guido van Rossum wrote:
>>>> Hardly, because that's not valid syntax. I'd write name(arg1, *,
>>> arg2=<default>).
>>>> Like
>>>> replace(*, name=<default>, kind=<default>, default=<default>,
>> annotation=<default>) -> Parameter
>>>> or
>>>> replace(*, name=<optional>, kind=<optional>, default=<optional>,
>> annotation=<optional>) -> Parameter
>> I do not undertand the 'or'. I hope you mean default argument expressions in the standard manner rather than '<default>' or '<optional>'.

It's now in the updated PEP. We use '<optional>' notation
just to specify that the parameter is optional, i.e. can
(or in some cases should) be omitted.
-
Yury


More information about the Python-Dev mailing list

AltStyle によって変換されたページ (->オリジナル) /