Open-Awesome
CategoriesAlternativesStacksSelf-HostedExplore
Open-Awesome

© 2026 Open-Awesome. Curated for the developer elite.

TermsPrivacyAboutGitHubRSS
  1. Home
  2. Static Analysis & Code Quality
  3. Tuli

Tuli

MITPHP

A static analysis engine for PHP that detects type mismatches in function arguments, return values, and method calls.

GitHubGitHub
169 stars7 forks0 contributors

What is Tuli?

Tuli is a static analysis engine for PHP that automatically detects type mismatches in function arguments, return values, and method calls. It analyzes PHP source code to identify potential type errors before code execution, helping developers maintain type safety in their codebases.

Target Audience

PHP developers working with typed codebases who want to catch type-related bugs early, particularly those using PHP's type hinting features in functions and methods.

Value Proposition

Tuli provides focused, practical type analysis specifically for PHP, with inheritance-aware checking that handles complex class hierarchies and type widening scenarios that simpler linters might miss.

Overview

A static analysis engine

Use Cases

Best For

  • Detecting type mismatches in PHP function arguments
  • Verifying return type consistency in typed PHP functions
  • Analyzing method call type safety across inheritance hierarchies
  • Catching float-to-int conversion issues in PHP code
  • Validating type hints in legacy PHP codebases
  • Preventing runtime type errors through static analysis

Not Ideal For

  • Projects needing comprehensive static analysis beyond type checking, such as code style or security vulnerability detection
  • Teams requiring out-of-the-box integration with IDEs or CI/CD pipelines without custom setup
  • Codebases that do not use PHP type hints extensively, as Tuli relies on declared types for analysis
  • Production environments prioritizing stability, since Tuli is installed via 'dev-master' and may have breaking changes

Pros & Cons

Pros

Focused Type Analysis

Specializes in detecting type mismatches in function arguments and return values, as shown in the example where it catches float-to-int conversions in function calls.

Inheritance-Aware Checking

Handles complex class hierarchies by analyzing all possible method definitions, ensuring type safety across inheritance, demonstrated in the second example with classes A, B, and C.

Easy Composer Integration

Installation is straightforward via Composer with a single command, making it simple to add to existing PHP projects without complex setup.

Practical Error Detection

Prioritizes real-world type errors over theoretical completeness, catching issues like missing return statements in typed functions, as indicated in the output examples.

Cons

Incomplete Feature Set

The README explicitly states 'Todo: * A lot', indicating many planned features are missing, limiting its scope compared to full-fledged static analyzers.

Development Instability

Installed via 'dev-master', suggesting it's in active development with potential unstable releases or breaking changes, not ideal for production use.

Limited Documentation

The README is brief and primarily provides examples; lack of comprehensive documentation could hinder advanced usage, configuration, or troubleshooting.

Narrow Focus

Only checks type-related issues and does not cover other static analysis aspects like code smells or performance issues, necessitating additional tools for broader analysis.

Frequently Asked Questions

Quick Stats

Stars169
Forks7
Contributors0
Open Issues7
Last commit10 years ago
CreatedSince 2015

Tags

#composer#developer-tools#bug-detection#code-quality#type-checking#php#linting#static-analysis

Built With

C
Composer
P
PHP

Included in

Static Analysis & Code Quality14.5k
Auto-fetched 15 hours ago

Related Projects

PHP ParserPHP Parser

A PHP parser written in PHP

Stars17,452
Forks1,129
Last commit13 days ago
TypeScript ESLintTypeScript ESLint

:sparkles: Monorepo for all the tooling which enables ESLint to support TypeScript

Stars16,320
Forks2,952
Last commit1 day ago
pyrightpyright

Static Type Checker for Python

Stars15,545
Forks1,797
Last commit3 days ago
ReviewdogReviewdog

🐶 Automated code review tool integrated with any code analysis tools regardless of programming language

Stars9,474
Forks490
Last commit19 hours ago
Community-curated · Updated weekly · 100% open source

Found a gem we're missing?

Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.

Submit a projectStar on GitHub