File tree 1 file changed +18
-18
lines changed
1 file changed +18
-18
lines changed Original file line number Diff line number Diff line change @@ -626,31 +626,31 @@ def get_args(self):
626
626
fake_cursor , self .current_line , self .interp .locals )
627
627
except simpleeval .EvaluationError :
628
628
return False
629
+
630
+ if inspect .isclass (f ):
631
+ class_f = None
632
+
633
+ if (hasattr (f , '__init__' ) and
634
+ f .__init__ is not object .__init__ ):
635
+ class_f = f .__init__
636
+ if ((not class_f or
637
+ not inspection .getfuncprops (func , class_f )) and
638
+ hasattr (f , '__new__' ) and
639
+ f .__new__ is not object .__new__ and
640
+ # py3
641
+ f .__new__ .__class__ is not object .__new__ .__class__ ):
642
+
643
+ class_f = f .__new__
644
+
645
+ if class_f :
646
+ f = class_f
629
647
except Exception :
630
648
# another case of needing to catch every kind of error
631
649
# since user code is run in the case of descriptors
632
650
# XXX: Make sure you raise here if you're debugging the completion
633
651
# stuff !
634
652
return False
635
653
636
- if inspect .isclass (f ):
637
- class_f = None
638
-
639
- if (hasattr (f , '__init__' ) and
640
- f .__init__ is not object .__init__ ):
641
- class_f = f .__init__
642
- if ((not class_f or
643
- not inspection .getfuncprops (func , class_f )) and
644
- hasattr (f , '__new__' ) and
645
- f .__new__ is not object .__new__ and
646
- # py3
647
- f .__new__ .__class__ is not object .__new__ .__class__ ):
648
-
649
- class_f = f .__new__
650
-
651
- if class_f :
652
- f = class_f
653
-
654
654
self .current_func = f
655
655
self .funcprops = inspection .getfuncprops (func , f )
656
656
if self .funcprops :
You can’t perform that action at this time.
0 commit comments