%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /proc/309157/task/309157/root/lib/python3/dist-packages/pythran/analyses/
Upload File :
Create Path :
Current File : //proc/309157/task/309157/root/lib/python3/dist-packages/pythran/analyses/yield_points.py

"""
YieldPoints gathers all yield points from a node
"""

from pythran.passmanager import FunctionAnalysis


class YieldPoints(FunctionAnalysis):
    '''Gathers all yield points of a generator, if any.'''
    def __init__(self):
        self.result = list()
        super(YieldPoints, self).__init__()

    def visit_Yield(self, node):
        self.result.append(node)

Zerion Mini Shell 1.0