Skip to content

check cython super in comprehension error #8080

@gshmu

Description

@gshmu

Current problem

cython can't using super() in list comprehension, assign a variable will fix this.

Desired solution

broken

class Any:
    def func(self):
        return [_ for _ in super().func()]

fixed

class Any:
    def func(self):
        var = super().func()
        return [_ for _ in var]

please add feature to check the cython broken.

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    High effort 🏋Difficult solution or problem to solveNeeds decision 🔒Needs a decision before implemention or rejectionNeeds design proposal 🔒This is a huge feature, some discussion should happen before a PR is proposedProposal 📨

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions