diff options
author | Jacob Walls <jacobtylerwalls@gmail.com> | 2023-03-26 08:17:38 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-26 08:17:38 -0400 |
commit | b5ebf994a1c6039fa8ca4706889e007700cdf41a (patch) | |
tree | 6de918a20f023a2b0168635c4664ab272bdc4497 /astroid/brain | |
parent | 598e4c3fc51173562fcbdda9c8413dd4e5f92b06 (diff) | |
download | astroid-git-b5ebf994a1c6039fa8ca4706889e007700cdf41a.tar.gz |
Restore setting a Call as a base for classes using `six.with_metaclass` (#2049)
Harden support for using enums as metaclasses.
Fixes the crash in PyCQA/pylint#5935 by adopting the check
for not-none bases as in ClassDef._inferred_bases without recausing
the false positive reported in PyCQA/pylint#7506, which requires
correct bases.
Diffstat (limited to 'astroid/brain')
-rw-r--r-- | astroid/brain/brain_six.py | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/astroid/brain/brain_six.py b/astroid/brain/brain_six.py index a35cfdd6..0eb945d8 100644 --- a/astroid/brain/brain_six.py +++ b/astroid/brain/brain_six.py @@ -219,7 +219,6 @@ def transform_six_with_metaclass(node): """ call = node.bases[0] node._metaclass = call.args[0] - node.bases = call.args[1:] return node |