xref: /ext-fiber/tests/debug-backtrace.phpt (revision 068e4ea3)
1--TEST--
2Print backtrace in fiber
3--EXTENSIONS--
4fiber
5--FILE--
6<?php
7
8function inner_function(): void
9{
10    debug_print_backtrace();
11}
12
13$fiber = new Fiber(function (): void {
14    inner_function();
15});
16
17$fiber->start();
18
19?>
20--EXPECTF--
21#0  inner_function() called at [%sdebug-backtrace.php:9]
22#1  {closure}()
23#2  Fiber->start() called at [%sdebug-backtrace.php:12]
24