Skip to content
New issue

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

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

Already on GitHub? # to your account

\array is not array #343

Closed
snapshotpl opened this issue Apr 19, 2022 · 7 comments
Closed

\array is not array #343

snapshotpl opened this issue Apr 19, 2022 · 7 comments

Comments

@snapshotpl
Copy link

#333 introduces change where return type with array is defined as:

@return \array Returns an array.

phpstan doesn't recognize now it as array, so it's break things

@Kharhamel
Copy link
Collaborator

oh no :(

@Kharhamel
Copy link
Collaborator

I switched the tag 2.2 to pre-release, hopefully that will give us some time. But i am not really sure how to fix this. @j3j5 do you have an idea?

@Kharhamel
Copy link
Collaborator

I think I am going to revert the j3j5 array rename PR and then i will create a beta to try his other strategy.

@j3j5
Copy link
Contributor

j3j5 commented Apr 19, 2022

Ok, I think it may be time to report this on the phpdocparser repo, let me put together an issue as soon as I have time.

For some reason I don't get any error when testing on the testing repo that was around, but I see now that phpstan doesn't support this form of return type (I should have checked earlier). Sorry about that :(

@j3j5
Copy link
Contributor

j3j5 commented Apr 19, 2022

I opened the issue on phpdoc-parser and although it was the wrong place to open it, it got some interesting insights on the replies, it may be that the issue was on larastan after all 🙈 Let's see what Ondrej thinks about the proposed solution, also, need to find the time to test bleeding edge with his version, it may be fixed there already (although from the comments, I think the issue is on larastan).

Anyway, I'd hold on on merging this until we get a bit further on the discussion.

@j3j5
Copy link
Contributor

j3j5 commented Apr 20, 2022

The comment above was meant for #338, anyway, looking at the responses by Jan on the other issue and after doing some more reading, I think he's right and the directory structure is wrong, so I believe #338 isn't the right answer either.

@Kharhamel
Copy link
Collaborator

I am closing this thread since the original issue was solved

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants