Dvorapa added a comment.

That method is an initializer. __new__ would be a constructor method.

That's an allocator. Python's __init__ initializer is mostly functionally equivalent to Java/C++'s constructor.

Yeah, I wanted to say the same thing. For people like me, who came to Python from Java-based languages __init__ behaves the same as Java's, Dart's etc. constructors


TASK DETAIL
https://phabricator.wikimedia.org/T166950

EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Dvorapa
Cc: Dalba, Dvorapa, gerritbot, darthbhyrava, Lokal_Profil, Framawiki, jayvdb, zhuyifei1999, Multichill, Xqt, Aklapper, valhallasw, pywikibot-bugs-list, Magul, Tbscho, MayS, Mdupont, JJMC89, Avicennasis, Masti, Alchimista, Rxy
_______________________________________________
pywikibot-bugs mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs

Reply via email to