View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0002027||Xdebug||Code Coverage||public||2021-10-04 20:50||2023-11-07 14:26|
|Summary||0002027: Branch/path code coverage for traits drops trait name since 3.1.0|
Relates to https://bugs.xdebug.org/view.php?id=1938
In versions of Xdebug prior to 3.1.0, traits and classes were treated the same from an output point of view. Under the functions key, there would be an array with each entry being of the format FQCN->methodName.
With Xdebug 3.1, the FQCN part is no longer included for traits.
Desired (assuming the annotation has to stay):
|Steps To Reproduce|
The testcase from https://bugs.xdebug.org/view.php?id=1938 will show this
|Tags||No tags attached.|
When analysing code, the scope is the trait name. While the code is running, the method has been copied into the class, and the scope is the class name.
I cheated earlier and removed the scope name to make code coverage work.
This "fix" is more of a plaster. We now remember the original scope and then add it when returning information.
PHP doesn't remember the original trait scope yet, but we might fix that as part of this PR: https://github.com/php/php-src/pull/12129/files.
|2021-10-04 20:50||dvdoug||New Issue|
|2021-12-08 11:19||derick||Status||new => acknowledged|
|2021-12-08 11:19||derick||Product Version||3.1.0 => 3.2dev|
|2023-11-07 14:26||derick||Assigned To||=> derick|
|2023-11-07 14:26||derick||Status||acknowledged => confirmed|
|2023-11-07 14:26||derick||Note Added: 0006673|
|2023-11-07 14:26||derick||Target Version||=> 3.3dev|