diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2022-04-28 10:25:33 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-28 10:25:33 (GMT) |
commit | cd1fbbc81761dc26ce6daf724d57d48e965e5817 (patch) | |
tree | e5ea8dd5fd0e4227fda80160f1de004a78f138f8 /Python/pylifecycle.c | |
parent | 37c6db60f9ac62b8a80bf04a8146274756ee0da0 (diff) | |
download | cpython-cd1fbbc81761dc26ce6daf724d57d48e965e5817.zip cpython-cd1fbbc81761dc26ce6daf724d57d48e965e5817.tar.gz cpython-cd1fbbc81761dc26ce6daf724d57d48e965e5817.tar.bz2 |
gh-91603: Speed up operator "|" for UnionType (GH-91955)
Reduce the complexity from O((M+N)^2) to O(M*N), where M and N are the length
of __args__ for both operands (1 for operand which is not a UnionType).
As a consequence, the complexity of parameter substitution in UnionType has
been reduced from O(N^3) to O(N^2).
Co-authored-by: Yurii Karabas <1998uriyyo@gmail.com>
Diffstat (limited to 'Python/pylifecycle.c')
0 files changed, 0 insertions, 0 deletions