debug_print_backtrace

(PHP 5, PHP 7)

debug_print_backtrace ��ӡһ�����ݡ�

˵��

debug_print_backtrace ([ int $options = 0 [, int $limit = 0 ]] ) : void

debug_print_backtrace() ��ӡ��һ�� PHP ���ݡ�����ӡ�˺������á��� included/required ���ļ��� eval() �Ĵ��롣

����

options

�� 5.3.6 ��ʼ���������������ѡ���λ���룺

debug_print_backtrace() ѡ��
DEBUG_BACKTRACE_IGNORE_ARGS �Ƿ���� "args" ���������������е� function/method �IJ������ܹ���ʡ�ڴ濪����

limit

�� 5.4.0 ��ʼ����������ܹ��������Ʒ��ض�ջ֡�������� Ĭ��Ϊ (limit=0) ���������еĶ�ջ֡��

����ֵ

û�з���ֵ��

������־

�汾 ˵��
5.4.0 ����˿�ѡ�IJ��� limit��
5.3.6 ����˿�ѡ�IJ��� options��

����

Example #1 debug_print_backtrace() ����

<?php
// include.php file

function a() {
    
b();
}

function 
b() {
    
c();
}

function 
c(){
    
debug_print_backtrace();
}

a();

?>
<?php
// �ļ� test.php
// ������Ӧ�����е��ļ�

include 'include.php';
?>

�������̵���������ڣ�

#0  c() called at [/tmp/include.php:10]
#1  b() called at [/tmp/include.php:6]
#2  a() called at [/tmp/include.php:17]
#3  include(/tmp/include.php) called at [/tmp/test.php:3]

�μ�