Re:How Many Lines of C It Takes to Execute a and B in Python?
by spacechild1 on Monday December 11, 2023 @01:53PM
(#38603809)
Lua has metamethods: https://www.lua.org/manual/5.3/manual.html#2.4
[ Parent
| on HN ]
Re:How Many Lines of C It Takes to Execute a and B in Python?
by lifthrasiir on Monday December 11, 2023 @11:09PM
(#38609326)
They reside in metatables, which are only optionally linked to ordinary objects. Python magic methods are a part of the core object protocol.