Skip to content

refactor: remove filter functionality - #55

Merged
carlos-granados merged 3 commits into
php-debugger:mainfrom
carlos-granados:refactor/remove-filters
May 2, 2026
Merged

carlos-granados merged 3 commits into
php-debugger:mainfrom
carlos-granados:refactor/remove-filters

Conversation

@carlos-granados

@carlos-granados carlos-granados commented Apr 15, 2026 •

Copy link
Copy Markdown
Collaborator

The filters were only used in code coverage, stack traces in develop mode, and tracing, they are not used at all for debugging, so I removed all this extra code, including tests

@carlos-granados
carlos-granados force-pushed the refactor/remove-filters branch from 71e7fe0 to 084c9bf Compare April 18, 2026 06:55
@pronskiy

Copy link
Copy Markdown
Member

You can probably remove this thing from lib.h:
/* filter properties */
unsigned char filtered_stack;

@carlos-granados
carlos-granados force-pushed the refactor/remove-filters branch from d917c5f to 943fa04 Compare April 19, 2026 19:35
@carlos-granados

Copy link
Copy Markdown
Collaborator Author

You can probably remove this thing from lib.h: /* filter properties */ unsigned char filtered_stack;

Thanks, updated

@carlos-granados
carlos-granados force-pushed the refactor/remove-filters branch from 943fa04 to 4838acc Compare April 19, 2026 21:05
# Conflicts:
#	config.m4
#	config.w32
#	src/base/filter.c

# Conflicts:
#	src/base/base.c
@carlos-granados
carlos-granados force-pushed the refactor/remove-filters branch from 4838acc to d7b767f Compare April 22, 2026 16:18
@pronskiy

pronskiy commented May 1, 2026

Copy link
Copy Markdown
Member
  1. these in src/base/base_globals.h:81-83 probably redundant:
/* filters */
zend_long     filter_type_stack;
xdebug_llist *filters_stack;

For keeping BC, how about adding xdebug_set_filter() stub to src/lib/compat_stubs.c/h ?

Also for BC sakes, makes sense to keep the constants, but just move them to compat_stubs:
XDEBUG_FILTER_, XDEBUG_PATH_, XDEBUG_NAMESPACE_*

wdyt?

@carlos-granados

Copy link
Copy Markdown
Collaborator Author
  1. these in src/base/base_globals.h:81-83 probably redundant:
/* filters */
zend_long     filter_type_stack;
xdebug_llist *filters_stack;

Removed

For keeping BC, how about adding xdebug_set_filter() stub to src/lib/compat_stubs.c/h ?

Also for BC sakes, makes sense to keep the constants, but just move them to compat_stubs: XDEBUG_FILTER__, XDEBUG_PATH__, XDEBUG_NAMESPACE_*

wdyt?

Good shout, added back to compat_stubs

@carlos-granados
carlos-granados requested a review from pronskiy May 2, 2026 16:40
@pronskiy

pronskiy commented May 2, 2026

Copy link
Copy Markdown
Member

👍

@carlos-granados
carlos-granados merged commit 67ac685 into php-debugger:main May 2, 2026
14 checks passed
@carlos-granados
carlos-granados deleted the refactor/remove-filters branch May 2, 2026 21:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants