Statistics
| Revision:

gvsig-scripting / org.gvsig.scripting / trunk / org.gvsig.scripting / org.gvsig.scripting.app / org.gvsig.scripting.app.mainplugin / src / main / resources-plugin / scripting / lib / pylint / test / input / func_return_yield_mix_py_33.py @ 745

History | View | Annotate | Download (321 Bytes)

1
"""pylint should detect yield and return mix inside genrators"""
2
# pylint: disable=using-constant-test
3
def somegen():
4
    """this is a bad generator"""
5
    if True:
6
        return 1
7
    else:
8
        yield 2
9

    
10
def moregen():
11
    """this is another bad generator"""
12
    if True:
13
        yield 1
14
    else:
15
        return 2
16