diff options
Diffstat (limited to 'astroid/protocols.py')
| -rw-r--r-- | astroid/protocols.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/astroid/protocols.py b/astroid/protocols.py index 8b682e48..84e3571b 100644 --- a/astroid/protocols.py +++ b/astroid/protocols.py @@ -339,6 +339,9 @@ def _arguments_infer_argname(self, name, context): if name == self.vararg: vararg = nodes.const_factory(()) vararg.parent = self + if not self.arguments and self.parent.name == "__init__": + cls = self.parent.parent.scope() + vararg.elts = [bases.Instance(cls)] yield vararg return if name == self.kwarg: |
