Skip to content
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

multiline array shape not merged? #38

Closed
orklah opened this issue Mar 15, 2020 · 6 comments
Closed

multiline array shape not merged? #38

orklah opened this issue Mar 15, 2020 · 6 comments

Comments

@orklah
Copy link

orklah commented Mar 15, 2020

Hi, I have a multiline array shape in a project that doesn't seem to be parsed.

When searching for an answer, I found #33 that do exactly that.

However, as though this was supposed to be merged according to
phpstan/phpstan#2497 (comment)
and
#33 (comment)

The actual commit was pretty empty:
18b0e92

and I can't find the content of the PR on master.

For example:
/~https://github.com/shmax/phpdoc-parser/blob/17d28cc099984a5ecbbbfb7b102daa45ce1af62f/tests/PHPStan/Parser/TypeParserTest.php#L481
/~https://github.com/shmax/phpdoc-parser/blob/master/tests/PHPStan/Parser/TypeParserTest.php#L481
should be the same

/~https://github.com/shmax/phpdoc-parser/blob/17d28cc099984a5ecbbbfb7b102daa45ce1af62f/src/Parser/TypeParser.php#L224
/~https://github.com/shmax/phpdoc-parser/blob/master/src/Parser/TypeParser.php#L224
too.

Was this reverted afterward?

@ondrejmirtes
Copy link
Member

Hi, can you post an example on phpstan.org what doesn't get parsed in your case?

@orklah
Copy link
Author

orklah commented Mar 15, 2020

@ondrejmirtes
Copy link
Member

It's just that you can't put the newline anywhere. This works: https://phpstan.org/r/22622ed0-2a45-40c0-bb7a-e7567be39fee

@ondrejmirtes
Copy link
Member

Also look into the feature of type aliases (/~https://github.com/phpstan/phpstan/releases/tag/0.12.9), you might like it :)

@orklah
Copy link
Author

orklah commented Mar 15, 2020

Thanks :)

Types aliase could indeed be handy for my use-case :)

@github-actions
Copy link

github-actions bot commented May 1, 2021

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 1, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants