PHPackages                             xp-lang/php-switch-expression - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. xp-lang/php-switch-expression

ArchivedLibrary[Utility &amp; Helpers](/categories/utility)

xp-lang/php-switch-expression
=============================

Switch expression for PHP

v1.0.2(5y ago)06BSD-3-ClausePHP &gt;=7.0.0

Since Sep 9Pushed 5y ago2 watchersCompare

[ Source](https://github.com/xp-lang/php-switch-expression)[ Packagist](https://packagist.org/packages/xp-lang/php-switch-expression)[ Docs](http://xp-framework.net/)[ RSS](/packages/xp-lang-php-switch-expression/feed)WikiDiscussions master Synced 2mo ago

READMEChangelog (6)Dependencies (3)Versions (7)Used By (0)

Switch expression for PHP
=========================

[](#switch-expression-for-php)

Obsolete and replaced by [PHP 8 match expressions](https://github.com/xp-framework/compiler/pull/87). Code is retained in [release branch](https://github.com/xp-lang/php-switch-expression/tree/release).

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~78 days

Recently: every ~97 days

Total

6

Last Release

2043d ago

Major Versions

v0.3.0 → v1.0.02019-11-30

PHP version history (2 changes)v0.1.0PHP &gt;=7.0.0

v0.2.0PHP &gt;=5.6.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/07d18d882c8b4aaf3466432f64018214f2771eda333202175431ee7233795376?d=identicon)[thekid](/maintainers/thekid)

---

Top Contributors

[![thekid](https://avatars.githubusercontent.com/u/696742?v=4)](https://github.com/thekid "thekid (23 commits)")

---

Tags

languagemodulexp

### Embed Badge

![Health badge](/badges/xp-lang-php-switch-expression/health.svg)

```
[![Health](https://phpackages.com/badges/xp-lang-php-switch-expression/health.svg)](https://phpackages.com/packages/xp-lang-php-switch-expression)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
