mirror of
https://github.com/davidhalter/jedi.git
synced 2025-12-08 23:04:48 +08:00
some list tests
This commit is contained in:
@@ -55,7 +55,7 @@ variable_rename(list())().
|
|||||||
variable_rename(1)().
|
variable_rename(1)().
|
||||||
|
|
||||||
# -----------------
|
# -----------------
|
||||||
# double execution
|
# keyword arguments
|
||||||
# -----------------
|
# -----------------
|
||||||
|
|
||||||
def func(a=1, b=''):
|
def func(a=1, b=''):
|
||||||
@@ -69,6 +69,7 @@ exe[0].index
|
|||||||
|
|
||||||
#? ['append']
|
#? ['append']
|
||||||
exe[1].append
|
exe[1].append
|
||||||
|
|
||||||
# -----------------
|
# -----------------
|
||||||
# closures
|
# closures
|
||||||
# -----------------
|
# -----------------
|
||||||
@@ -101,6 +102,20 @@ exe[1].real
|
|||||||
#? ['upper']
|
#? ['upper']
|
||||||
exe[1].upper
|
exe[1].upper
|
||||||
|
|
||||||
|
lis = [1,""]
|
||||||
|
exe2 = args_func(lis)[0]
|
||||||
|
|
||||||
|
#? []
|
||||||
|
exe2[1].real
|
||||||
|
#? ['upper']
|
||||||
|
exe2[1].upper
|
||||||
|
|
||||||
|
exe3 = args_func([1,""])[0]
|
||||||
|
|
||||||
|
##? []
|
||||||
|
exe3[1].real
|
||||||
|
##? ['upper']
|
||||||
|
exe3[1].upper
|
||||||
|
|
||||||
def args_func(arg1, *args):
|
def args_func(arg1, *args):
|
||||||
return arg1, args
|
return arg1, args
|
||||||
|
|||||||
Reference in New Issue
Block a user