Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e670b2d

Browse files
committed
Issue #28727: Fix typo in pattern_richcompare()
Typo catched by Serhiy Storchaka, thanks!
1 parent 3a5d79f commit e670b2d

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Modules/_sre.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2688,7 +2688,7 @@ pattern_richcompare(PyObject *lefto, PyObject *righto, int op)
26882688

26892689
cmp = (left->flags == right->flags
26902690
&& left->isbytes == right->isbytes
2691-
&& left->codesize && right->codesize);
2691+
&& left->codesize == right->codesize);
26922692
if (cmp) {
26932693
/* Compare the code and the pattern because the same pattern can
26942694
produce different codes depending on the locale used to compile the

0 commit comments

Comments
 (0)