Hi internals,

I'd like to gauge interest in adding two debugging functions to PHP core:
dd() and dump().

*Background*
Currently, developers rely on userland solutions like Laravel's dd() helper
or Symfony's VarDumper for enhanced debugging output. These tools are
widely adopted across the PHP ecosystem, suggesting strong demand for
better debugging primitives.


*Proposal Overview*- dd($var, ...$vars) - "dump and die" - outputs
formatted debug info and terminates execution
- dump($var, ...$vars) - outputs formatted debug info and continues
execution


*Enhanced Features Over Existing Solutions*- Native performance (no
userland overhead)
- Stack trace integration
- Memory usage reporting
- Execution timing (potentially)
- Better CLI formatting


*Why Core vs Userland?*Similar to how var_dump() provides basic
introspection, these functions would offer enhanced debugging capabilities
that benefit the entire ecosystem, not just framework users.

*Implementation*
I'm seeking collaboration with an experienced PHP core developer for the C
implementation. I can handle the RFC documentation, testing, etc. I have
experience with the Laravel/Symfony codebases.


*Before drafting a formal RFC, I'd appreciate feedback on:*1. General
appetite for enhanced debugging functions in core
2. Concerns about naming conflicts with existing userland helpers
3. Preferred feature scope

Thoughts?

Best regards,
Braunson Yager

Reply via email to