New submission from autospamfighter <autospamfigh...@yahoo.com>:

I was trying to make a custom complex class that looked something like this and 
it failed. I replaced complex with int and it also failed, but I tried float 
and it worked.

---fail
class A(complex):
    def __init__(self, test):
        super().__init__()

A(test=5)

---fail
class A(int):
    def __init__(self, test):
        super().__init__()

A(test=5)

---work
class A(float):
    def __init__(self, test):
        super().__init__()

A(test=5)

----------
components: Library (Lib)
messages: 380840
nosy: autospamfighter
priority: normal
severity: normal
status: open
title: Subclassing int and complex with keyword arguments weird
versions: Python 3.9

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue42334>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to