Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

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

infinite loop in never returning function is allowed #4516

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
canvural wants to merge 1 commit into phpstan:2.1.x
base: 2.1.x
Choose a base branch
Loading
from canvural:never-infinite-loop

Conversation

@canvural
Copy link
Contributor

@canvural canvural commented Nov 2, 2025
edited
Loading

Doing an infinite loop in a function that never returns is a valid use case.

closes phpstan/phpstan#6458
closes phpstan/phpstan#12813

Copy link
Contributor

staabm commented Nov 2, 2025
edited
Loading

see https://github.com/phpstan/phpstan-src/actions/runs/19016009464 how this change affects other open bug reports

canvural reacted with thumbs up emoji

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

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

while.alwaysTrue reported in :never method Allow infinite loops inside never return methods and functions

2 participants

AltStyle によって変換されたページ (->オリジナル) /