polyfills ¶
Functions:
PyTypeObject_as_types_dict module-attribute
¶
PyTypeObject_as_types_dict = {
"tp_as_async": PyAsyncMethods,
"tp_as_number": PyNumberMethods,
"tp_as_sequence": PySequenceMethods,
"tp_as_mapping": PyMappingMethods,
}
SSizeObjArgProc_p module-attribute
¶
SSizeObjArgProc_p = CFUNCTYPE(c_int, PyObject_p, Py_ssize_t, PyObject_p)
TernaryFunc_p module-attribute
¶
TernaryFunc_p = CFUNCTYPE(py_object, PyObject_p, PyObject_p, PyObject_p)
as_number module-attribute
¶
as_number = (
"tp_as_number",
[
("add", "nb_add"),
("sub", "nb_subtract"),
("mul", "nb_multiply"),
("mod", "nb_remainder"),
("pow", "nb_power"),
("neg", "nb_negative"),
("pos", "nb_positive"),
("abs", "nb_absolute"),
("bool", "nb_bool"),
("inv", "nb_invert"),
("invert", "nb_invert"),
("lshift", "nb_lshift"),
("rshift", "nb_rshift"),
("and", "nb_and"),
("xor", "nb_xor"),
("or", "nb_or"),
("int", "nb_int"),
("float", "nb_float"),
("iadd", "nb_inplace_add"),
("isub", "nb_inplace_subtract"),
("imul", "nb_inplace_multiply"),
("imod", "nb_inplace_remainder"),
("ipow", "nb_inplace_power"),
("ilshift", "nb_inplace_lshift"),
("irshift", "nb_inplace_rshift"),
("iadd", "nb_inplace_and"),
("ixor", "nb_inplace_xor"),
("ior", "nb_inplace_or"),
("floordiv", "nb_floor_divide"),
("div", "nb_true_divide"),
("ifloordiv", "nb_inplace_floor_divide"),
("idiv", "nb_inplace_true_divide"),
("index", "nb_index"),
("matmul", "nb_matrix_multiply"),
("imatmul", "nb_inplace_matrix_multiply"),
],
)
builtin_methods module-attribute
¶
builtin_methods = {
(ob_type, dunder): copy_func(getattr(ob_type, dunder))
for dunder in dunder_methods
for ob_type in ob_types
if dunder in dir(ob_type)
}
dunder_methods module-attribute
¶
dunder_methods = [
"__add__",
"__iadd__",
"__sub__",
"__isub__",
"__mul__",
"__imul__",
"__floordiv__",
"__ifloordiv__",
"__pow__",
"__exp__",
"__log__",
"__sqrt__",
"__neg__",
"__pos__",
"__invert__",
"__int__",
"__float__",
"__abs__",
"__mod__",
"__and__",
"__or__",
"__xor__",
]
PyObject ¶
curse ¶
Source code
255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 |
|
disable_poly ¶
disable_poly() -> None
Source code
373 374 375 376 377 378 379 380 381 382 |
|
enable_poly ¶
enable_poly() -> None
Source code
361 362 363 364 365 366 367 368 369 370 |
|
get_not_implemented ¶
get_not_implemented() -> Any
Source code
85 86 87 88 89 90 91 |
|
reverse ¶
Source code
304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 |
|