Author serhiy.storchaka
Recipients benjamin.peterson, brett.cannon, cryvate, gvanrossum, ncoghlan, serhiy.storchaka, yselivanov
Date 2017-11-14.10:43:13
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1510656193.36.0.213398074469.issue32012@psf.upfronthosting.co.za>
In-reply-to
Content
No, it doesn't match the "@dotted_name(arg_list)" pattern.

   decorator: "@" `dotted_name` ["(" [`argument_list` [","]] ")"] NEWLINE
   call: `primary` "(" [`argument_list` [","] | `comprehension`] ")"
   argument_list: `positional_arguments` ["," `starred_and_keywords`]
                :   ["," `keywords_arguments`]
                : | `starred_and_keywords` ["," `keywords_arguments`]
                : | `keywords_arguments`

The call syntax contains a special case for generator expression. The decorator expression syntax dosn't contain it. You should change the grammar rule to

   decorator: "@" `dotted_name` ["(" [`argument_list` [","] | `comprehension`] ")"] NEWLINE

for supporting this syntax. Please open a separate topic on Python-Dev for discussing this language change.
History
Date User Action Args
2017-11-14 10:43:13serhiy.storchakasetrecipients: + serhiy.storchaka, gvanrossum, brett.cannon, ncoghlan, benjamin.peterson, yselivanov, cryvate
2017-11-14 10:43:13serhiy.storchakasetmessageid: <1510656193.36.0.213398074469.issue32012@psf.upfronthosting.co.za>
2017-11-14 10:43:13serhiy.storchakalinkissue32012 messages
2017-11-14 10:43:13serhiy.storchakacreate