-
Notifications
You must be signed in to change notification settings - Fork 314
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
Old-style Closure dump format? #218
Comments
/cc @GrahamCampbell |
you could do this by adding a virtual prop, let's name it "signature", when you generate the signature of the closure in PHP style? |
Just acking this. So, you would also represent "use" right at their place
in the signature I believe. When default arg values are array, would you
present them on the same line, inlined?
|
What about this:
And in short mode (the default one), we hide everything but the signature?
I'd like to keep the |
@nicolas-grekas I'm all about removing redundant or obvious information where possible. We probably don't need to tell users that an anonymous function is an object of type Closure because all anonymous functions are objects of type Closure ;) Is there a straightforward way to render it just like before (or maybe with |
Fixed by symfony/symfony#27768 |
…s-grekas) This PR was merged into the 4.2-dev branch. Discussion ---------- [VarDumper] display the signature of callables | Q | A | ------------- | --- | Branch? | master | Bug fix? | no | New feature? | yes | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | bobthecow/psysh#218 | License | MIT | Doc PR | - E.g. ![capture d ecran de 2018-06-29 12-08-13](https://user-images.githubusercontent.com/243674/42087047-4fdc70d6-7b95-11e8-972c-216651bf7d69.png) or ![image](https://user-images.githubusercontent.com/243674/42086967-070bc960-7b95-11e8-9470-7e88f8acf12a.png) Commits ------- 73b4ac78c0 [VarDumper] display the signature of callables
…s-grekas) This PR was merged into the 4.2-dev branch. Discussion ---------- [VarDumper] display the signature of callables | Q | A | ------------- | --- | Branch? | master | Bug fix? | no | New feature? | yes | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | bobthecow/psysh#218 | License | MIT | Doc PR | - E.g. ![capture d ecran de 2018-06-29 12-08-13](https://user-images.githubusercontent.com/243674/42087047-4fdc70d6-7b95-11e8-972c-216651bf7d69.png) or ![image](https://user-images.githubusercontent.com/243674/42086967-070bc960-7b95-11e8-9470-7e88f8acf12a.png) Commits ------- 73b4ac7 [VarDumper] display the signature of callables
The new Closure formatting feels less intuitive and easily grokkable than before. Should we re-implement the function-signature-style formatting in terms of VarDumper? I took a look, but didn't get very far. @nicolas-grekas how tough would this be?
The text was updated successfully, but these errors were encountered: