Skip to content

HybridParser is now StackParser, with a deprecated alias - #137

Merged
thunderer merged 1 commit into
masterfrom
tk-stack-parser
Nov 13, 2026
Merged

thunderer merged 1 commit into
masterfrom
tk-stack-parser

Conversation

@thunderer

Copy link
Copy Markdown
Owner

Renames HybridParser to StackParser before tagging 0.8, as agreed in #135. HybridParser stays as a deprecated alias until 2.x.

  • HybridParser renamed to StackParser,
  • HybridParser kept as a deprecated alias, which also works with an authoritative Composer classmap,
  • every test of StackParser also runs with HybridParser,
  • tests cover the alias in both directions, including loading HybridParser before StackParser,
  • benchmarks keep the hybrid key, so this PR still compares with the base branch.

@github-actions

Copy link
Copy Markdown

Merging this PR will not alter performance

Benchmark ⚡ improved ❌ regressed ✅ untouched 🆕 new
ProcessorBench 0 0 8 0
ParserBench 0 0 20 0

A benchmark is changed when its efficiency (BASE / HEAD - 1) is at least 10% in either direction.

All benchmarks
+----------------+--------------+--------------------+------+-----+----------------+------------------+-----------------+
| benchmark      | subject      | set                | revs | its | mem_peak       | mode             | rstdev          |
+----------------+--------------+--------------------+------+-----+----------------+------------------+-----------------+
| ProcessorBench | benchProcess | regular article    | 1    | 5   | 3.884mb 0.00%  | 123.821ms -0.01% | ±0.56% -52.97%  |
| ProcessorBench | benchProcess | regular dense      | 1    | 5   | 16.017mb 0.00% | 184.065ms +0.19% | ±0.50% +156.64% |
| ProcessorBench | benchProcess | regular nested     | 1    | 5   | 5.821mb 0.00%  | 134.765ms -0.06% | ±0.37% +117.16% |
| ProcessorBench | benchProcess | regular deep       | 1    | 5   | 2.516mb 0.00%  | 208.534ms +0.09% | ±0.22% -86.99%  |
| ProcessorBench | benchProcess | hybrid article     | 1    | 5   | 2.125mb 0.00%  | 157.416ms -0.29% | ±0.27% -2.77%   |
| ProcessorBench | benchProcess | hybrid dense       | 1    | 5   | 4.206mb +0.05% | 163.915ms +0.24% | ±0.26% +65.00%  |
| ProcessorBench | benchProcess | hybrid nested      | 1    | 5   | 2.542mb +0.08% | 181.662ms -0.08% | ±0.18% -19.84%  |
| ProcessorBench | benchProcess | hybrid deep        | 1    | 5   | 2.315mb +0.08% | 99.544ms -0.04%  | ±0.25% -83.00%  |
| ParserBench    | benchParse   | regular article    | 1    | 5   | 4.540mb 0.00%  | 132.691ms +0.01% | ±0.77% -8.89%   |
| ParserBench    | benchParse   | regular dense      | 1    | 5   | 6.204mb 0.00%  | 123.945ms +0.85% | ±0.72% +83.47%  |
| ParserBench    | benchParse   | regular nested     | 1    | 5   | 7.011mb 0.00%  | 196.556ms -0.26% | ±0.40% -33.81%  |
| ParserBench    | benchParse   | regular deep       | 1    | 5   | 9.338mb 0.00%  | 131.502ms +0.08% | ±0.55% -31.30%  |
| ParserBench    | benchParse   | regular brackets   | 1    | 5   | 12.082mb 0.00% | 109.042ms -0.00% | ±0.83% +5.75%   |
| ParserBench    | benchParse   | regex article      | 1    | 5   | 2.125mb 0.00%  | 176.903ms +0.09% | ±0.39% +19.64%  |
| ParserBench    | benchParse   | regex dense        | 1    | 5   | 2.294mb 0.00%  | 122.930ms +0.20% | ±0.46% +14.42%  |
| ParserBench    | benchParse   | regex nested       | 1    | 5   | 2.125mb 0.00%  | 121.404ms +0.40% | ±0.33% -41.05%  |
| ParserBench    | benchParse   | regex deep         | 1    | 5   | 2.125mb 0.00%  | 149.136ms -0.33% | ±0.52% +109.91% |
| ParserBench    | benchParse   | regex brackets     | 1    | 5   | 3.005mb 0.00%  | 180.227ms -0.28% | ±0.06% -97.09%  |
| ParserBench    | benchParse   | hybrid article     | 1    | 5   | 2.125mb 0.00%  | 139.395ms +0.05% | ±0.32% -68.42%  |
| ParserBench    | benchParse   | hybrid dense       | 1    | 5   | 2.182mb +0.09% | 93.705ms -0.37%  | ±0.38% -28.87%  |
| ParserBench    | benchParse   | hybrid nested      | 1    | 5   | 2.395mb +0.08% | 203.136ms +0.11% | ±1.05% -18.19%  |
| ParserBench    | benchParse   | hybrid deep        | 1    | 5   | 3.474mb +0.06% | 213.856ms -0.28% | ±1.53% +151.58% |
| ParserBench    | benchParse   | hybrid brackets    | 1    | 5   | 3.010mb +0.06% | 198.414ms +1.17% | ±1.28% +88.45%  |
| ParserBench    | benchParse   | wordpress article  | 1    | 5   | 2.125mb 0.00%  | 100.299ms -0.02% | ±0.57% +20.93%  |
| ParserBench    | benchParse   | wordpress dense    | 1    | 5   | 2.125mb 0.00%  | 190.277ms +0.03% | ±0.57% -4.52%   |
| ParserBench    | benchParse   | wordpress nested   | 1    | 5   | 2.125mb 0.00%  | 107.701ms -0.22% | ±0.86% +169.46% |
| ParserBench    | benchParse   | wordpress deep     | 1    | 5   | 2.125mb 0.00%  | 115.459ms -0.20% | ±0.17% +16.35%  |
| ParserBench    | benchParse   | wordpress brackets | 1    | 5   | 2.966mb 0.00%  | 101.368ms -0.22% | ±1.20% -18.74%  |
+----------------+--------------+--------------------+------+-----+----------------+------------------+-----------------+

Comparing tk-stack-parser (6ab06d1) with master (4623196)

@thunderer
thunderer merged commit 5f4d792 into master Nov 13, 2026
18 checks passed
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.

1 participant