PHPackages                             kedniko/php-parser-closure - 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. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. kedniko/php-parser-closure

ActiveLibrary[Parsing &amp; Serialization](/categories/parsing)

kedniko/php-parser-closure
==========================

v0.0.1(3y ago)1114PHPPHP &gt;=7.4

Since Mar 31Pushed 2y ago1 watchersCompare

[ Source](https://github.com/kedniko/php-parser-closure)[ Packagist](https://packagist.org/packages/kedniko/php-parser-closure)[ RSS](/packages/kedniko-php-parser-closure/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (2)Versions (2)Used By (0)

PHP Parser Closure (work in progress)
=====================================

[](#php-parser-closure-work-in-progress)

Quick Start
-----------

[](#quick-start)

```
$parser = new \Kedniko\PhpParserClosure\PhpParserClosure();

$closure = function (int $number) {
  return $number * 2;
};

$parser->parse($closure);
$code = $parser->getCode();

echo $code;
// "function (int $number) {
//   return $number * 2;
// }"
```

Under the hood this library uses [nikic/php-parser](https://github.com/nikic/PHP-Parser).

###  Health Score

20

—

LowBetter than 14% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity11

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity34

Early-stage or recently created project

 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

Unknown

Total

1

Last Release

1143d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/f1bd1a72ee820af31b4d1ce0d752edf435a660d9a3c573cc8ca812cf9fa3e00a?d=identicon)[kedniko](/maintainers/kedniko)

---

Top Contributors

[![kedniko](https://avatars.githubusercontent.com/u/42846752?v=4)](https://github.com/kedniko "kedniko (2 commits)")

###  Code Quality

TestsPest

### Embed Badge

![Health badge](/badges/kedniko-php-parser-closure/health.svg)

```
[![Health](https://phpackages.com/badges/kedniko-php-parser-closure/health.svg)](https://phpackages.com/packages/kedniko-php-parser-closure)
```

###  Alternatives

[ajthinking/archetype

Programmatically edit PHP and Laravel files.

2723.4M12](/packages/ajthinking-archetype)[jolicode/automapper

JoliCode AutoMapper

213439.4k7](/packages/jolicode-automapper)[json-mapper/json-mapper

Map JSON structures to PHP classes

2181.1M22](/packages/json-mapper-json-mapper)[goaop/parser-reflection

Provides reflection information, based on raw source

1003.4M4](/packages/goaop-parser-reflection)[psx/schema

Parse and generate data schema formats

57238.7k18](/packages/psx-schema)[corveda/php-sandbox

A PHP library that can be used to run PHP code in a sandboxed environment

23483.5k2](/packages/corveda-php-sandbox)

PHPackages © 2026

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