June 2016: A much improved versin has been released.
PHP Debug is single API for tracing PHP applications. With a single file -- only 700 lines -- you can add, with minimal impact, diagnostics to be displayed upon program termination. Each diagnostic contains file, function and caller function information as well.
Just an API, not a class. Just include the debug.php file and add debug() calls throughout your code similar to var_dump().
However, the diagnostic messages are stored and displayed as a list at program termination. The diagnostics can be disabled and controlled in other ways. It's small and simple yet very versatile.
See the Github page to view the source code.
Be the first to post a review of PHP Debug API!