-
Notifications
You must be signed in to change notification settings - Fork 504
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
Infer object type mysqli_fetch_object #2675
Conversation
This pull request has been marked as ready for review. |
resources/functionMap.php
Outdated
@@ -7472,7 +7472,7 @@ | |||
'mysqli_fetch_field_direct' => ['object|false', 'result'=>'mysqli_result', 'fieldnr'=>'int'], | |||
'mysqli_fetch_fields' => ['array', 'result'=>'mysqli_result'], | |||
'mysqli_fetch_lengths' => ['array|false', 'result'=>'mysqli_result'], | |||
'mysqli_fetch_object' => ['object|null', 'result'=>'mysqli_result', 'class_name='=>'string', 'params='=>'?array'], | |||
'mysqli_fetch_object' => ['object|false|null', 'result'=>'mysqli_result', 'class_name='=>'class-string', 'params='=>'?array'], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
seem we were missing the possible false
type in php 7.2/7.3.
in newer versions it was already valid because of php8-stubs
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don’t sneak in narrower parameter types like this 😊
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ahh good point. just dropped the param type change
resources/functionMap.php
Outdated
@@ -7472,7 +7472,7 @@ | |||
'mysqli_fetch_field_direct' => ['object|false', 'result'=>'mysqli_result', 'fieldnr'=>'int'], | |||
'mysqli_fetch_fields' => ['array', 'result'=>'mysqli_result'], | |||
'mysqli_fetch_lengths' => ['array|false', 'result'=>'mysqli_result'], | |||
'mysqli_fetch_object' => ['object|null', 'result'=>'mysqli_result', 'class_name='=>'string', 'params='=>'?array'], | |||
'mysqli_fetch_object' => ['object|false|null', 'result'=>'mysqli_result', 'class_name='=>'class-string', 'params='=>'?array'], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don’t sneak in narrower parameter types like this 😊
fixed conflicts |
Thank you. |
No description provided.