Skip to content

gen_stub: Also verify implementation-alias #6615

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

Closed
wants to merge 1 commit into from

Conversation

nikic
Copy link
Member

@nikic nikic commented Jan 18, 2021

This makes --verify also check @implementation-alias. Failures are ignored using @no-verify instead. Some mistakes have been made that would have been caught by this...

There is one remaining failure:

SplFileObject::__toString() and SplFileObject::fgets() must have the same return type

Another example of great terrible API design in SPL. Converting a file into a string returns ... the current line. Which can return false. Probably the alias here needs to be dropped and we should return "" instead of false.

@nikic
Copy link
Member Author

nikic commented Jan 18, 2021

@kocsismate What do you think about this?

@nikic
Copy link
Member Author

nikic commented Jan 18, 2021

The SplFileObject issue is fixed by f2364f3. It turns out that fgets() can't actually return false here, so we can make the return types line up.

@kocsismate
Copy link
Member

Sounds like a good idea! :)

@php-pulls php-pulls closed this in a9efcb1 Jan 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants