Author Anthony Sottile
Recipients Anthony Sottile, benjamin.peterson, brett.cannon, hroncok, jwilk, mbussonn, nascheme, ncoghlan, njs, serhiy.storchaka, thautwarm, vstinner, yselivanov
Date 2019-05-14.16:52:56
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1557852776.41.0.421716387578.issue32892@roundup.psfhosted.org>
In-reply-to
Content
hitting this in https://bugs.python.org/issue36917?

Is the simplification here really worth the breaking change to consumers?

I now have to write something that's essentially this to work around this which feels more like the complexity has just been pushed to users instead of the stdlib:


def visit_Constant(self, node):
    if isinstance(node.value, str):
        self.visit_Str(node)
    elif isinstance(node.value, bytes):
        self.visit_Bytes(node)
    elif node.value in {True, False}:
        self.visit_NameConstant(node)
    elif node.value is Ellipsis:
        self.visit_Ellipsis(node)
    elif isinstance(node.value, (int, float)):
        self.visit_Num(node)
    else:
        # etc...
History
Date User Action Args
2019-05-14 16:52:56Anthony Sottilesetrecipients: + Anthony Sottile, brett.cannon, nascheme, ncoghlan, vstinner, benjamin.peterson, jwilk, njs, serhiy.storchaka, yselivanov, mbussonn, hroncok, thautwarm
2019-05-14 16:52:56Anthony Sottilesetmessageid: <1557852776.41.0.421716387578.issue32892@roundup.psfhosted.org>
2019-05-14 16:52:56Anthony Sottilelinkissue32892 messages
2019-05-14 16:52:56Anthony Sottilecreate