mirror of
https://github.com/davidhalter/jedi.git
synced 2025-12-08 06:44:46 +08:00
fixed getattr with array call
This commit is contained in:
@@ -414,6 +414,9 @@ class Execution(Executable):
|
|||||||
continue
|
continue
|
||||||
|
|
||||||
for arr_name in names:
|
for arr_name in names:
|
||||||
|
if not isinstance(arr_name, Instance):
|
||||||
|
debug.warning('getattr called without str')
|
||||||
|
continue
|
||||||
if len(arr_name.var_args) != 1:
|
if len(arr_name.var_args) != 1:
|
||||||
debug.warning('jedi getattr is too simple')
|
debug.warning('jedi getattr is too simple')
|
||||||
key = arr_name.var_args[0]
|
key = arr_name.var_args[0]
|
||||||
|
|||||||
@@ -495,6 +495,8 @@ getattr()
|
|||||||
getattr(str)
|
getattr(str)
|
||||||
#?
|
#?
|
||||||
getattr(getattr, 1)
|
getattr(getattr, 1)
|
||||||
|
#?
|
||||||
|
getattr(str, [])
|
||||||
|
|
||||||
|
|
||||||
class Base():
|
class Base():
|
||||||
|
|||||||
Reference in New Issue
Block a user