Skip to content

Commit

Permalink
lkpp10
Browse files Browse the repository at this point in the history
  • Loading branch information
sobolevn committed Oct 3, 2024
1 parent 0fc5b85 commit 758a746
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions homeworks/10-==.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,14 @@
- Байткод `IS_OP`: https://docs.python.org/3/library/dis.html#opcode-IS_OP
- Как работают сравнения в Python? https://docs.python.org/3/reference/datamodel.html#object.__eq__
- `functools.total_ordering`: https://docs.python.org/3/library/functools.html#functools.total_ordering
- `functools.cmp_to_key`: https://docs.python.org/3/library/functools.html#functools.cmp_to_key
- `@dataclass(eq=True, order=True)`: https://docs.python.org/3/library/dataclasses.html#dataclasses.dataclass
- `ast.Compare`: https://docs.python.org/3/library/ast.html#ast.Compare

Другие статьи:
- https://snarky.ca/unravelling-rich-comparison-operators/
- https://snarky.ca/unravelling-is-and-is-not/

Жесть:
- `PyObject_RichCompare`: https://docs.python.org/3/c-api/object.html#c.PyObject_RichCompare
- `tp_richcompare`: https://docs.python.org/3/c-api/typeobj.html#c.PyTypeObject.tp_richcompare и https://docs.python.org/3/c-api/typeobj.html#c.richcmpfunc

0 comments on commit 758a746

Please sign in to comment.