Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Introduce dump_die to directly output result #13657

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
Closed

Introduce dump_die to directly output result #13657

wants to merge 1 commit into from

Conversation

rvanlaak
Copy link
Contributor

Q A
Bug fix? no
New feature? yes
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets
License MIT
Doc PR symfony/symfony-docs#4988

@nicolas-grekas
Copy link
Member

This do not save a single keystroke... What about d() + dd()? I'm not sure others would agree though

@rvanlaak
Copy link
Contributor Author

Some other helpers would be usefull. Was inspired by the Ladybug Helpers

https://github.com/raulfraile/LadybugBundle#helpers

@fabpot
Copy link
Member

fabpot commented Feb 11, 2015

I don't see a big value in adding more "shortcuts"; it makes things more difficult to learn and more confusing IMO.

@stof
Copy link
Member

stof commented Feb 15, 2015

I agree with @fabpot here

@fabpot fabpot closed this Feb 16, 2015
@garf
Copy link

garf commented Jan 5, 2016

It makes debugging easier and It's a helper. There is no need to learn it. You can only discover it suddenly and become happy.

@ivoba
Copy link
Contributor

ivoba commented Nov 3, 2017

Uh i just wanted to open a PR for this.
I still think its a useful helper and would save me tons of typing "exit;".
With code completion this will save keystrokes.

Btw the implementation here wont work, it will show the line of the dump call, which is inside of dump_die.

@nicolas-grekas
Copy link
Member

For reference, this is being reconsidered in #26970.

fabpot added a commit that referenced this pull request Apr 19, 2018
…s-grekas)

This PR was merged into the 4.1-dev branch.

Discussion
----------

[VarDumper] Add dd() helper == dump() + exit()

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

By popular demand, I feel like we should reconsider our refusal for a `dd()` global helper.
For past references, see #26965, #26906, #13657, #17267, #19096.

Commits
-------

a55916a [VarDumper] Add dd() helper == dump() + die()
@ivoba
Copy link
Contributor

ivoba commented Apr 19, 2018

nice!
in the meantime i wrote https://github.com/ivoba/dump-die-shortcuts
and https://github.com/ivoba/dump-die
Hopefully obsolete soon :)

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.

6 participants