Skip to content

Commit

Permalink
- Added the xdebug_time_index() function.
Browse files Browse the repository at this point in the history
SVN Rev: 727
  • Loading branch information
derickr committed Jun 28, 2003
1 parent c7310fc commit f192a9b
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 1 deletion.
4 changes: 4 additions & 0 deletions NEWS
@@ -1,5 +1,9 @@
???, ??? ??, 2003 - xdebug 1.3.0

+ Implemented xdebug_time_index() which returns the time passed since the
start of the script. This change also changes the output of the tracing
functions as the start time will no longer be the first function call, but
the real start time of the script. (Derick)
+ Implemented the "show-local" command (shows all local variables in the
current scope including all contents). (Derick)
+ Implemented conditions for breakpoints in the "break" command. (Derick)
Expand Down
3 changes: 2 additions & 1 deletion php_xdebug.h
Expand Up @@ -81,14 +81,15 @@ PHP_FUNCTION(xdebug_is_enabled);
PHP_FUNCTION(xdebug_start_trace);
PHP_FUNCTION(xdebug_stop_trace);
PHP_FUNCTION(xdebug_get_function_trace);
PHP_FUNCTION(xdebug_dump_function_trace);

/* misc functions */
PHP_FUNCTION(xdebug_dump_function_trace);
PHP_FUNCTION(xdebug_dump_superglobals);
PHP_FUNCTION(xdebug_set_error_handler);
#if MEMORY_LIMIT
PHP_FUNCTION(xdebug_memory_usage);
#endif
PHP_FUNCTION(xdebug_time_index);


void xdebug_start_trace();
Expand Down
6 changes: 6 additions & 0 deletions xdebug.c
Expand Up @@ -95,6 +95,7 @@ function_entry xdebug_functions[] = {
#if MEMORY_LIMIT
PHP_FE(xdebug_memory_usage, NULL)
#endif
PHP_FE(xdebug_time_index, NULL)

PHP_FE(xdebug_start_code_coverage, NULL)
PHP_FE(xdebug_stop_code_coverage, NULL)
Expand Down Expand Up @@ -1435,6 +1436,11 @@ PHP_FUNCTION(xdebug_memory_usage)
}
#endif

PHP_FUNCTION(xdebug_time_index)
{
RETURN_DOUBLE(get_utime() - XG(start_time));
}

PHP_FUNCTION(xdebug_set_error_handler)
{
char *handler;
Expand Down

0 comments on commit f192a9b

Please sign in to comment.