PHPackages                             tacoberu/hayo-ast - 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. tacoberu/hayo-ast

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

tacoberu/hayo-ast
=================

Abstract Syntax Tree (AST) implementation for the Hayo scripting language.

v0.1.5(1mo ago)01461MITPHPPHP &gt;=7.4

Since Mar 5Pushed 1mo agoCompare

[ Source](https://github.com/tacoberu/php-hayo-ast)[ Packagist](https://packagist.org/packages/tacoberu/hayo-ast)[ RSS](/packages/tacoberu-hayo-ast/feed)WikiDiscussions v0.1 Synced 1w ago

READMEChangelogDependencies (10)Versions (3)Used By (1)

Hayo AST
========

[](#hayo-ast)

Abstract Syntax Tree (AST) implementation for the Hayo scripting language in PHP.

> **Note:** This project is not useful on its own as it is a component of the [php-hayo](https://github.com/tacoberu/php-hayo) project.

Installation
------------

[](#installation)

Install via Composer:

```
composer require tacoberu/hayo-ast
```

Basic Usage
-----------

[](#basic-usage)

The library provides classes for representing various language constructs like expressions, scalars, lambdas, and scopes.

### Scalars

[](#scalars)

Represent basic values:

```
use Taco\Hayo\Scalar;

$int = Scalar::Int_(42);
$str = Scalar::Str_("Hello World");
$bool = Scalar::Bool_(true);

echo (string) $int; // 42 : Int
```

### Expressions

[](#expressions)

Expressions can be functional calls or binary operations:

```
use Taco\Hayo\Expr;
use Taco\Hayo\Scalar;

// Function call: str.len "Lorem"
$expr = Expr::Func_("str.len", [Scalar::Str_("Lorem")]);

// Binary operation: 1 + 2
$binExpr = Expr::Bin_(Scalar::Int_(1), "+", Scalar::Int_(2));
```

### References

[](#references)

You can track required symbols (references) in an expression:

```
$expr = Expr::Bin_('a', "+", Scalar::Int_(1));
print_r($expr->refs()); // ['a', '+']
```

License
-------

[](#license)

This project is licensed under the MIT License.

###  Health Score

35

—

LowBetter than 77% of packages

Maintenance89

Actively maintained with recent releases

Popularity11

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity26

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

Every ~44 days

Total

3

Last Release

53d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/1828339?v=4)[Martin Takáč](/maintainers/tacoberu)[@tacoberu](https://github.com/tacoberu)

---

Top Contributors

[![tacoberu](https://avatars.githubusercontent.com/u/1828339?v=4)](https://github.com/tacoberu "tacoberu (11 commits)")

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/tacoberu-hayo-ast/health.svg)

```
[![Health](https://phpackages.com/badges/tacoberu-hayo-ast/health.svg)](https://phpackages.com/packages/tacoberu-hayo-ast)
```

###  Alternatives

[sandersander/composer-link

Adds ability to link local packages for development with composer

98457.9k](/packages/sandersander-composer-link)[carpcai/address-parser

A PHP library covers PHP 5.4 to 7.3, split an address street to street, states, city, zipcode.

1425.5k](/packages/carpcai-address-parser)

PHPackages © 2026

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