Extract functions properly out of functions

This commit is contained in:
Dave Halter
2020-02-22 21:24:06 +01:00
parent ce1093406a
commit 1c0f9e1f30
3 changed files with 46 additions and 10 deletions

View File

@@ -18,3 +18,29 @@ def ab():
ab()
# -------------------------------------------------- in-function-1
def f(x):
#? 11 text {'new_name': 'ab'}
return x + 1 * 2
# ++++++++++++++++++++++++++++++++++++++++++++++++++
def ab():
return x + 1 * 2
def f(x):
#? 11 text {'new_name': 'ab'}
return ab()
# -------------------------------------------------- in-function-with-dec
@classmethod
def f(x):
#? 11 text {'new_name': 'ab'}
return x + 1 * 2
# ++++++++++++++++++++++++++++++++++++++++++++++++++
def ab():
return x + 1 * 2
@classmethod
def f(x):
#? 11 text {'new_name': 'ab'}
return ab()