[
https://issues.apache.org/jira/browse/THRIFT-5983?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Volodymyr Panivko updated THRIFT-5983:
--------------------------------------
Parent: THRIFT-5960
Issue Type: Sub-task (was: Improvement)
> Replace switch with match expression in PHP TProtocol::skip and skipBinary
> --------------------------------------------------------------------------
>
> Key: THRIFT-5983
> URL: https://issues.apache.org/jira/browse/THRIFT-5983
> Project: Thrift
> Issue Type: Sub-task
> Components: PHP - Library
> Reporter: Volodymyr Panivko
> Priority: Minor
> Time Spent: 10m
> Remaining Estimate: 0h
>
> Refactor PHP runtime `lib/php/lib/Protocol/TProtocol.php`:
> - Convert `switch ($type)` in `skip()` to `match` expression
> - Convert `switch ($type)` in `skipBinary()` to `match` expression
> Match expressions enforce exhaustive case handling (no fall-through bugs),
> use strict comparison (===), and naturally throw `UnhandledMatchError` on
> unknown values — but here we keep an explicit `TProtocolException` to
> preserve the existing API contract.
> This is a follow-up to THRIFT-5981 within the umbrella THRIFT-5960 (PHP
> modernization).
--
This message was sent by Atlassian Jira
(v8.20.10#820010)