Skip to content

Commit 892f3b0

Browse files
CopilotEdmondDantes
andcommitted
Address code review feedback - improve comments and logical grouping
Co-authored-by: EdmondDantes <1571649+EdmondDantes@users.noreply.github.com>
1 parent 5ede1d4 commit 892f3b0

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

coroutine.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1348,8 +1348,7 @@ METHOD(getTrace)
13481348

13491349
// Return empty array if coroutine is not suspended or has no fiber context
13501350
if (fiber_context == NULL ||
1351-
fiber_context->context.status != ZEND_FIBER_STATUS_SUSPENDED ||
1352-
!fiber_context->execute_data) {
1351+
(fiber_context->context.status != ZEND_FIBER_STATUS_SUSPENDED || !fiber_context->execute_data)) {
13531352
array_init(return_value);
13541353
return;
13551354
}
@@ -1362,7 +1361,7 @@ METHOD(getTrace)
13621361
EG(current_execute_data) = fiber_context->execute_data;
13631362

13641363
// Generate the backtrace using Zend's built-in function
1365-
// skip_last = 0 (don't skip any frames)
1364+
// skip_last = 0 (skip zero frames from the end of the trace)
13661365
zend_fetch_debug_backtrace(return_value, 0, (int)options, (int)limit);
13671366

13681367
// Restore original VM stack and execute data

0 commit comments

Comments
 (0)