Avoid duplicate visit in check_boolean_op() by ilevkivskyi · Pull Request #19515 · python/mypy

Skip to content

Navigation Menu

Sign in

Appearance settings

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

Appearance settings

Conversation

@ilevkivskyi

Copy link Copy Markdown

Member

Surprisingly, this simple change gives 0.5-1% perf boost on self-check (for some reasons this is quite hot function).

@github-actions

Copy link Copy Markdown

Contributor

According to mypy_primer, this change doesn't affect type check results on a corpus of open source code. ✅

@ilevkivskyi

Copy link Copy Markdown

Member Author

This one is kind of trivial/obvious, so I will just go ahead and merge it.

@ilevkivskyi ilevkivskyi merged commit 31adfb4 into python:master

Jul 26, 2025

20 checks passed

@ilevkivskyi ilevkivskyi deleted the no-dup-bool-op branch

July 26, 2025 23:29

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@JukkaL JukkaL Awaiting requested review from JukkaL

@hauntsaninja hauntsaninja Awaiting requested review from hauntsaninja

@sterliakov sterliakov Awaiting requested review from sterliakov

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

1 participant

@ilevkivskyi