LICENSE 0000666 00000002057 13436755504 0005575 0 ustar 00 MIT License
Copyright (c) 2016 Ondřej Mirtes
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
README.md 0000666 00000061400 13436755504 0006044 0 ustar 00 # PHPStan - PHP Static Analysis Tool
[![Build Status](https://travis-ci.org/phpstan/phpstan.svg)](https://travis-ci.org/phpstan/phpstan)
[![Latest Stable Version](https://poser.pugx.org/phpstan/phpstan/v/stable)](https://packagist.org/packages/phpstan/phpstan)
[![License](https://poser.pugx.org/phpstan/phpstan/license)](https://packagist.org/packages/phpstan/phpstan)
[![PHPStan](https://img.shields.io/badge/PHPStan-enabled-brightgreen.svg?style=flat)](https://github.com/phpstan/phpstan)
[![Donate on PayPal](https://www.paypalobjects.com/en_US/i/btn/btn_donateCC_LG.gif)](https://paypal.me/phpstan)
PHPStan focuses on finding errors in your code without actually running it. It catches whole classes of bugs
even before you write tests for the code.
![PHPStan](build/phpstan.gif)
PHPStan moves PHP closer to compiled languages in the sense that the correctness of each line of the code
can be checked before you run the actual line.
**[Read more about PHPStan on Medium.com »](https://medium.com/@ondrejmirtes/phpstan-2939cd0ad0e3)**
**[Try out PHPStan on the on-line playground! »](https://phpstan.org/)**
## Is PHPStan helping you to avoid bugs in production?
## Consider [supporting it on Patreon](https://www.patreon.com/phpstan) so I'm able to make it even more awesome!
*I offer to issue invoices for contributions on PayPal and Patreon! [Contact me](mailto:ondrej@mirtes.cz) for details.*
It currently performs the following checks on your code:
* Existence of classes and interfaces in `instanceof`, `catch`, typehints, other language constructs and even annotations. PHP does not do this and just stays silent instead.
* Existence of variables while respecting scopes of branches and loops.
* Existence and visibility of called methods and functions.
* Existence and visibility of accessed properties and constants.
* Correct types assigned to properties.
* Correct number and types of parameters passed to constructors, methods and functions.
* Correct types returned from methods and functions.
* Correct number of parameters passed to `sprintf`/`printf` calls based on format strings.
* Useless casts like `(string) 'foo'`.
* Unused constructor parameters - they can either be deleted or the author forgot to
use them in the method body.
* Require calling `parent::__construct()` if the parent constructor exists.
* Only valid array key types are used (only integers, strings, floats, booleans and nulls).
* Duplicate array keys in literal arrays.
* Only iterables are passed to `foreach`.
* Correct case when referencing classes. Class names are case insensitive, but taking advantage of this is dangerous with autoloading on case-insensitive filesystems.
* Impossible checks (dead code) of incompatible types with `instanceof`, `===`, `!==` and various function checks like `is_int` or `is_null`.
* Always-defined and never-defined variables in `isset()` call.
* Validating phpDocs - finding incompatible types between phpDocs and native typehints.
* That only objects are passed to the `clone` keyword.
## Extensibility
Unique feature of PHPStan is the ability to define and statically check "magic" behaviour of classes -
accessing properties that are not defined in the class but are created in `__get` and `__set`
and invoking methods using `__call`.
See [Class reflection extensions](#class-reflection-extensions), [Dynamic return type extensions](#dynamic-return-type-extensions) and [Type-specifying extensions](#type-specifying-extensions).
You can also install official framework-specific extensions:
* [Doctrine](https://github.com/phpstan/phpstan-doctrine)
* [PHPUnit](https://github.com/phpstan/phpstan-phpunit)
* [Nette Framework](https://github.com/phpstan/phpstan-nette)
* [Dibi - Database Abstraction Library](https://github.com/phpstan/phpstan-dibi)
* [PHP-Parser](https://github.com/phpstan/phpstan-php-parser)
* [beberlei/assert](https://github.com/phpstan/phpstan-beberlei-assert)
* [webmozart/assert](https://github.com/phpstan/phpstan-webmozart-assert)
* [Symfony Framework](https://github.com/phpstan/phpstan-symfony)
* [Mockery](https://github.com/phpstan/phpstan-mockery)
Unofficial extensions for other frameworks and libraries are also available:
* [Phony](https://github.com/eloquent/phpstan-phony)
* [Prophecy](https://github.com/Jan0707/phpstan-prophecy)
* [Laravel](https://github.com/nunomaduro/larastan)
* [myclabs/php-enum](https://github.com/timeweb/phpstan-enum)
New extensions are becoming available on a regular basis!
## Prerequisites
PHPStan requires PHP >= 7.1. You have to run it in environment with PHP 7.x but the actual code does not have to use
PHP 7.x features. (Code written for PHP 5.6 and earlier can run on 7.x mostly unmodified.)
PHPStan works best with modern object-oriented code. The more strongly-typed your code is, the more information
you give PHPStan to work with.
Properly annotated and typehinted code (class properties, function and method arguments, return types) helps
not only static analysis tools but also other people that work with the code to understand it.
## Installation
To start performing analysis on your code, require PHPStan in [Composer](https://getcomposer.org/):
```
composer require --dev phpstan/phpstan
```
Composer will install PHPStan's executable in its `bin-dir` which defaults to `vendor/bin`.
If you have conflicting dependencies or you want to install PHPStan globally, the best way is via a PHAR archive. You will always find the latest stable PHAR archive below the [release notes](https://github.com/phpstan/phpstan/releases). You can also use the [phpstan/phpstan-shim](https://packagist.org/packages/phpstan/phpstan-shim) package to install PHPStan via Composer without the risk of conflicting dependencies.
You can also use [PHPStan via Docker](https://github.com/phpstan/docker-image).
## First run
To let PHPStan analyse your codebase, you have use the `analyse` command and point it to the right directories.
So, for example if you have your classes in directories `src` and `tests`, you can run PHPStan like this:
```bash
vendor/bin/phpstan analyse src tests
```
PHPStan will probably find some errors, but don't worry, your code might be just fine. Errors found
on the first run tend to be:
* Extra arguments passed to functions (e. g. function requires two arguments, the code passes three)
* Extra arguments passed to print/sprintf functions (e. g. format string contains one placeholder, the code passes two values to replace)
* Obvious errors in dead code
* Magic behaviour that needs to be defined. See [Extensibility](#extensibility).
After fixing the obvious mistakes in the code, look to the following section
for all the configuration options that will bring the number of reported errors to zero
making PHPStan suitable to run as part of your continuous integration script.
## Rule levels
If you want to use PHPStan but your codebase isn't up to speed with strong typing
and PHPStan's strict checks, you can choose from currently 8 levels
(0 is the loosest and 7 is the strictest) by passing `--level` to `analyse` command. Default level is `0`.
This feature enables incremental adoption of PHPStan checks. You can start using PHPStan
with a lower rule level and increase it when you feel like it.
You can also use `--level max` as an alias for the highest level. This will ensure that you will always use the highest level when upgrading to new versions of PHPStan. Please note that this can create a significant obstacle when upgrading to a newer version because you might have to fix a lot of code to bring the number of errors down to zero.
## Configuration
Config file is passed to the `phpstan` executable with `-c` option:
```bash
vendor/bin/phpstan analyse -l 4 -c phpstan.neon src tests
```
When using a custom project config file, you have to pass the `--level` (`-l`)
option to `analyse` command (default value does not apply here).
If you do not provide config file explicitly, PHPStan will look for
files named `phpstan.neon` or `phpstan.neon.dist` in current directory.
The resolution priority is as such:
1. If config file is provided on command line, it is used.
2. If config file `phpstan.neon` exists in current directory, it will be used.
3. If config file `phpstan.neon.dist` exists in current directory, it will be used.
4. If none of the above is true, no config will be used.
[NEON file format](https://ne-on.org/) is very similar to YAML.
All the following options are part of the `parameters` section.
#### Configuration variables
- `%rootDir%` - root directory where PHPStan resides (i.e. `vendor/phpstan/phpstan` in Composer installation)
- `%currentWorkingDirectory%` - current working directory where PHPStan was executed
#### Configuration options
- `tmpDir` - specifies the temporary directory used by PHPStan cache (defaults to `sys_get_temp_dir() . '/phpstan'`)
- `level` - specifies analysis level - if specified, `-l` option is not required
- `paths` - specifies analysed paths - if specified, paths are not required to be passed as arguments
### Autoloading
PHPStan uses Composer autoloader so the easiest way how to autoload classes
is through the `autoload`/`autoload-dev` sections in composer.json.
#### Specify paths to scan
If PHPStan complains about some non-existent classes and you're sure the classes
exist in the codebase AND you don't want to use Composer autoloader for some reason,
you can specify directories to scan and concrete files to include using
`autoload_directories` and `autoload_files` array parameters:
```
parameters:
autoload_directories:
- %rootDir%/../../../build
autoload_files:
- %rootDir%/../../../generated/routes/GeneratedRouteList.php
```
`%rootDir%` is expanded to the root directory where PHPStan resides.
#### Autoloading for global installation
PHPStan supports global installation using [`composer global`](https://getcomposer.org/doc/03-cli.md#global) or via a [PHAR archive](#installation).
In this case, it's not part of the project autoloader, but it supports autodiscovery of the Composer autoloader
from current working directory residing in `vendor/`:
```bash
cd /path/to/project
phpstan analyse src tests # looks for autoloader at /path/to/project/vendor/autoload.php
```
If you have your dependencies installed at a different path
or you're running PHPStan from a different directory,
you can specify the path to the autoloader with the `--autoload-file|-a` option:
```bash
phpstan analyse --autoload-file=/path/to/autoload.php src tests
```
### Exclude files from analysis
If your codebase contains some files that are broken on purpose
(e. g. to test behaviour of your application on files with invalid PHP code),
you can exclude them using the `excludes_analyse` array parameter. String at each line
is used as a pattern for the [`fnmatch`](https://secure.php.net/manual/en/function.fnmatch.php) function.
```
parameters:
excludes_analyse:
- %rootDir%/../../../tests/*/data/*
```
### Include custom extensions
If your codebase contains php files with extensions other than the standard .php extension then you can add them
to the `fileExtensions` array parameter:
```
parameters:
fileExtensions:
- php
- module
- inc
```
### Universal object crates
Classes without predefined structure are common in PHP applications.
They are used as universal holders of data - any property can be set and read on them. Notable examples
include `stdClass`, `SimpleXMLElement` (these are enabled by default), objects with results of database queries etc.
Use `universalObjectCratesClasses` array parameter to let PHPStan know which classes
with these characteristics are used in your codebase:
```
parameters:
universalObjectCratesClasses:
- Dibi\Row
- Ratchet\ConnectionInterface
```
### Add non-obviously assigned variables to scope
If you use some variables from a try block in your catch blocks, set `polluteCatchScopeWithTryAssignments` boolean parameter to `true`.
```php
try {
$author = $this->getLoggedInUser();
$post = $this->postRepository->getById($id);
} catch (PostNotFoundException $e) {
// $author is probably defined here
throw new ArticleByAuthorCannotBePublished($author);
}
```
If you are enumerating over all possible situations in if-elseif branches
and PHPStan complains about undefined variables after the conditions, you can write
an else branch with throwing an exception:
```php
if (somethingIsTrue()) {
$foo = true;
} elseif (orSomethingElseIsTrue()) {
$foo = false;
} else {
throw new ShouldNotHappenException();
}
doFoo($foo);
```
I recommend leaving `polluteCatchScopeWithTryAssignments` set to `false` because it leads to a clearer and more maintainable code.
### Custom early terminating method calls
Previous example showed that if a condition branches end with throwing an exception, that branch does not have
to define a variable used after the condition branches end.
But exceptions are not the only way how to terminate execution of a method early. Some specific method calls
can be perceived by project developers also as early terminating - like a `redirect()` that stops execution
by throwing an internal exception.
```php
if (somethingIsTrue()) {
$foo = true;
} elseif (orSomethingElseIsTrue()) {
$foo = false;
} else {
$this->redirect('homepage');
}
doFoo($foo);
```
These methods can be configured by specifying a class on whose instance they are called like this:
```
parameters:
earlyTerminatingMethodCalls:
Nette\Application\UI\Presenter:
- redirect
- redirectUrl
- sendJson
- sendResponse
```
### Ignore error messages with regular expressions
If some issue in your code base is not easy to fix or just simply want to deal with it later,
you can exclude error messages from the analysis result with regular expressions:
```
parameters:
ignoreErrors:
- '#Call to an undefined method [a-zA-Z0-9\\_]+::method\(\)#'
- '#Call to an undefined method [a-zA-Z0-9\\_]+::expects\(\)#'
- '#Access to an undefined property PHPUnit_Framework_MockObject_MockObject::\$[a-zA-Z0-9_]+#'
- '#Call to an undefined method PHPUnit_Framework_MockObject_MockObject::[a-zA-Z0-9_]+\(\)#'
```
If some of the patterns do not occur in the result anymore, PHPStan will let you know
and you will have to remove the pattern from the configuration. You can turn off
this behaviour by setting `reportUnmatchedIgnoredErrors` to `false` in PHPStan configuration.
### Bootstrap file
If you need to initialize something in PHP runtime before PHPStan runs (like your own autoloader),
you can provide your own bootstrap file:
```
parameters:
bootstrap: %rootDir%/../../../phpstan-bootstrap.php
```
### Custom rules
PHPStan allows writing custom rules to check for specific situations in your own codebase. Your rule class
needs to implement the `PHPStan\Rules\Rule` interface and registered as a service in the configuration file:
```
services:
-
class: MyApp\PHPStan\Rules\DefaultValueTypesAssignedToPropertiesRule
tags:
- phpstan.rules.rule
```
For inspiration on how to implement a rule turn to [src/Rules](https://github.com/phpstan/phpstan/tree/master/src/Rules)
to see a lot of built-in rules.
Check out also [phpstan-strict-rules](https://github.com/phpstan/phpstan-strict-rules) repository for extra strict and opinionated rules for PHPStan!
### Custom error formatters
By default, PHPStan outputs found errors into tables grouped by files to be easily human-readable. To change the output, you can use the `--error-format` CLI option. There's an additional built-in `raw` format with one-per-line errors intended for easy parsing. You can also create your own error formatter by implementing the `PHPStan\Command\ErrorFormatter\ErrorFormatter` interface:
```php
interface ErrorFormatter
{
/**
* Formats the errors and outputs them to the console.
*
* @param \PHPStan\Command\AnalysisResult $analysisResult
* @param \Symfony\Component\Console\Style\OutputStyle $style
* @return int Error code.
*/
public function formatErrors(
AnalysisResult $analysisResult,
\Symfony\Component\Console\Style\OutputStyle $style
): int;
}
```
Register the formatter in your `phpstan.neon`:
```
services:
errorFormatter.awesome:
class: App\PHPStan\AwesomeErrorFormatter
```
Use the name part after `errorFormatter.` as the CLI option value:
```bash
vendor/bin/phpstan analyse -c phpstan.neon -l 4 --error-format awesome src tests
```
## Class reflection extensions
Classes in PHP can expose "magical" properties and methods decided in run-time using
class methods like `__get`, `__set` and `__call`. Because PHPStan is all about static analysis
(testing code for errors without running it), it has to know about those properties and methods beforehand.
When PHPStan stumbles upon a property or a method that is unknown to built-in class reflection, it iterates
over all registered class reflection extensions until it finds one that defines the property or method.
Class reflection extension cannot have `PHPStan\Broker\Broker` (service for obtaining class reflections) injected in the constructor due to circular reference issue, but the extensions can implement `PHPStan\Reflection\BrokerAwareExtension` interface to obtain Broker via a setter.
### Properties class reflection extensions
This extension type must implement the following interface:
```php
namespace PHPStan\Reflection;
interface PropertiesClassReflectionExtension
{
public function hasProperty(ClassReflection $classReflection, string $propertyName): bool;
public function getProperty(ClassReflection $classReflection, string $propertyName): PropertyReflection;
}
```
Most likely you will also have to implement a new `PropertyReflection` class:
```php
namespace PHPStan\Reflection;
interface PropertyReflection
{
public function getType(): Type;
public function getDeclaringClass(): ClassReflection;
public function isStatic(): bool;
public function isPrivate(): bool;
public function isPublic(): bool;
}
```
This is how you register the extension in project's PHPStan config file:
```
services:
-
class: App\PHPStan\PropertiesFromAnnotationsClassReflectionExtension
tags:
- phpstan.broker.propertiesClassReflectionExtension
```
### Methods class reflection extensions
This extension type must implement the following interface:
```php
namespace PHPStan\Reflection;
interface MethodsClassReflectionExtension
{
public function hasMethod(ClassReflection $classReflection, string $methodName): bool;
public function getMethod(ClassReflection $classReflection, string $methodName): MethodReflection;
}
```
Most likely you will also have to implement a new `MethodReflection` class:
```php
namespace PHPStan\Reflection;
interface MethodReflection
{
public function getDeclaringClass(): ClassReflection;
public function getPrototype(): self;
public function isStatic(): bool;
public function isPrivate(): bool;
public function isPublic(): bool;
public function getName(): string;
/**
* @return \PHPStan\Reflection\ParameterReflection[]
*/
public function getParameters(): array;
public function isVariadic(): bool;
public function getReturnType(): Type;
}
```
This is how you register the extension in project's PHPStan config file:
```
services:
-
class: App\PHPStan\EnumMethodsClassReflectionExtension
tags:
- phpstan.broker.methodsClassReflectionExtension
```
## Dynamic return type extensions
If the return type of a method is not always the same, but depends on an argument passed to the method,
you can specify the return type by writing and registering an extension.
Because you have to write the code with the type-resolving logic, it can be as complex as you want.
After writing the sample extension, the variable `$mergedArticle` will have the correct type:
```php
$mergedArticle = $this->entityManager->merge($article);
// $mergedArticle will have the same type as $article
```
This is the interface for dynamic return type extension:
```php
namespace PHPStan\Type;
use PhpParser\Node\Expr\MethodCall;
use PHPStan\Analyser\Scope;
use PHPStan\Reflection\MethodReflection;
interface DynamicMethodReturnTypeExtension
{
public function getClass(): string;
public function isMethodSupported(MethodReflection $methodReflection): bool;
public function getTypeFromMethodCall(MethodReflection $methodReflection, MethodCall $methodCall, Scope $scope): Type;
}
```
And this is how you'd write the extension that correctly resolves the EntityManager::merge() return type:
```php
public function getClass(): string
{
return \Doctrine\ORM\EntityManager::class;
}
public function isMethodSupported(MethodReflection $methodReflection): bool
{
return $methodReflection->getName() === 'merge';
}
public function getTypeFromMethodCall(MethodReflection $methodReflection, MethodCall $methodCall, Scope $scope): Type
{
if (count($methodCall->args) === 0) {
return \PHPStan\Reflection\ParametersAcceptorSelector::selectFromArgs(
$scope,
$methodCall->args,
$methodReflection->getVariants()
)->getReturnType();
}
$arg = $methodCall->args[0]->value;
return $scope->getType($arg);
}
```
And finally, register the extension to PHPStan in the project's config file:
```
services:
-
class: App\PHPStan\EntityManagerDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicMethodReturnTypeExtension
```
There's also an analogous functionality for:
* **static methods** using `DynamicStaticMethodReturnTypeExtension` interface
and `phpstan.broker.dynamicStaticMethodReturnTypeExtension` service tag.
* **functions** using `DynamicFunctionReturnTypeExtension` interface and `phpstan.broker.dynamicFunctionReturnTypeExtension` service tag.
## Type-specifying extensions
These extensions allow you to specify types of expressions based on certain pre-existing conditions. This is best illustrated with couple examples:
```php
if (is_int($variable)) {
// here we can be sure that $variable is integer
}
```
```php
// using PHPUnit's asserts
self::assertNotNull($variable);
// here we can be sure that $variable is not null
```
Type-specifying extension cannot have `PHPStan\Analyser\TypeSpecifier` injected in the constructor due to circular reference issue, but the extensions can implement `PHPStan\Analyser\TypeSpecifierAwareExtension` interface to obtain TypeSpecifier via a setter.
This is the interface for type-specifying extension:
```php
namespace PHPStan\Type;
use PhpParser\Node\Expr\StaticCall;
use PHPStan\Analyser\Scope;
use PHPStan\Analyser\SpecifiedTypes;
use PHPStan\Analyser\TypeSpecifierContext;
use PHPStan\Reflection\MethodReflection;
interface StaticMethodTypeSpecifyingExtension
{
public function getClass(): string;
public function isStaticMethodSupported(MethodReflection $staticMethodReflection, StaticCall $node, TypeSpecifierContext $context): bool;
public function specifyTypes(MethodReflection $staticMethodReflection, StaticCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes;
}
```
And this is how you'd write the extension for the second example above:
```php
public function getClass(): string
{
return \PHPUnit\Framework\Assert::class;
}
public function isStaticMethodSupported(MethodReflection $staticMethodReflection, StaticCall $node, TypeSpecifierContext $context): bool;
{
// The $context argument tells us if we're in an if condition or not (as in this case).
return $staticMethodReflection->getName() === 'assertNotNull' && $context->null();
}
public function specifyTypes(MethodReflection $staticMethodReflection, StaticCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
// Assuming extension implements \PHPStan\Analyser\TypeSpecifierAwareExtension.
return $this->typeSpecifier->create($node->var, \PHPStan\Type\TypeCombinator::removeNull($scope->getType($node->var)), $context);
}
```
And finally, register the extension to PHPStan in the project's config file:
```
services:
-
class: App\PHPStan\AssertNotNullTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.staticMethodTypeSpecifyingExtension
```
There's also an analogous functionality for:
* **dynamic methods** using `MethodTypeSpecifyingExtension` interface
and `phpstan.typeSpecifier.methodTypeSpecifyingExtension` service tag.
* **functions** using `FunctionTypeSpecifyingExtension` interface and `phpstan.typeSpecifier.functionTypeSpecifyingExtension` service tag.
## Known issues
* If `include` or `require` are used in the analysed code (instead of `include_once` or `require_once`),
PHPStan will throw `Cannot redeclare class` error. Use the `_once` variants to avoid this error.
* If PHPStan crashes without outputting any error, it's quite possible that it's
because of a low memory limit set on your system. **Run PHPStan again** to read a couple of hints
what you can do to prevent the crashes.
## Code of Conduct
This project adheres to a [Contributor Code of Conduct](https://github.com/phpstan/phpstan/blob/master/CODE_OF_CONDUCT.md). By participating in this project and its community, you are expected to uphold this code.
## Contributing
Any contributions are welcome.
### Building
You can either run the whole build including linting and coding standards using
```bash
vendor/bin/phing
```
or run only tests using
```bash
vendor/bin/phing tests
```
phpcs.xml 0000666 00000006422 13436755504 0006427 0 ustar 00
tests/*/data
tests/*/traits
tests/notAutoloaded
src/Reflection/SignatureMap/functionMap.php
.github/ISSUE_TEMPLATE.md 0000666 00000001032 13436755504 0010625 0 ustar 00
### Summary of a problem or a feature request
### Code snippet that reproduces the problem
### Expected output
BACKERS.md 0000666 00000002047 13436755504 0006163 0 ustar 00 # Backers
Development of PHPStan is made possible thanks to these awesome backers!
You can become one of them by [pledging on Patreon](https://www.patreon.com/phpstan).
Check out all the tiers - higher ones include additional goodies like placing
the logo of your company in PHPStan's README.
# $50+
* MessageBird
# $10+
* Adam Lundrigan
* Scott Arciszewski
# $5+
* Adam Žurek
* Bart Reunes
* Carlos C Soto
* Craig Mayhew
* David Šolc
* Dennis Haarbrink
* Haralan Dobrev
* Ilija Tovilo
* Jake B
* Jakub Chábek
* Jakub Červený
* Jan Endel
* Jan Kuchař
* Lars Roettig
* Lukas Unger
* Masaru Yamagishi
* Michael Moll
* Pavel Vondrášek
* René Kliment
* Rudolph Gottesheim
* seagoj
* Stefan Zielke
* Thomas Daugaard
* Tomasz
* Tommy Muehle
* Vašek Brychta
* Woda Digital
# $1+
* Andrew Barlow
* Broken Bialek
* Christian Sjöström
* Craig Duncan
* Honza Cerny
* Ian Den Hartog
* Ivan Kvasnica
* korchasa
* Lucas Dos Santos Abreu
* Martin Lukeš
* Matej Drame
* Michal Mleczko
* Michał Włodarczyk
* Oliver Klee
* Ondrej Vodacek
* Wouter Admiraal
src/Testing/RuleTestCase.php 0000666 00000007576 13436755504 0012063 0 ustar 00 createTypeSpecifier(
new \PhpParser\PrettyPrinter\Standard(),
$this->createBroker(),
$this->getMethodTypeSpecifyingExtensions(),
$this->getStaticMethodTypeSpecifyingExtensions()
);
}
private function getAnalyser(): Analyser
{
if ($this->analyser === null) {
$registry = new Registry([
$this->getRule(),
]);
$broker = $this->createBroker();
$printer = new \PhpParser\PrettyPrinter\Standard();
$fileHelper = $this->getFileHelper();
$typeSpecifier = $this->createTypeSpecifier(
$printer,
$broker,
$this->getMethodTypeSpecifyingExtensions(),
$this->getStaticMethodTypeSpecifyingExtensions()
);
$currentWorkingDirectory = $this->getCurrentWorkingDirectory();
$this->analyser = new Analyser(
$this->createScopeFactory($broker, $typeSpecifier),
$this->getParser(),
$registry,
new NodeScopeResolver(
$broker,
$this->getParser(),
new FileTypeMapper($this->getParser(), self::getContainer()->getByType(PhpDocStringResolver::class), $this->createMock(Cache::class), new AnonymousClassNameHelper(new FileHelper($currentWorkingDirectory), new RelativePathHelper($currentWorkingDirectory, DIRECTORY_SEPARATOR, [])), new \PHPStan\PhpDoc\TypeNodeResolver($this->getTypeNodeResolverExtensions())),
$fileHelper,
$typeSpecifier,
$this->shouldPolluteScopeWithLoopInitialAssignments(),
$this->shouldPolluteCatchScopeWithTryAssignments(),
[]
),
[],
true,
50
);
}
return $this->analyser;
}
/**
* @return \PHPStan\Type\MethodTypeSpecifyingExtension[]
*/
protected function getMethodTypeSpecifyingExtensions(): array
{
return [];
}
/**
* @return \PHPStan\Type\StaticMethodTypeSpecifyingExtension[]
*/
protected function getStaticMethodTypeSpecifyingExtensions(): array
{
return [];
}
/**
* @return \PHPStan\PhpDoc\TypeNodeResolverExtension[]
*/
protected function getTypeNodeResolverExtensions(): array
{
return [];
}
/**
* @param string[] $files
* @param mixed[] $expectedErrors
*/
public function analyse(array $files, array $expectedErrors): void
{
$files = array_map([$this->getFileHelper(), 'normalizePath'], $files);
$actualErrors = $this->getAnalyser()->analyse($files, false);
$strictlyTypedSprintf = static function (int $line, string $message): string {
return sprintf('%02d: %s', $line, $message);
};
$expectedErrors = array_map(
static function (array $error) use ($strictlyTypedSprintf): string {
if (!isset($error[0])) {
throw new \InvalidArgumentException('Missing expected error message.');
}
if (!isset($error[1])) {
throw new \InvalidArgumentException('Missing expected file line.');
}
return $strictlyTypedSprintf($error[1], $error[0]);
},
$expectedErrors
);
$actualErrors = array_map(
static function (Error $error): string {
return sprintf('%02d: %s', $error->getLine(), $error->getMessage());
},
$actualErrors
);
$this->assertSame(implode("\n", $expectedErrors), implode("\n", $actualErrors));
}
protected function shouldPolluteScopeWithLoopInitialAssignments(): bool
{
return false;
}
protected function shouldPolluteCatchScopeWithTryAssignments(): bool
{
return false;
}
}
src/Testing/TestCase.php 0000666 00000025575 13436755504 0011232 0 ustar 00 create($rootDir . '/tmp', [
$containerFactory->getConfigDirectory() . '/config.level7.neon',
]);
}
return self::$container;
}
public function getParser(): \PHPStan\Parser\Parser
{
/** @var \PHPStan\Parser\Parser $parser */
$parser = self::getContainer()->getService('directParser');
return $parser;
}
/**
* @param \PHPStan\Type\DynamicMethodReturnTypeExtension[] $dynamicMethodReturnTypeExtensions
* @param \PHPStan\Type\DynamicStaticMethodReturnTypeExtension[] $dynamicStaticMethodReturnTypeExtensions
* @return \PHPStan\Broker\Broker
*/
public function createBroker(
array $dynamicMethodReturnTypeExtensions = [],
array $dynamicStaticMethodReturnTypeExtensions = []
): Broker
{
$functionCallStatementFinder = new FunctionCallStatementFinder();
$parser = $this->getParser();
$cache = new Cache(new MemoryCacheStorage());
$methodReflectionFactory = new class($parser, $functionCallStatementFinder, $cache) implements PhpMethodReflectionFactory {
/** @var \PHPStan\Parser\Parser */
private $parser;
/** @var \PHPStan\Parser\FunctionCallStatementFinder */
private $functionCallStatementFinder;
/** @var \PHPStan\Cache\Cache */
private $cache;
/** @var \PHPStan\Broker\Broker */
public $broker;
public function __construct(
Parser $parser,
FunctionCallStatementFinder $functionCallStatementFinder,
Cache $cache
)
{
$this->parser = $parser;
$this->functionCallStatementFinder = $functionCallStatementFinder;
$this->cache = $cache;
}
/**
* @param ClassReflection $declaringClass
* @param ClassReflection|null $declaringTrait
* @param \PHPStan\Reflection\Php\BuiltinMethodReflection $reflection
* @param Type[] $phpDocParameterTypes
* @param Type|null $phpDocReturnType
* @param Type|null $phpDocThrowType
* @param bool $isDeprecated
* @param bool $isInternal
* @param bool $isFinal
* @return PhpMethodReflection
*/
public function create(
ClassReflection $declaringClass,
?ClassReflection $declaringTrait,
\PHPStan\Reflection\Php\BuiltinMethodReflection $reflection,
array $phpDocParameterTypes,
?Type $phpDocReturnType,
?Type $phpDocThrowType,
bool $isDeprecated,
bool $isInternal,
bool $isFinal
): PhpMethodReflection
{
return new PhpMethodReflection(
$declaringClass,
$declaringTrait,
$reflection,
$this->broker,
$this->parser,
$this->functionCallStatementFinder,
$this->cache,
$phpDocParameterTypes,
$phpDocReturnType,
$phpDocThrowType,
$isDeprecated,
$isInternal,
$isFinal
);
}
};
$phpDocStringResolver = self::getContainer()->getByType(PhpDocStringResolver::class);
$currentWorkingDirectory = $this->getCurrentWorkingDirectory();
$fileTypeMapper = new FileTypeMapper($parser, $phpDocStringResolver, $cache, new AnonymousClassNameHelper(new FileHelper($currentWorkingDirectory), new RelativePathHelper($currentWorkingDirectory, DIRECTORY_SEPARATOR, [])), self::getContainer()->getByType(\PHPStan\PhpDoc\TypeNodeResolver::class));
$annotationsMethodsClassReflectionExtension = new AnnotationsMethodsClassReflectionExtension($fileTypeMapper);
$annotationsPropertiesClassReflectionExtension = new AnnotationsPropertiesClassReflectionExtension($fileTypeMapper);
$signatureMapProvider = self::getContainer()->getByType(SignatureMapProvider::class);
$phpExtension = new PhpClassReflectionExtension($methodReflectionFactory, $fileTypeMapper, $annotationsMethodsClassReflectionExtension, $annotationsPropertiesClassReflectionExtension, $signatureMapProvider);
$functionReflectionFactory = new class($this->getParser(), $functionCallStatementFinder, $cache) implements FunctionReflectionFactory {
/** @var \PHPStan\Parser\Parser */
private $parser;
/** @var \PHPStan\Parser\FunctionCallStatementFinder */
private $functionCallStatementFinder;
/** @var \PHPStan\Cache\Cache */
private $cache;
public function __construct(
Parser $parser,
FunctionCallStatementFinder $functionCallStatementFinder,
Cache $cache
)
{
$this->parser = $parser;
$this->functionCallStatementFinder = $functionCallStatementFinder;
$this->cache = $cache;
}
/**
* @param \ReflectionFunction $function
* @param Type[] $phpDocParameterTypes
* @param Type|null $phpDocReturnType
* @param Type|null $phpDocThrowType
* @param bool $isDeprecated
* @param bool $isInternal
* @param bool $isFinal
* @param string|false $filename
* @return PhpFunctionReflection
*/
public function create(
\ReflectionFunction $function,
array $phpDocParameterTypes,
?Type $phpDocReturnType,
?Type $phpDocThrowType,
bool $isDeprecated,
bool $isInternal,
bool $isFinal,
$filename
): PhpFunctionReflection
{
return new PhpFunctionReflection(
$function,
$this->parser,
$this->functionCallStatementFinder,
$this->cache,
$phpDocParameterTypes,
$phpDocReturnType,
$phpDocThrowType,
$isDeprecated,
$isInternal,
$isFinal,
$filename
);
}
};
$tagToService = static function (array $tags) {
return array_map(static function (string $serviceName) {
return self::getContainer()->getService($serviceName);
}, array_keys($tags));
};
$currentWorkingDirectory = $this->getCurrentWorkingDirectory();
$anonymousClassNameHelper = new AnonymousClassNameHelper(new FileHelper($currentWorkingDirectory), new RelativePathHelper($currentWorkingDirectory, DIRECTORY_SEPARATOR, []));
$broker = new Broker(
[
$phpExtension,
new PhpDefectClassReflectionExtension(self::getContainer()->getByType(TypeStringResolver::class)),
new UniversalObjectCratesClassReflectionExtension([\stdClass::class]),
$annotationsPropertiesClassReflectionExtension,
],
[
$phpExtension,
$annotationsMethodsClassReflectionExtension,
],
array_merge($dynamicMethodReturnTypeExtensions, $this->getDynamicMethodReturnTypeExtensions()),
array_merge($dynamicStaticMethodReturnTypeExtensions, $this->getDynamicStaticMethodReturnTypeExtensions()),
array_merge($tagToService(self::getContainer()->findByTag(BrokerFactory::DYNAMIC_FUNCTION_RETURN_TYPE_EXTENSION_TAG)), $this->getDynamicFunctionReturnTypeExtensions()),
$functionReflectionFactory,
new FileTypeMapper($this->getParser(), $phpDocStringResolver, $cache, $anonymousClassNameHelper, self::getContainer()->getByType(\PHPStan\PhpDoc\TypeNodeResolver::class)),
$signatureMapProvider,
self::getContainer()->getByType(Standard::class),
$anonymousClassNameHelper,
self::getContainer()->getByType(Parser::class),
new RelativePathHelper($this->getCurrentWorkingDirectory(), DIRECTORY_SEPARATOR, []),
self::getContainer()->parameters['universalObjectCratesClasses']
);
$methodReflectionFactory->broker = $broker;
return $broker;
}
/**
* @param Broker $broker
* @param TypeSpecifier $typeSpecifier
* @param string[] $dynamicConstantNames
*
* @return ScopeFactory
*/
public function createScopeFactory(Broker $broker, TypeSpecifier $typeSpecifier, array $dynamicConstantNames = []): ScopeFactory
{
return new ScopeFactory(
Scope::class,
$broker,
new \PhpParser\PrettyPrinter\Standard(),
$typeSpecifier,
$dynamicConstantNames
);
}
public function getCurrentWorkingDirectory(): string
{
return $this->getFileHelper()->normalizePath(__DIR__ . '/../..');
}
/**
* @return \PHPStan\Type\DynamicMethodReturnTypeExtension[]
*/
public function getDynamicMethodReturnTypeExtensions(): array
{
return [];
}
/**
* @return \PHPStan\Type\DynamicStaticMethodReturnTypeExtension[]
*/
public function getDynamicStaticMethodReturnTypeExtensions(): array
{
return [];
}
/**
* @return \PHPStan\Type\DynamicFunctionReturnTypeExtension[]
*/
public function getDynamicFunctionReturnTypeExtensions(): array
{
return [];
}
/**
* @param \PhpParser\PrettyPrinter\Standard $printer
* @param \PHPStan\Broker\Broker $broker
* @param \PHPStan\Type\MethodTypeSpecifyingExtension[] $methodTypeSpecifyingExtensions
* @param \PHPStan\Type\StaticMethodTypeSpecifyingExtension[] $staticMethodTypeSpecifyingExtensions
* @return \PHPStan\Analyser\TypeSpecifier
*/
public function createTypeSpecifier(
Standard $printer,
Broker $broker,
array $methodTypeSpecifyingExtensions = [],
array $staticMethodTypeSpecifyingExtensions = []
): TypeSpecifier
{
$tagToService = static function (array $tags) {
return array_map(static function (string $serviceName) {
return self::getContainer()->getService($serviceName);
}, array_keys($tags));
};
return new TypeSpecifier(
$printer,
$broker,
$tagToService(self::getContainer()->findByTag(TypeSpecifierFactory::FUNCTION_TYPE_SPECIFYING_EXTENSION_TAG)),
$methodTypeSpecifyingExtensions,
$staticMethodTypeSpecifyingExtensions
);
}
public function getFileHelper(): FileHelper
{
return self::getContainer()->getByType(FileHelper::class);
}
protected function skipIfNotOnWindows(): void
{
if (DIRECTORY_SEPARATOR === '\\') {
return;
}
self::markTestSkipped();
}
protected function skipIfNotOnUnix(): void
{
if (DIRECTORY_SEPARATOR === '/') {
return;
}
self::markTestSkipped();
}
}
src/Testing/LevelsTestCase.php 0000666 00000005316 13436755504 0012374 0 ustar 00 getDataPath(), $topic);
$command = escapeshellcmd($this->getPhpStanExecutablePath());
$configPath = $this->getPhpStanConfigPath();
$fileHelper = new FileHelper(__DIR__ . '/../..');
$previousMessages = [];
$exceptions = [];
foreach (range(0, 7) as $level) {
unset($outputLines);
exec(sprintf('php %s analyse --no-progress --error-format=prettyJson --level=%d %s --autoload-file %s %s', $command, $level, $configPath !== null ? '--configuration ' . escapeshellarg($configPath) : '', escapeshellarg($file), escapeshellarg($file)), $outputLines);
$output = implode("\n", $outputLines);
try {
$actualJson = \Nette\Utils\Json::decode($output, \Nette\Utils\Json::FORCE_ARRAY);
} catch (\Nette\Utils\JsonException $e) {
throw new \Nette\Utils\JsonException(sprintf('Cannot decode: %s', $output));
}
if (count($actualJson['files']) > 0) {
$messagesBeforeDiffing = $actualJson['files'][$fileHelper->normalizePath($file)]['messages'];
} else {
$messagesBeforeDiffing = [];
}
$messages = [];
foreach ($messagesBeforeDiffing as $message) {
foreach ($previousMessages as $lastMessage) {
if (
$message['message'] === $lastMessage['message']
&& $message['line'] === $lastMessage['line']
) {
continue 2;
}
}
$messages[] = $message;
}
$previousMessages = array_merge($previousMessages, $messages);
$expectedJsonFile = sprintf('%s/%s-%d.json', $this->getDataPath(), $topic, $level);
if (count($messages) === 0) {
try {
$this->assertFileNotExists($expectedJsonFile);
continue;
} catch (\PHPUnit\Framework\AssertionFailedError $e) {
unlink($expectedJsonFile);
$exceptions[] = $e;
continue;
}
}
$actualOutput = \Nette\Utils\Json::encode($messages, \Nette\Utils\Json::PRETTY);
try {
$this->assertJsonStringEqualsJsonFile(
$expectedJsonFile,
$actualOutput,
sprintf('Level #%d - file %s', $level, pathinfo($file, PATHINFO_BASENAME))
);
} catch (\PHPUnit\Framework\AssertionFailedError $e) {
file_put_contents($expectedJsonFile, $actualOutput);
$exceptions[] = $e;
}
}
if (count($exceptions) > 0) {
throw $exceptions[0];
}
}
}
src/File/FileHelper.php 0000666 00000003243 13436755504 0010764 0 ustar 00 workingDirectory = $this->normalizePath($workingDirectory);
}
public function getWorkingDirectory(): string
{
return $this->workingDirectory;
}
public function absolutizePath(string $path): string
{
if (DIRECTORY_SEPARATOR === '/') {
if (substr($path, 0, 1) === '/') {
return $path;
}
} else {
if (substr($path, 1, 1) === ':') {
return $path;
}
}
return rtrim($this->getWorkingDirectory(), '/\\') . DIRECTORY_SEPARATOR . ltrim($path, '/\\');
}
public function normalizePath(string $originalPath): string
{
$matches = \Nette\Utils\Strings::match($originalPath, '~^([a-z]+)\\:\\/\\/(.+)~');
if ($matches !== null) {
[, $scheme, $path] = $matches;
} else {
$scheme = null;
$path = $originalPath;
}
$path = str_replace('\\', '/', $path);
$path = Strings::replace($path, '~/{2,}~', '/');
$pathRoot = strpos($path, '/') === 0 ? DIRECTORY_SEPARATOR : '';
$pathParts = explode('/', trim($path, '/'));
$normalizedPathParts = [];
foreach ($pathParts as $pathPart) {
if ($pathPart === '.') {
continue;
}
if ($pathPart === '..') {
/** @var string $removedPart */
$removedPart = array_pop($normalizedPathParts);
if ($scheme === 'phar' && substr($removedPart, -5) === '.phar') {
$scheme = null;
}
} else {
$normalizedPathParts[] = $pathPart;
}
}
return ($scheme !== null ? $scheme . '://' : '') . $pathRoot . implode(DIRECTORY_SEPARATOR, $normalizedPathParts);
}
}
src/File/FileExcluder.php 0000666 00000002320 13436755504 0011313 0 ustar 00 analyseExcludes = array_map(function (string $exclude) use ($fileHelper): string {
$normalized = $fileHelper->normalizePath($exclude);
if ($this->isFnmatchPattern($normalized)) {
return $normalized;
}
return $fileHelper->absolutizePath($normalized);
}, $analyseExcludes);
}
public function isExcludedFromAnalysing(string $file): bool
{
foreach ($this->analyseExcludes as $exclude) {
if (strpos($file, $exclude) === 0) {
return true;
}
$isWindows = DIRECTORY_SEPARATOR === '\\';
if ($isWindows) {
$fnmatchFlags = FNM_NOESCAPE | FNM_CASEFOLD;
} else {
$fnmatchFlags = 0;
}
if ($this->isFnmatchPattern($exclude) && fnmatch($exclude, $file, $fnmatchFlags)) {
return true;
}
}
return false;
}
private function isFnmatchPattern(string $path): bool
{
return preg_match('~[*?[\]]~', $path) > 0;
}
}
src/File/RelativePathHelper.php 0000666 00000004752 13436755504 0012503 0 ustar 00 directorySeparator = $directorySeparator;
$pathBeginning = null;
$pathToTrimArray = null;
$trimBeginning = static function (string $path): array {
if (substr($path, 0, 1) === '/') {
return [
'/',
substr($path, 1),
];
} elseif (substr($path, 1, 1) === ':') {
return [
substr($path, 0, 3),
substr($path, 3),
];
}
return ['', $path];
};
if (
!in_array($currentWorkingDirectory, ['', '/'], true)
&& !(strlen($currentWorkingDirectory) === 3 && substr($currentWorkingDirectory, 1, 1) === ':')
) {
[$pathBeginning, $currentWorkingDirectory] = $trimBeginning($currentWorkingDirectory);
/** @var string[] $pathToTrimArray */
$pathToTrimArray = explode($directorySeparator, $currentWorkingDirectory);
}
foreach ($analysedPaths as $pathNumber => $path) {
[$tempPathBeginning, $path] = $trimBeginning($path);
/** @var string[] $pathArray */
$pathArray = explode($directorySeparator, $path);
$pathTempParts = [];
foreach ($pathArray as $i => $pathPart) {
if (\Nette\Utils\Strings::endsWith($pathPart, '.php')) {
continue;
}
if (!isset($pathToTrimArray[$i])) {
if ($pathNumber !== 0) {
$pathToTrimArray = $pathTempParts;
continue 2;
}
} elseif ($pathToTrimArray[$i] !== $pathPart) {
$pathToTrimArray = $pathTempParts;
continue 2;
}
$pathTempParts[] = $pathPart;
}
$pathBeginning = $tempPathBeginning;
$pathToTrimArray = $pathTempParts;
}
if ($pathToTrimArray === null || count($pathToTrimArray) === 0) {
return;
}
$pathToTrim = $pathBeginning . implode($directorySeparator, $pathToTrimArray);
$realPathToTrim = realpath($pathToTrim);
if ($realPathToTrim !== false) {
$pathToTrim = $realPathToTrim;
}
$this->pathToTrim = $pathToTrim;
}
public function getRelativePath(string $filename): string
{
if (
$this->pathToTrim !== null
&& strpos($filename, $this->pathToTrim) === 0
) {
return ltrim(substr($filename, strlen($this->pathToTrim)), $this->directorySeparator);
}
return $filename;
}
}
src/Internal/ScopeIsInClassTypeSpecifyingExtension.php 0000666 00000004107 13436755504 0017244 0 ustar 00 isInMethodName = $isInMethodName;
$this->removeNullMethodName = $removeNullMethodName;
$this->broker = $broker;
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
public function getClass(): string
{
return ClassMemberAccessAnswerer::class;
}
public function isMethodSupported(
MethodReflection $methodReflection,
MethodCall $node,
TypeSpecifierContext $context
): bool
{
return $methodReflection->getName() === $this->isInMethodName
&& !$context->null();
}
public function specifyTypes(
MethodReflection $methodReflection,
MethodCall $node,
Scope $scope,
TypeSpecifierContext $context
): SpecifiedTypes
{
$scopeClass = $this->broker->getClass(Scope::class);
$methodVariants = $scopeClass
->getMethod($this->removeNullMethodName, $scope)
->getVariants();
return $this->typeSpecifier->create(
new MethodCall($node->var, $this->removeNullMethodName),
TypeCombinator::removeNull(
ParametersAcceptorSelector::selectSingle($methodVariants)->getReturnType()
),
$context
);
}
}
src/Cache/CacheStorage.php 0000666 00000000460 13436755504 0011417 0 ustar 00 directory = $directory;
if (@mkdir($this->directory) && !is_dir($this->directory)) {
throw new \InvalidArgumentException(sprintf('Directory "%s" doesn\'t exist.', $this->directory));
}
}
/**
* @param string $key
* @return mixed|null
*/
public function load(string $key)
{
return (function (string $key) {
$filePath = $this->getFilePath($key);
return is_file($filePath) ? require $this->getFilePath($key) : null;
})($key);
}
/**
* @param string $key
* @param mixed $data
* @return bool
*/
public function save(string $key, $data): bool
{
$writtenBytes = @file_put_contents(
$this->getFilePath($key),
sprintf("directory, preg_replace('~[^-\\w]~', '_', $key));
}
}
src/Cache/MemoryCacheStorage.php 0000666 00000000730 13436755504 0012610 0 ustar 00 storage[$key] ?? null;
}
/**
* @param string $key
* @param mixed $data
* @return bool
*/
public function save(string $key, $data): bool
{
$this->storage[$key] = $data;
return true;
}
}
src/Cache/Cache.php 0000666 00000001025 13436755504 0010070 0 ustar 00 storage = $storage;
}
/**
* @param string $key
* @return mixed|null
*/
public function load(string $key)
{
return $this->storage->load($key);
}
/**
* @param string $key
* @param mixed $data
* @return bool
*/
public function save(string $key, $data): bool
{
return $this->storage->save($key, $data);
}
}
src/Type/ResourceType.php 0000666 00000003052 13436755504 0011436 0 ustar 00 hasClass($selfClass)) {
$classReflection = $broker->getClass($selfClass);
if ($classReflection->getParentClass() !== false) {
return new ObjectType($classReflection->getParentClass()->getName());
}
}
return new NonexistentParentClassType();
default:
return new ObjectType($typeString);
}
}
public static function decideTypeFromReflection(
?\ReflectionType $reflectionType,
?Type $phpDocType = null,
?string $selfClass = null,
bool $isVariadic = false
): Type
{
if ($reflectionType === null) {
return $phpDocType ?? new MixedType();
}
$reflectionTypeString = (string) $reflectionType;
if (\Nette\Utils\Strings::endsWith(strtolower($reflectionTypeString), '\\object')) {
$reflectionTypeString = 'object';
}
$type = self::getTypeObjectFromTypehint($reflectionTypeString, $selfClass);
if ($reflectionType->allowsNull()) {
$type = TypeCombinator::addNull($type);
}
if ($isVariadic) {
$type = new ArrayType(new IntegerType(), $type);
}
return self::decideType($type, $phpDocType);
}
public static function decideType(
Type $type,
?Type $phpDocType = null
): Type
{
if ($phpDocType !== null && !$phpDocType instanceof ErrorType) {
if ($type instanceof VoidType || $phpDocType instanceof VoidType) {
return new VoidType();
}
if (TypeCombinator::removeNull($type) instanceof IterableType) {
if ($phpDocType instanceof UnionType) {
$innerTypes = [];
foreach ($phpDocType->getTypes() as $innerType) {
if ($innerType instanceof ArrayType) {
$innerTypes[] = new IterableType(
$innerType->getKeyType(),
$innerType->getItemType()
);
} else {
$innerTypes[] = $innerType;
}
}
$phpDocType = new UnionType($innerTypes);
} elseif ($phpDocType instanceof ArrayType) {
$phpDocType = new IterableType(
$phpDocType->getKeyType(),
$phpDocType->getItemType()
);
}
}
return $type->isSuperTypeOf($phpDocType)->yes() ? $phpDocType : $type;
}
return $type;
}
}
src/Type/CallableTypeHelper.php 0000666 00000002024 13436755504 0012504 0 ustar 00 getParameters();
$ourParameters = $ours->getParameters();
if (count($theirParameters) > count($ourParameters)) {
return TrinaryLogic::createNo();
}
$result = null;
foreach ($theirParameters as $i => $theirParameter) {
$ourParameter = $ourParameters[$i];
$isSuperType = $theirParameter->getType()->isSuperTypeOf($ourParameter->getType());
if ($result === null) {
$result = $isSuperType;
} else {
$result = $result->and($isSuperType);
}
}
$isReturnTypeSuperType = $ours->getReturnType()->isSuperTypeOf($theirs->getReturnType());
if ($result === null) {
$result = $isReturnTypeSuperType;
} else {
$result = $result->and($isReturnTypeSuperType);
}
return $result;
}
}
src/Type/Traits/NonObjectTypeTrait.php 0000666 00000002501 13436755504 0014000 0 ustar 00 value === $type->value);
}
if ($type instanceof CompoundType) {
return CompoundTypeHelper::accepts($type, $this, $strictTypes);
}
return TrinaryLogic::createNo();
}
public function isSuperTypeOf(Type $type): TrinaryLogic
{
if ($type instanceof self) {
return $this->value === $type->value ? TrinaryLogic::createYes() : TrinaryLogic::createNo();
}
if ($type instanceof parent) {
return TrinaryLogic::createMaybe();
}
if ($type instanceof CompoundType) {
return $type->isSubTypeOf($this);
}
return TrinaryLogic::createNo();
}
public function equals(Type $type): bool
{
return $type instanceof self && $this->value === $type->value;
}
public function generalize(): Type
{
return new parent();
}
}
src/Type/Traits/TruthyBooleanTypeTrait.php 0000666 00000000413 13436755504 0014716 0 ustar 00 getName()) === 'is_null'
&& isset($node->args[0])
&& !$context->null();
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
if ($context->null()) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->typeSpecifier->create($node->args[0]->value, new NullType(), $context);
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
}
src/Type/Php/IsIterableFunctionTypeSpecifyingExtension.php 0000666 00000002541 13436755504 0020047 0 ustar 00 getName()) === 'is_iterable'
&& isset($node->args[0])
&& !$context->null();
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
if ($context->null()) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->typeSpecifier->create($node->args[0]->value, new IterableType(new MixedType(), new MixedType()), $context);
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
}
src/Type/Php/MbStrlenFunctionReturnTypeExtension.php 0000666 00000002743 13436755504 0016735 0 ustar 00 getName() === 'mb_strlen';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
$returnType = ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
if (count($functionCall->args) < 1) {
return $returnType;
}
if (!isset($functionCall->args[1])) {
return new IntegerType();
}
if (!extension_loaded('mbstring')) {
return $returnType;
}
$result = array_unique(array_map(static function (ConstantStringType $encoding): bool {
return @mb_strlen('', $encoding->getValue()) !== false; // @ = silence the undocumented warning
}, TypeUtils::getConstantStrings($scope->getType($functionCall->args[1]->value))));
if (count($result) !== 1) {
return $returnType;
}
return $result[0] ? new IntegerType() : new ConstantBooleanType(false);
}
}
src/Type/Php/ArrayReduceFunctionReturnTypeExtension.php 0000666 00000003755 13436755504 0017421 0 ustar 00 getName() === 'array_reduce';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
if (!isset($functionCall->args[1])) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$callbackType = $scope->getType($functionCall->args[1]->value);
if ($callbackType->isCallable()->no()) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$callbackReturnType = ParametersAcceptorSelector::selectFromArgs(
$scope,
$functionCall->args,
$callbackType->getCallableParametersAcceptors($scope)
)->getReturnType();
if (isset($functionCall->args[2])) {
$initialType = $scope->getType($functionCall->args[2]->value);
} else {
$initialType = new NullType();
}
$arraysType = $scope->getType($functionCall->args[0]->value);
$constantArrays = TypeUtils::getConstantArrays($arraysType);
if (count($constantArrays) > 0) {
$onlyEmpty = true;
$onlyNonEmpty = true;
foreach ($constantArrays as $constantArray) {
$isEmpty = count($constantArray->getValueTypes()) === 0;
$onlyEmpty = $onlyEmpty && $isEmpty;
$onlyNonEmpty = $onlyNonEmpty && !$isEmpty;
}
if ($onlyEmpty) {
return $initialType;
}
if ($onlyNonEmpty) {
return $callbackReturnType;
}
}
return TypeCombinator::union($callbackReturnType, $initialType);
}
}
src/Type/Php/IsResourceFunctionTypeSpecifyingExtension.php 0000666 00000002445 13436755504 0020112 0 ustar 00 getName()) === 'is_resource'
&& isset($node->args[0])
&& !$context->null();
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
if ($context->null()) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->typeSpecifier->create($node->args[0]->value, new ResourceType(), $context);
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
}
src/Type/Php/ArrayMergeFunctionDynamicReturnTypeExtension.php 0000666 00000005065 13436755504 0020552 0 ustar 00 getName() === 'array_merge';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
if (!isset($functionCall->args[0])) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$argumentTypes = [];
foreach ($functionCall->args as $arg) {
$argType = $scope->getType($arg->value);
if ($arg->unpack) {
$iterableValueType = $argType->getIterableValueType();
if ($iterableValueType instanceof UnionType) {
foreach ($iterableValueType->getTypes() as $innerType) {
$argumentTypes[] = $innerType;
}
} else {
$argumentTypes[] = $iterableValueType;
}
continue;
}
$argumentTypes[] = $argType;
}
return $this->processType($argumentTypes);
}
/**
* @param \PHPStan\Type\Type[] $types
* @return Type
*/
private function processType(
array $types
): Type
{
$arrayType = null;
foreach ($types as $type) {
if (!$type instanceof ConstantArrayType) {
return \PHPStan\Type\TypeCombinator::union(...$types);
}
if ($arrayType === null) {
$newArrayBuilder = ConstantArrayTypeBuilder::createEmpty();
foreach ($type->getKeyTypes() as $i => $keyType) {
$valueType = $type->getValueTypes()[$i];
if ($keyType instanceof ConstantIntegerType) {
$keyType = null;
}
$newArrayBuilder->setOffsetValueType(
$keyType,
$valueType
);
}
$arrayType = $newArrayBuilder->getArray();
continue;
}
foreach ($type->getValueTypes() as $i => $valueType) {
$keyType = $type->getKeyTypes()[$i];
if ($keyType instanceof ConstantIntegerType) {
$arrayType = $arrayType->setOffsetValueType(null, $valueType);
continue;
}
$arrayType = $arrayType->setOffsetValueType($keyType, $valueType);
}
}
/** @var \PHPStan\Type\Type $arrayType */
$arrayType = $arrayType;
return $arrayType;
}
}
src/Type/Php/DioStatDynamicFunctionReturnTypeExtension.php 0000666 00000002230 13436755504 0020052 0 ustar 00 getName() === 'dio_stat';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
$valueType = new IntegerType();
$builder = ConstantArrayTypeBuilder::createEmpty();
$keys = [
'device',
'inode',
'mode',
'nlink',
'uid',
'gid',
'device_type',
'size',
'blocksize',
'blocks',
'atime',
'mtime',
'ctime',
];
foreach ($keys as $key) {
$builder->setOffsetValueType(new ConstantStringType($key), $valueType);
}
return TypeCombinator::addNull($builder->getArray());
}
}
src/Type/Php/TypeSpecifyingFunctionsDynamicReturnTypeExtension.php 0000666 00000004442 13436755504 0021637 0 ustar 00 broker = $broker;
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
public function isFunctionSupported(FunctionReflection $functionReflection): bool
{
return in_array($functionReflection->getName(), [
'array_key_exists',
'in_array',
'is_numeric',
'is_int',
'is_array',
'is_bool',
'is_callable',
'is_float',
'is_double',
'is_real',
'is_iterable',
'is_null',
'is_object',
'is_resource',
'is_scalar',
'is_string',
'is_subclass_of',
], true);
}
public function getTypeFromFunctionCall(
FunctionReflection $functionReflection,
FuncCall $functionCall,
Scope $scope
): Type
{
if (count($functionCall->args) === 0) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$isAlways = $this->getHelper()->findSpecifiedType(
$scope,
$functionCall
);
if ($isAlways === null) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
return new ConstantBooleanType($isAlways);
}
private function getHelper(): ImpossibleCheckTypeHelper
{
if ($this->helper === null) {
$this->helper = new ImpossibleCheckTypeHelper($this->broker, $this->typeSpecifier);
}
return $this->helper;
}
}
src/Type/Php/ArrayValuesFunctionDynamicReturnTypeExtension.php 0000666 00000001705 13436755504 0020747 0 ustar 00 getName() === 'array_values';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
$arrayArg = $functionCall->args[0]->value ?? null;
if ($arrayArg !== null) {
$valueType = $scope->getType($arrayArg);
if ($valueType instanceof ArrayType) {
return $valueType->getValuesArray();
}
}
return new ArrayType(
new IntegerType(),
new MixedType()
);
}
}
src/Type/Php/ArrayKeysFunctionDynamicReturnTypeExtension.php 0000666 00000002001 13436755504 0020411 0 ustar 00 getName() === 'array_keys';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
$arrayArg = $functionCall->args[0]->value ?? null;
if ($arrayArg !== null) {
$valueType = $scope->getType($arrayArg);
if ($valueType instanceof ArrayType) {
return $valueType->getKeysArray();
}
}
return new ArrayType(
new IntegerType(),
new UnionType([new StringType(), new IntegerType()])
);
}
}
src/Type/Php/DefinedConstantTypeSpecifyingExtension.php 0000666 00000003036 13436755504 0017366 0 ustar 00 typeSpecifier = $typeSpecifier;
}
public function isFunctionSupported(
FunctionReflection $functionReflection,
FuncCall $node,
TypeSpecifierContext $context
): bool
{
return $functionReflection->getName() === 'defined'
&& count($node->args) >= 1
&& !$context->null();
}
public function specifyTypes(
FunctionReflection $functionReflection,
FuncCall $node,
Scope $scope,
TypeSpecifierContext $context
): SpecifiedTypes
{
$constantName = $scope->getType($node->args[0]->value);
if (
!$constantName instanceof ConstantStringType
|| $constantName->getValue() === ''
) {
return new SpecifiedTypes([], []);
}
return $this->typeSpecifier->create(
new \PhpParser\Node\Expr\ConstFetch(
new \PhpParser\Node\Name\FullyQualified($constantName->getValue())
),
new MixedType(),
$context
);
}
}
src/Type/Php/PropertyExistsTypeSpecifyingExtension.php 0000666 00000003150 13436755504 0017337 0 ustar 00 typeSpecifier = $typeSpecifier;
}
public function isFunctionSupported(
FunctionReflection $functionReflection,
FuncCall $node,
TypeSpecifierContext $context
): bool
{
return $functionReflection->getName() === 'property_exists'
&& $context->truthy()
&& count($node->args) >= 2;
}
public function specifyTypes(
FunctionReflection $functionReflection,
FuncCall $node,
Scope $scope,
TypeSpecifierContext $context
): SpecifiedTypes
{
$propertyNameType = $scope->getType($node->args[1]->value);
if (!$propertyNameType instanceof ConstantStringType) {
return new SpecifiedTypes([], []);
}
return $this->typeSpecifier->create(
$node->args[0]->value,
new IntersectionType([
new ObjectWithoutClassType(),
new HasPropertyType($propertyNameType->getValue()),
]),
$context
);
}
}
src/Type/Php/ReplaceFunctionsDynamicReturnTypeExtension.php 0000666 00000005311 13436755504 0020244 0 ustar 00 */
private $functions = [
'preg_replace' => 2,
'preg_replace_callback' => 2,
'preg_replace_callback_array' => 1,
'str_replace' => 2,
'str_ireplace' => 2,
'substr_replace' => 0,
];
public function isFunctionSupported(FunctionReflection $functionReflection): bool
{
return array_key_exists($functionReflection->getName(), $this->functions);
}
public function getTypeFromFunctionCall(
FunctionReflection $functionReflection,
FuncCall $functionCall,
Scope $scope
): Type
{
$type = $this->getPreliminarilyResolvedTypeFromFunctionCall($functionReflection, $functionCall, $scope);
$possibleTypes = ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
if (TypeCombinator::containsNull($possibleTypes)) {
$type = TypeCombinator::addNull($type);
}
return $type;
}
private function getPreliminarilyResolvedTypeFromFunctionCall(
FunctionReflection $functionReflection,
FuncCall $functionCall,
Scope $scope
): Type
{
$argumentPosition = $this->functions[$functionReflection->getName()];
if (count($functionCall->args) <= $argumentPosition) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$subjectArgumentType = $scope->getType($functionCall->args[$argumentPosition]->value);
$defaultReturnType = ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
if ($subjectArgumentType instanceof MixedType) {
return TypeUtils::toBenevolentUnion($defaultReturnType);
}
$stringType = new StringType();
$arrayType = new ArrayType(new MixedType(), new MixedType());
$isStringSuperType = $stringType->isSuperTypeOf($subjectArgumentType);
$isArraySuperType = $arrayType->isSuperTypeOf($subjectArgumentType);
$compareSuperTypes = $isStringSuperType->compareTo($isArraySuperType);
if ($compareSuperTypes === $isStringSuperType) {
return $stringType;
} elseif ($compareSuperTypes === $isArraySuperType) {
if ($subjectArgumentType instanceof ArrayType) {
return $subjectArgumentType->generalizeValues();
}
return $subjectArgumentType;
}
return $defaultReturnType;
}
}
src/Type/Php/MethodExistsTypeSpecifyingExtension.php 0000666 00000003132 13436755504 0016733 0 ustar 00 typeSpecifier = $typeSpecifier;
}
public function isFunctionSupported(
FunctionReflection $functionReflection,
FuncCall $node,
TypeSpecifierContext $context
): bool
{
return $functionReflection->getName() === 'method_exists'
&& $context->truthy()
&& count($node->args) >= 2;
}
public function specifyTypes(
FunctionReflection $functionReflection,
FuncCall $node,
Scope $scope,
TypeSpecifierContext $context
): SpecifiedTypes
{
$methodNameType = $scope->getType($node->args[1]->value);
if (!$methodNameType instanceof ConstantStringType) {
return new SpecifiedTypes([], []);
}
return $this->typeSpecifier->create(
$node->args[0]->value,
new IntersectionType([
new ObjectWithoutClassType(),
new HasMethodType($methodNameType->getValue()),
]),
$context
);
}
}
src/Type/Php/IsNumericFunctionTypeSpecifyingExtension.php 0000666 00000003001 13436755504 0017712 0 ustar 00 getName() === 'is_numeric'
&& isset($node->args[0])
&& !$context->null();
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
if ($context->null()) {
throw new \PHPStan\ShouldNotHappenException();
}
$numericTypes = [
new IntegerType(),
new FloatType(),
];
if ($context->truthy()) {
$numericTypes[] = new StringType();
}
return $this->typeSpecifier->create($node->args[0]->value, new UnionType($numericTypes), $context);
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
}
src/Type/Php/IsArrayFunctionTypeSpecifyingExtension.php 0000666 00000002525 13436755504 0017400 0 ustar 00 getName()) === 'is_array'
&& isset($node->args[0])
&& !$context->null();
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
if ($context->null()) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->typeSpecifier->create($node->args[0]->value, new ArrayType(new MixedType(), new MixedType()), $context);
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
}
src/Type/Php/ArraySearchFunctionDynamicReturnTypeExtension.php 0000666 00000011377 13436755504 0020723 0 ustar 00 getName() === 'array_search';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
$argsCount = count($functionCall->args);
if ($argsCount < 2) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$haystackArgType = $scope->getType($functionCall->args[1]->value);
$haystackIsArray = (new ArrayType(new MixedType(), new MixedType()))->isSuperTypeOf($haystackArgType);
if ($haystackIsArray->no()) {
return new NullType();
}
if ($argsCount < 3) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$strictArgType = $scope->getType($functionCall->args[2]->value);
if (!($strictArgType instanceof ConstantBooleanType) || $strictArgType->getValue() === false) {
return TypeCombinator::union($haystackArgType->getIterableKeyType(), new ConstantBooleanType(false), new NullType());
}
$needleArgType = $scope->getType($functionCall->args[0]->value);
if ($haystackArgType->getIterableValueType()->isSuperTypeOf($needleArgType)->no()) {
return new ConstantBooleanType(false);
}
$typesFromConstantArrays = [];
if ($haystackIsArray->maybe()) {
$typesFromConstantArrays[] = new NullType();
}
$haystackArrays = $this->pickArrays($haystackArgType);
if (count($haystackArrays) === 0) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$arrays = [];
$typesFromConstantArraysCount = 0;
foreach ($haystackArrays as $haystackArray) {
if (!$haystackArray instanceof ConstantArrayType) {
$arrays[] = $haystackArray;
continue;
}
$typesFromConstantArrays[] = $this->resolveTypeFromConstantHaystackAndNeedle($needleArgType, $haystackArray);
$typesFromConstantArraysCount++;
}
if (
$typesFromConstantArraysCount > 0
&& count($haystackArrays) === $typesFromConstantArraysCount
) {
return TypeCombinator::union(...$typesFromConstantArrays);
}
$iterableKeyType = TypeCombinator::union(...$arrays)->getIterableKeyType();
if ($iterableKeyType instanceof BenevolentUnionType) {
$iterableKeyType = new MixedType();
}
return TypeCombinator::union(
$iterableKeyType,
new ConstantBooleanType(false),
...$typesFromConstantArrays
);
}
private function resolveTypeFromConstantHaystackAndNeedle(Type $needle, ConstantArrayType $haystack): Type
{
$matchesByType = [];
foreach ($haystack->getValueTypes() as $index => $valueType) {
$isNeedleSuperType = $valueType->isSuperTypeOf($needle);
if ($isNeedleSuperType->no()) {
$matchesByType[] = new ConstantBooleanType(false);
continue;
}
if ($needle instanceof ConstantScalarType && $valueType instanceof ConstantScalarType
&& $needle->getValue() === $valueType->getValue()
) {
return $haystack->getKeyTypes()[$index];
}
$matchesByType[] = $haystack->getKeyTypes()[$index];
if (!$isNeedleSuperType->maybe()) {
continue;
}
$matchesByType[] = new ConstantBooleanType(false);
}
if (count($matchesByType) > 0) {
if (
$haystack->getIterableValueType()->accepts($needle, true)->yes()
&& $needle->isSuperTypeOf(new ObjectWithoutClassType())->no()
) {
return TypeCombinator::union(...$matchesByType);
}
return TypeCombinator::union(new ConstantBooleanType(false), ...$matchesByType);
}
return new ConstantBooleanType(false);
}
/**
* @param Type $type
* @return Type[]
*/
private function pickArrays(Type $type): array
{
if ($type instanceof ArrayType) {
return [$type];
}
if ($type instanceof UnionType || $type instanceof IntersectionType) {
$arrayTypes = [];
foreach ($type->getTypes() as $innerType) {
if (!($innerType instanceof ArrayType)) {
continue;
}
$arrayTypes[] = $innerType;
}
return $arrayTypes;
}
return [];
}
}
src/Type/Php/AssertFunctionTypeSpecifyingExtension.php 0000666 00000002251 13436755504 0017263 0 ustar 00 getName() === 'assert'
&& isset($node->args[0]);
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
return $this->typeSpecifier->specifyTypesInCondition($scope, $node->args[0]->value, TypeSpecifierContext::createTruthy());
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
}
src/Type/Php/MinMaxFunctionReturnTypeExtension.php 0000666 00000010340 13436755504 0016370 0 ustar 00 '',
'max' => '',
];
public function isFunctionSupported(FunctionReflection $functionReflection): bool
{
return isset($this->functionNames[$functionReflection->getName()]);
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
if (!isset($functionCall->args[0])) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
if (count($functionCall->args) === 1) {
$argType = $scope->getType($functionCall->args[0]->value);
if ($argType instanceof ArrayType) {
$iterableValueType = $argType->getIterableValueType();
$argumentTypes = [];
if ($iterableValueType instanceof UnionType) {
foreach ($iterableValueType->getTypes() as $innerType) {
$argumentTypes[] = $innerType;
}
} else {
$argumentTypes[] = $iterableValueType;
}
return $this->processType(
$functionReflection->getName(),
$argumentTypes
);
}
return new ErrorType();
}
$argumentTypes = [];
foreach ($functionCall->args as $arg) {
$argType = $scope->getType($arg->value);
if ($arg->unpack) {
$iterableValueType = $argType->getIterableValueType();
if ($iterableValueType instanceof UnionType) {
foreach ($iterableValueType->getTypes() as $innerType) {
$argumentTypes[] = $innerType;
}
} else {
$argumentTypes[] = $iterableValueType;
}
continue;
}
$argumentTypes[] = $argType;
}
return $this->processType(
$functionReflection->getName(),
$argumentTypes
);
}
/**
* @param string $functionName
* @param \PHPStan\Type\Type[] $types
* @return Type
*/
private function processType(
string $functionName,
array $types
): Type
{
$resultType = null;
foreach ($types as $type) {
if (!$type instanceof ConstantType) {
return TypeCombinator::union(...$types);
}
if ($resultType === null) {
$resultType = $type;
continue;
}
$compareResult = $this->compareTypes($resultType, $type);
if ($functionName === 'min') {
if ($compareResult === $type) {
$resultType = $type;
}
} elseif ($functionName === 'max') {
if ($compareResult === $resultType) {
$resultType = $type;
}
}
}
if ($resultType === null) {
return new ErrorType();
}
return $resultType;
}
private function compareTypes(
Type $firstType,
Type $secondType
): ?Type
{
if (
$firstType instanceof ConstantArrayType
&& $secondType instanceof ConstantScalarType
) {
return $secondType;
}
if (
$firstType instanceof ConstantScalarType
&& $secondType instanceof ConstantArrayType
) {
return $firstType;
}
if (
$firstType instanceof ConstantArrayType
&& $secondType instanceof ConstantArrayType
) {
if ($secondType->count() < $firstType->count()) {
return $secondType;
} elseif ($firstType->count() < $secondType->count()) {
return $firstType;
}
foreach ($firstType->getValueTypes() as $i => $firstValueType) {
$secondValueType = $secondType->getValueTypes()[$i];
$compareResult = $this->compareTypes($firstValueType, $secondValueType);
if ($compareResult === $firstValueType) {
return $firstType;
}
if ($compareResult === $secondValueType) {
return $secondType;
}
}
return null;
}
if (
$firstType instanceof ConstantScalarType
&& $secondType instanceof ConstantScalarType
) {
if ($secondType->getValue() < $firstType->getValue()) {
return $secondType;
}
if ($firstType->getValue() < $secondType->getValue()) {
return $firstType;
}
}
return null;
}
}
src/Type/Php/IsObjectFunctionTypeSpecifyingExtension.php 0000666 00000002465 13436755504 0017533 0 ustar 00 getName()) === 'is_object'
&& isset($node->args[0])
&& !$context->null();
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
if ($context->null()) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->typeSpecifier->create($node->args[0]->value, new ObjectWithoutClassType(), $context);
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
}
src/Type/Php/PathinfoFunctionDynamicReturnTypeExtension.php 0000666 00000002426 13436755504 0020262 0 ustar 00 getName() === 'pathinfo';
}
public function getTypeFromFunctionCall(
FunctionReflection $functionReflection,
\PhpParser\Node\Expr\FuncCall $functionCall,
Scope $scope
): Type
{
$argsCount = count($functionCall->args);
if ($argsCount === 0) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
} elseif ($argsCount === 1) {
$stringType = new StringType();
return new ConstantArrayType([
new ConstantStringType('dirname'),
new ConstantStringType('basename'),
new ConstantStringType('extension'),
new ConstantStringType('filename'),
], [
$stringType,
$stringType,
$stringType,
$stringType,
]);
}
return new StringType();
}
}
src/Type/Php/RangeFunctionReturnTypeExtension.php 0000666 00000006630 13436755504 0016242 0 ustar 00 getName() === 'range';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
if (count($functionCall->args) < 2) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$startType = $scope->getType($functionCall->args[0]->value);
$endType = $scope->getType($functionCall->args[1]->value);
$stepType = count($functionCall->args) >= 3 ? $scope->getType($functionCall->args[2]->value) : new ConstantIntegerType(1);
$constantReturnTypes = [];
$startConstants = TypeUtils::getConstantScalars($startType);
foreach ($startConstants as $startConstant) {
if (!$startConstant instanceof ConstantIntegerType && !$startConstant instanceof ConstantFloatType) {
continue;
}
$endConstants = TypeUtils::getConstantScalars($endType);
foreach ($endConstants as $endConstant) {
if (!$endConstant instanceof ConstantIntegerType && !$endConstant instanceof ConstantFloatType) {
continue;
}
$stepConstants = TypeUtils::getConstantScalars($stepType);
foreach ($stepConstants as $stepConstant) {
if (!$stepConstant instanceof ConstantIntegerType && !$stepConstant instanceof ConstantFloatType) {
continue;
}
$rangeLength = (int) ceil(abs($startConstant->getValue() - $endConstant->getValue()) / $stepConstant->getValue()) + 1;
if ($rangeLength > self::RANGE_LENGTH_THRESHOLD) {
continue;
}
$keyTypes = [];
$valueTypes = [];
$rangeValues = range($startConstant->getValue(), $endConstant->getValue(), $stepConstant->getValue());
foreach ($rangeValues as $key => $value) {
$keyTypes[] = new ConstantIntegerType($key);
$valueTypes[] = $scope->getTypeFromValue($value);
}
$constantReturnTypes[] = new ConstantArrayType($keyTypes, $valueTypes, $rangeLength);
}
}
}
if (count($constantReturnTypes) > 0) {
return TypeCombinator::union(...$constantReturnTypes);
}
$startType = TypeUtils::generalizeType($startType);
$endType = TypeUtils::generalizeType($endType);
$stepType = TypeUtils::generalizeType($stepType);
if (
$startType instanceof IntegerType
&& $endType instanceof IntegerType
&& $stepType instanceof IntegerType
) {
return new ArrayType(new IntegerType(), new IntegerType());
}
if (
$startType instanceof FloatType
|| $endType instanceof FloatType
|| $stepType instanceof FloatType
) {
return new ArrayType(new IntegerType(), new FloatType());
}
return new ArrayType(new IntegerType(), new UnionType([new IntegerType(), new FloatType()]));
}
}
src/Type/Php/IsScalarFunctionTypeSpecifyingExtension.php 0000666 00000002736 13436755504 0017533 0 ustar 00 getName() === 'is_scalar'
&& isset($node->args[0])
&& !$context->null();
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
if ($context->null()) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->typeSpecifier->create($node->args[0]->value, new UnionType([
new StringType(),
new IntegerType(),
new FloatType(),
new BooleanType(),
]), $context);
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
}
src/Type/Php/ArrayFillKeysFunctionReturnTypeExtension.php 0000666 00000003060 13436755504 0017721 0 ustar 00 getName() === 'array_fill_keys';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
if (count($functionCall->args) < 2) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$valueType = $scope->getType($functionCall->args[1]->value);
$keysType = $scope->getType($functionCall->args[0]->value);
$constantArrays = TypeUtils::getConstantArrays($keysType);
if (count($constantArrays) === 0) {
return new ArrayType($keysType->getIterableValueType(), $valueType);
}
$arrayTypes = [];
foreach ($constantArrays as $constantArray) {
$arrayBuilder = ConstantArrayTypeBuilder::createEmpty();
foreach ($constantArray->getValueTypes() as $keyType) {
$arrayBuilder->setOffsetValueType($keyType, $valueType);
}
$arrayTypes[] = $arrayBuilder->getArray();
}
return TypeCombinator::union(...$arrayTypes);
}
}
src/Type/Php/CurlInitReturnTypeExtension.php 0000666 00000001541 13436755504 0015225 0 ustar 00 getName() === 'curl_init';
}
public function getTypeFromFunctionCall(
FunctionReflection $functionReflection,
\PhpParser\Node\Expr\FuncCall $functionCall,
Scope $scope
): Type
{
$argsCount = count($functionCall->args);
if ($argsCount === 0) {
return new ResourceType();
}
return new UnionType([
new ResourceType(),
new ConstantBooleanType(false),
]);
}
}
src/Type/Php/ArrayFillFunctionReturnTypeExtension.php 0000666 00000003316 13436755504 0017071 0 ustar 00 getName() === 'array_fill';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
if (count($functionCall->args) < 3) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$valueType = $scope->getType($functionCall->args[2]->value);
$startIndexType = $scope->getType($functionCall->args[0]->value);
if (!$startIndexType instanceof ConstantIntegerType) {
return new ArrayType(new IntegerType(), $valueType);
}
$numberType = $scope->getType($functionCall->args[1]->value);
if (!$numberType instanceof ConstantIntegerType) {
return new ArrayType(new IntegerType(), $valueType);
}
$arrayBuilder = ConstantArrayTypeBuilder::createEmpty();
$nextIndex = $startIndexType->getValue();
for ($i = 0; $i < $numberType->getValue(); $i++) {
$arrayBuilder->setOffsetValueType(
new ConstantIntegerType($nextIndex),
$valueType
);
if ($nextIndex < 0) {
$nextIndex = 0;
} else {
$nextIndex++;
}
}
return $arrayBuilder->getArray();
}
}
src/Type/Php/InArrayFunctionTypeSpecifyingExtension.php 0000666 00000003245 13436755504 0017373 0 ustar 00 typeSpecifier = $typeSpecifier;
}
public function isFunctionSupported(FunctionReflection $functionReflection, FuncCall $node, TypeSpecifierContext $context): bool
{
return strtolower($functionReflection->getName()) === 'in_array'
&& count($node->args) >= 3
&& !$context->null();
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
$strictNodeType = $scope->getType($node->args[2]->value);
if (!(new ConstantBooleanType(true))->isSuperTypeOf($strictNodeType)->yes()) {
return new SpecifiedTypes([], []);
}
$arrayValueType = $scope->getType($node->args[1]->value)->getIterableValueType();
if (
$context->truthy()
|| count(TypeUtils::getConstantScalars($arrayValueType)) > 0
) {
return $this->typeSpecifier->create(
$node->args[0]->value,
$arrayValueType,
$context
);
}
return new SpecifiedTypes([], []);
}
}
src/Type/Php/IsSubclassOfFunctionTypeSpecifyingExtension.php 0000666 00000003460 13436755504 0020365 0 ustar 00 getName()) === 'is_subclass_of'
&& count($node->args) >= 2
&& !$context->null();
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
$objectType = $scope->getType($node->args[0]->value);
$stringType = new StringType();
if (
!$objectType instanceof MixedType
&& !$stringType->isSuperTypeOf($objectType)->no()
) {
return new SpecifiedTypes();
}
$classType = $scope->getType($node->args[1]->value);
if (!$classType instanceof ConstantStringType || $classType->getValue() === '') {
return new SpecifiedTypes();
}
return $this->typeSpecifier->specifyTypesInCondition(
$scope,
new \PhpParser\Node\Expr\Instanceof_(
$node->args[0]->value,
new \PhpParser\Node\Name($classType->getValue())
),
$context
);
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
}
src/Type/Php/GettimeofdayDynamicFunctionReturnTypeExtension.php 0000666 00000003441 13436755504 0021131 0 ustar 00 getName() === 'gettimeofday';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
$arrayType = new ConstantArrayType([
new ConstantStringType('sec'),
new ConstantStringType('usec'),
new ConstantStringType('minuteswest'),
new ConstantStringType('dsttime'),
], [
new IntegerType(),
new IntegerType(),
new IntegerType(),
new IntegerType(),
]);
$floatType = new FloatType();
if (!isset($functionCall->args[0])) {
return $arrayType;
}
$argType = $scope->getType($functionCall->args[0]->value);
$isTrueType = (new ConstantBooleanType(true))->isSuperTypeOf($argType);
$isFalseType = (new ConstantBooleanType(false))->isSuperTypeOf($argType);
$compareTypes = $isTrueType->compareTo($isFalseType);
if ($compareTypes === $isTrueType) {
return $floatType;
}
if ($compareTypes === $isFalseType) {
return $arrayType;
}
if ($argType instanceof MixedType) {
return new BenevolentUnionType([$arrayType, $floatType]);
}
return new UnionType([$arrayType, $floatType]);
}
}
src/Type/Php/ArrayKeyExistsFunctionTypeSpecifyingExtension.php 0000666 00000002760 13436755504 0020756 0 ustar 00 typeSpecifier = $typeSpecifier;
}
public function isFunctionSupported(
FunctionReflection $functionReflection,
FuncCall $node,
TypeSpecifierContext $context
): bool
{
return $functionReflection->getName() === 'array_key_exists'
&& count($node->args) >= 2
&& !$context->null();
}
public function specifyTypes(
FunctionReflection $functionReflection,
FuncCall $node,
Scope $scope,
TypeSpecifierContext $context
): SpecifiedTypes
{
$keyType = $scope->getType($node->args[0]->value);
return $this->typeSpecifier->create(
$node->args[1]->value,
TypeCombinator::intersect(
new ArrayType(new MixedType(), new MixedType()),
new HasOffsetType($keyType)
),
$context
);
}
}
src/Type/Php/StatDynamicReturnTypeExtension.php 0000666 00000003615 13436755504 0015720 0 ustar 00 getName(), ['stat', 'lstat', 'fstat', 'ssh2_sftp_stat'], true);
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
return $this->getReturnType();
}
public function getClass(): string
{
return \SplFileObject::class;
}
public function isMethodSupported(MethodReflection $methodReflection): bool
{
return $methodReflection->getName() === 'fstat';
}
public function getTypeFromMethodCall(MethodReflection $methodReflection, MethodCall $methodCall, Scope $scope): Type
{
return $this->getReturnType();
}
private function getReturnType(): Type
{
$valueType = new IntegerType();
$builder = ConstantArrayTypeBuilder::createEmpty();
$keys = [
'dev',
'ino',
'mode',
'nlink',
'uid',
'gid',
'rdev',
'size',
'atime',
'mtime',
'ctime',
'blksize',
'blocks',
];
foreach ($keys as $key) {
$builder->setOffsetValueType(null, $valueType);
}
foreach ($keys as $key) {
$builder->setOffsetValueType(new ConstantStringType($key), $valueType);
}
return TypeCombinator::union($builder->getArray(), new ConstantBooleanType(false));
}
}
src/Type/Php/ArrayMapFunctionReturnTypeExtension.php 0000666 00000003763 13436755504 0016726 0 ustar 00 getName() === 'array_map';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
if (count($functionCall->args) < 2) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$valueType = new MixedType();
$callableType = $scope->getType($functionCall->args[0]->value);
if (!$callableType->isCallable()->no()) {
$valueType = ParametersAcceptorSelector::selectFromArgs(
$scope,
$functionCall->args,
$callableType->getCallableParametersAcceptors($scope)
)->getReturnType();
}
$arrayType = $scope->getType($functionCall->args[1]->value);
$constantArrays = TypeUtils::getConstantArrays($arrayType);
if (count($constantArrays) > 0) {
$arrayTypes = [];
foreach ($constantArrays as $constantArray) {
$returnedArrayBuilder = ConstantArrayTypeBuilder::createEmpty();
foreach ($constantArray->getKeyTypes() as $keyType) {
$returnedArrayBuilder->setOffsetValueType(
$keyType,
$valueType
);
}
$arrayTypes[] = $returnedArrayBuilder->getArray();
}
return TypeCombinator::union(...$arrayTypes);
} elseif ($arrayType instanceof ArrayType) {
return new ArrayType(
$arrayType->getIterableKeyType(),
$valueType
);
}
return new ArrayType(
new MixedType(),
$valueType
);
}
}
src/Type/Php/ArgumentBasedFunctionReturnTypeExtension.php 0000666 00000003746 13436755504 0017734 0 ustar 00 0,
'array_reverse' => 0,
'array_change_key_case' => 0,
'array_diff_assoc' => 0,
'array_diff_key' => 0,
'array_diff_uassoc' => 0,
'array_diff_ukey' => 0,
'array_diff' => 0,
'array_udiff_assoc' => 0,
'array_udiff_uassoc' => 0,
'array_udiff' => 0,
'array_intersect_assoc' => 0,
'array_intersect_key' => 0,
'array_intersect_uassoc' => 0,
'array_intersect_ukey' => 0,
'array_intersect' => 0,
'array_uintersect_assoc' => 0,
'array_uintersect_uassoc' => 0,
'array_uintersect' => 0,
];
public function isFunctionSupported(FunctionReflection $functionReflection): bool
{
return isset($this->functionNames[$functionReflection->getName()]);
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
$argumentPosition = $this->functionNames[$functionReflection->getName()];
if (!isset($functionCall->args[$argumentPosition])) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$argument = $functionCall->args[$argumentPosition];
$argumentType = $scope->getType($argument->value);
$argumentKeyType = $argumentType->getIterableKeyType();
$argumentValueType = $argumentType->getIterableValueType();
if ($argument->unpack) {
$argumentKeyType = TypeUtils::generalizeType($argumentKeyType);
$argumentValueType = TypeUtils::generalizeType($argumentValueType->getIterableValueType());
}
return new ArrayType(
$argumentKeyType,
$argumentValueType
);
}
}
src/Type/Php/ArrayPopFunctionReturnTypeExtension.php 0000666 00000002356 13436755504 0016744 0 ustar 00 getName() === 'array_pop';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
if (!isset($functionCall->args[0])) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$argType = $scope->getType($functionCall->args[0]->value);
$arrayTypes = TypeUtils::getArrays($argType);
if (count($arrayTypes) > 0) {
$resultTypes = [];
foreach ($arrayTypes as $arrayType) {
$resultTypes[] = $arrayType->getLastValueType();
}
return TypeCombinator::union(...$resultTypes);
}
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
}
src/Type/Php/IsAFunctionTypeSpecifyingExtension.php 0000666 00000005533 13436755504 0016504 0 ustar 00 getName()) === 'is_a'
&& isset($node->args[0])
&& isset($node->args[1])
&& !$context->null();
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
if ($context->null()) {
throw new \PHPStan\ShouldNotHappenException();
}
$classNameArgExpr = $node->args[1]->value;
$classNameArgExprType = $scope->getType($classNameArgExpr);
if (
$classNameArgExpr instanceof ClassConstFetch
&& $classNameArgExpr->class instanceof Name
&& $classNameArgExpr->name instanceof \PhpParser\Node\Identifier
&& strtolower($classNameArgExpr->name->name) === 'class'
) {
$className = $scope->resolveName($classNameArgExpr->class);
if (strtolower($classNameArgExpr->class->toString()) === 'static') {
$objectType = new StaticType($className);
} else {
$objectType = new ObjectType($className);
}
$types = $this->typeSpecifier->create($node->args[0]->value, $objectType, $context);
} elseif ($classNameArgExprType instanceof ConstantStringType) {
$objectType = new ObjectType($classNameArgExprType->getValue());
$types = $this->typeSpecifier->create($node->args[0]->value, $objectType, $context);
} elseif ($context->true()) {
$objectType = new ObjectWithoutClassType();
$types = $this->typeSpecifier->create($node->args[0]->value, $objectType, $context);
} else {
$types = new SpecifiedTypes();
}
if (isset($node->args[2]) && $context->true()) {
if (!$scope->getType($node->args[2]->value)->isSuperTypeOf(new ConstantBooleanType(true))->no()) {
$types = $types->intersectWith($this->typeSpecifier->create($node->args[0]->value, new StringType(), $context));
}
}
return $types;
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
}
src/Type/Php/MicrotimeFunctionReturnTypeExtension.php 0000666 00000002635 13436755504 0017137 0 ustar 00 getName() === 'microtime';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
if (count($functionCall->args) < 1) {
return new StringType();
}
$argType = $scope->getType($functionCall->args[0]->value);
$isTrueType = (new ConstantBooleanType(true))->isSuperTypeOf($argType);
$isFalseType = (new ConstantBooleanType(false))->isSuperTypeOf($argType);
$compareTypes = $isTrueType->compareTo($isFalseType);
if ($compareTypes === $isTrueType) {
return new FloatType();
}
if ($compareTypes === $isFalseType) {
return new StringType();
}
if ($argType instanceof MixedType) {
return new BenevolentUnionType([new StringType(), new FloatType()]);
}
return new UnionType([new StringType(), new FloatType()]);
}
}
src/Type/Php/IsIntFunctionTypeSpecifyingExtension.php 0000666 00000002517 13436755504 0017055 0 ustar 00 getName()), [
'is_int',
'is_integer',
'is_long',
], true)
&& isset($node->args[0])
&& !$context->null();
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
if ($context->null()) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->typeSpecifier->create($node->args[0]->value, new IntegerType(), $context);
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
}
src/Type/Php/ExplodeFunctionDynamicReturnTypeExtension.php 0000666 00000003052 13436755504 0020106 0 ustar 00 getName() === 'explode';
}
public function getTypeFromFunctionCall(
FunctionReflection $functionReflection,
FuncCall $functionCall,
Scope $scope
): Type
{
if (count($functionCall->args) < 2) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$delimiterType = $scope->getType($functionCall->args[0]->value);
$isSuperset = (new ConstantStringType(''))->isSuperTypeOf($delimiterType);
if ($isSuperset->yes()) {
return new ConstantBooleanType(false);
} elseif ($isSuperset->no()) {
return new ArrayType(new IntegerType(), new StringType());
}
$returnType = ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
if ($delimiterType instanceof MixedType) {
return TypeUtils::toBenevolentUnion($returnType);
}
return $returnType;
}
}
src/Type/Php/ArrayPointerFunctionsDynamicReturnTypeExtension.php 0000666 00000003340 13436755504 0021310 0 ustar 00 getName(), $this->functions, true);
}
public function getTypeFromFunctionCall(
FunctionReflection $functionReflection,
FuncCall $functionCall,
Scope $scope
): Type
{
if (count($functionCall->args) === 0) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$argType = $scope->getType($functionCall->args[0]->value);
$constantArrays = TypeUtils::getConstantArrays($argType);
if (count($constantArrays) > 0) {
$keyTypes = [];
foreach ($constantArrays as $constantArray) {
$arrayKeyTypes = $constantArray->getKeyTypes();
if (count($arrayKeyTypes) === 0) {
$keyTypes[] = new ConstantBooleanType(false);
continue;
}
$valueOffset = $functionReflection->getName() === 'reset'
? $arrayKeyTypes[0]
: $arrayKeyTypes[count($arrayKeyTypes) - 1];
$keyTypes[] = $constantArray->getOffsetValueType($valueOffset);
}
return TypeCombinator::union(...$keyTypes);
}
return TypeCombinator::union(
$argType->getIterableValueType(),
new ConstantBooleanType(false)
);
}
}
src/Type/Php/StrtotimeFunctionReturnTypeExtension.php 0000666 00000002725 13436755504 0017201 0 ustar 00 getName() === 'strtotime';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
$defaultReturnType = ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
if (count($functionCall->args) === 0) {
return $defaultReturnType;
}
$argType = $scope->getType($functionCall->args[0]->value);
if ($argType instanceof MixedType) {
return TypeUtils::toBenevolentUnion($defaultReturnType);
}
$result = array_unique(array_map(static function (ConstantStringType $string): bool {
return is_int(strtotime($string->getValue()));
}, TypeUtils::getConstantStrings($argType)));
if (count($result) !== 1) {
return $defaultReturnType;
}
return $result[0] ? new IntegerType() : new ConstantBooleanType(false);
}
}
src/Type/Php/DefineConstantTypeSpecifyingExtension.php 0000666 00000003062 13436755504 0017221 0 ustar 00 typeSpecifier = $typeSpecifier;
}
public function isFunctionSupported(
FunctionReflection $functionReflection,
FuncCall $node,
TypeSpecifierContext $context
): bool
{
return $functionReflection->getName() === 'define'
&& $context->null()
&& count($node->args) >= 2;
}
public function specifyTypes(
FunctionReflection $functionReflection,
FuncCall $node,
Scope $scope,
TypeSpecifierContext $context
): SpecifiedTypes
{
$constantName = $scope->getType($node->args[0]->value);
if (
!$constantName instanceof ConstantStringType
|| $constantName->getValue() === ''
) {
return new SpecifiedTypes([], []);
}
return $this->typeSpecifier->create(
new \PhpParser\Node\Expr\ConstFetch(
new \PhpParser\Node\Name\FullyQualified($constantName->getValue())
),
$scope->getType($node->args[1]->value),
TypeSpecifierContext::createTruthy()
);
}
}
src/Type/Php/GetParentClassDynamicFunctionReturnTypeExtension.php 0000666 00000005416 13436755504 0021373 0 ustar 00 broker = $broker;
}
public function isFunctionSupported(
FunctionReflection $functionReflection
): bool
{
return $functionReflection->getName() === 'get_parent_class';
}
public function getTypeFromFunctionCall(
FunctionReflection $functionReflection,
FuncCall $functionCall,
Scope $scope
): Type
{
$defaultReturnType = ParametersAcceptorSelector::selectSingle(
$functionReflection->getVariants()
)->getReturnType();
if (count($functionCall->args) === 0) {
if ($scope->isInTrait()) {
return $defaultReturnType;
}
if ($scope->isInClass()) {
return $this->findParentClassType(
$scope->getClassReflection()
);
}
return new ConstantBooleanType(false);
}
$argType = $scope->getType($functionCall->args[0]->value);
if ($scope->isInTrait() && TypeUtils::findThisType($argType) !== null) {
return $defaultReturnType;
}
$constantStrings = TypeUtils::getConstantStrings($argType);
if (count($constantStrings) > 0) {
return \PHPStan\Type\TypeCombinator::union(...array_map(function (ConstantStringType $stringType): Type {
return $this->findParentClassNameType($stringType->getValue());
}, $constantStrings));
}
$classNames = TypeUtils::getDirectClassNames($argType);
if (count($classNames) > 0) {
return \PHPStan\Type\TypeCombinator::union(...array_map(function (string $classNames): Type {
return $this->findParentClassNameType($classNames);
}, $classNames));
}
return $defaultReturnType;
}
private function findParentClassNameType(string $className): Type
{
if (!$this->broker->hasClass($className)) {
return new UnionType([
new StringType(),
new ConstantBooleanType(false),
]);
}
return $this->findParentClassType($this->broker->getClass($className));
}
private function findParentClassType(
ClassReflection $classReflection
): Type
{
$parentClass = $classReflection->getParentClass();
if ($parentClass === false) {
return new ConstantBooleanType(false);
}
return new ConstantStringType($parentClass->getName());
}
}
src/Type/Php/IsBoolFunctionTypeSpecifyingExtension.php 0000666 00000002433 13436755504 0017213 0 ustar 00 getName()) === 'is_bool'
&& isset($node->args[0])
&& !$context->null();
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
if ($context->null()) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->typeSpecifier->create($node->args[0]->value, new BooleanType(), $context);
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
}
src/Type/Php/ArrayShiftFunctionReturnTypeExtension.php 0000666 00000002363 13436755504 0017261 0 ustar 00 getName() === 'array_shift';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
if (!isset($functionCall->args[0])) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$argType = $scope->getType($functionCall->args[0]->value);
$arrayTypes = TypeUtils::getArrays($argType);
if (count($arrayTypes) > 0) {
$resultTypes = [];
foreach ($arrayTypes as $arrayType) {
$resultTypes[] = $arrayType->getFirstValueType();
}
return TypeCombinator::union(...$resultTypes);
}
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
}
src/Type/Php/IsStringFunctionTypeSpecifyingExtension.php 0000666 00000002435 13436755504 0017570 0 ustar 00 getName()) === 'is_string'
&& isset($node->args[0])
&& !$context->null();
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
if ($context->null()) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->typeSpecifier->create($node->args[0]->value, new StringType(), $context);
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
}
src/Type/Php/IsCallableFunctionTypeSpecifyingExtension.php 0000666 00000002445 13436755504 0020022 0 ustar 00 getName()) === 'is_callable'
&& isset($node->args[0])
&& !$context->null();
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
if ($context->null()) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->typeSpecifier->create($node->args[0]->value, new CallableType(), $context);
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
}
src/Type/Php/CountFunctionReturnTypeExtension.php 0000666 00000002264 13436755504 0016275 0 ustar 00 getName() === 'count';
}
public function getTypeFromFunctionCall(
FunctionReflection $functionReflection,
FuncCall $functionCall,
Scope $scope
): Type
{
if (count($functionCall->args) < 1) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$arrays = TypeUtils::getArrays($scope->getType($functionCall->args[0]->value));
if (count($arrays) === 0) {
return ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
}
$countTypes = [];
foreach ($arrays as $array) {
$countTypes[] = $array->count();
}
return TypeCombinator::union(...$countTypes);
}
}
src/Type/Php/VersionCompareFunctionDynamicReturnTypeExtension.php 0000666 00000005174 13436755504 0021451 0 ustar 00 getName() === 'version_compare';
}
public function getTypeFromFunctionCall(
FunctionReflection $functionReflection,
FuncCall $functionCall,
Scope $scope
): Type
{
if (count($functionCall->args) < 2) {
return ParametersAcceptorSelector::selectFromArgs($scope, $functionCall->args, $functionReflection->getVariants())->getReturnType();
}
$version1Strings = TypeUtils::getConstantStrings($scope->getType($functionCall->args[0]->value));
$version2Strings = TypeUtils::getConstantStrings($scope->getType($functionCall->args[1]->value));
$counts = [
count($version1Strings),
count($version2Strings),
];
if (isset($functionCall->args[2])) {
$operatorStrings = TypeUtils::getConstantStrings($scope->getType($functionCall->args[2]->value));
$counts[] = count($operatorStrings);
$returnType = new BooleanType();
} else {
$returnType = TypeCombinator::union(
new ConstantIntegerType(-1),
new ConstantIntegerType(0),
new ConstantIntegerType(1)
);
}
if (count(array_filter($counts, static function (int $count): bool {
return $count === 0;
})) > 0) {
return $returnType; // one of the arguments is not a constant string
}
if (count(array_filter($counts, static function (int $count): bool {
return $count > 1;
})) > 1) {
return $returnType; // more than one argument can have multiple possibilities, avoid combinatorial explosion
}
$types = [];
foreach ($version1Strings as $version1String) {
foreach ($version2Strings as $version2String) {
if (isset($operatorStrings)) {
foreach ($operatorStrings as $operatorString) {
$value = version_compare($version1String->getValue(), $version2String->getValue(), $operatorString->getValue());
$types[$value] = new ConstantBooleanType($value);
}
} else {
$value = version_compare($version1String->getValue(), $version2String->getValue());
$types[$value] = new ConstantIntegerType($value);
}
}
}
return TypeCombinator::union(...$types);
}
}
src/Type/Php/StrSplitFunctionReturnTypeExtension.php 0000666 00000004674 13436755504 0017000 0 ustar 00 getName() === 'str_split';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
$defaultReturnType = ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getReturnType();
if (count($functionCall->args) < 1) {
return $defaultReturnType;
}
$splitLength = 1;
if (count($functionCall->args) >= 2) {
$splitLengthType = $scope->getType($functionCall->args[1]->value);
if (!$splitLengthType instanceof ConstantIntegerType) {
return $defaultReturnType;
}
$splitLength = $splitLengthType->getValue();
if ($splitLength < 1) {
return new ConstantBooleanType(false);
}
}
$stringType = $scope->getType($functionCall->args[0]->value);
if (!$stringType instanceof ConstantStringType) {
return new ArrayType(new IntegerType(), new StringType());
}
$stringValue = $stringType->getValue();
$items = str_split($stringValue, $splitLength);
if (!is_array($items)) {
throw new \PHPStan\ShouldNotHappenException();
}
return self::createConstantArrayFrom($items, $scope);
}
private static function createConstantArrayFrom(array $constantArray, Scope $scope): ConstantArrayType
{
$keyTypes = [];
$valueTypes = [];
$isList = true;
$i = 0;
foreach ($constantArray as $key => $value) {
$keyType = $scope->getTypeFromValue($key);
if (!$keyType instanceof ConstantIntegerType) {
throw new \PHPStan\ShouldNotHappenException();
}
$keyTypes[] = $keyType;
$valueTypes[] = $scope->getTypeFromValue($value);
$isList = $isList && $key === $i;
$i++;
}
return new ConstantArrayType($keyTypes, $valueTypes, $isList ? $i : 0);
}
}
src/Type/Php/ArrayFilterFunctionReturnTypeReturnTypeExtension.php 0000666 00000007134 13436755504 0021474 0 ustar 00 getName() === 'array_filter';
}
public function getTypeFromFunctionCall(FunctionReflection $functionReflection, FuncCall $functionCall, Scope $scope): Type
{
$arrayArg = $functionCall->args[0]->value ?? null;
$callbackArg = $functionCall->args[1]->value ?? null;
$flagArg = $functionCall->args[2]->value ?? null;
if ($arrayArg !== null) {
$arrayArgType = $scope->getType($arrayArg);
$keyType = $arrayArgType->getIterableKeyType();
$itemType = $arrayArgType->getIterableValueType();
if ($callbackArg === null) {
return TypeCombinator::union(
...array_map([$this, 'removeFalsey'], TypeUtils::getArrays($arrayArgType))
);
}
if ($flagArg === null && $callbackArg instanceof Closure && count($callbackArg->stmts) === 1) {
$statement = $callbackArg->stmts[0];
if ($statement instanceof Return_ && $statement->expr !== null && count($callbackArg->params) > 0) {
if (!$callbackArg->params[0]->var instanceof Variable || !is_string($callbackArg->params[0]->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
$itemVariableName = $callbackArg->params[0]->var->name;
$scope = $scope->assignVariable($itemVariableName, $itemType, TrinaryLogic::createYes());
$scope = $scope->filterByTruthyValue($statement->expr);
$itemType = $scope->getVariableType($itemVariableName);
}
}
} else {
$keyType = new MixedType();
$itemType = new MixedType();
}
return new ArrayType($keyType, $itemType);
}
public function removeFalsey(Type $type): Type
{
$falseyTypes = new UnionType([
new NullType(),
new ConstantBooleanType(false),
new ConstantIntegerType(0),
new ConstantFloatType(0.0),
new ConstantStringType(''),
new ConstantArrayType([], []),
]);
if ($type instanceof ConstantArrayType) {
$keys = $type->getKeyTypes();
$values = $type->getValueTypes();
$generalize = false;
foreach ($values as $offset => $value) {
$isFalsey = $falseyTypes->isSuperTypeOf($value);
if ($isFalsey->yes()) {
unset($keys[$offset], $values[$offset]);
} elseif ($isFalsey->maybe()) {
$values[$offset] = TypeCombinator::remove($values[$offset], $falseyTypes);
$generalize = true;
}
}
$filteredArray = new ConstantArrayType(array_values($keys), array_values($values));
return $generalize ? $filteredArray->generalize() : $filteredArray;
}
$keyType = $type->getIterableKeyType();
$valueType = $type->getIterableValueType();
$valueType = TypeCombinator::remove($valueType, $falseyTypes);
if ($valueType instanceof NeverType) {
return new ConstantArrayType([], []);
}
return new ArrayType($keyType, $valueType);
}
}
src/Type/Php/IsFloatFunctionTypeSpecifyingExtension.php 0000666 00000002516 13436755504 0017367 0 ustar 00 getName()), [
'is_float',
'is_double',
'is_real',
], true)
&& isset($node->args[0])
&& !$context->null();
}
public function specifyTypes(FunctionReflection $functionReflection, FuncCall $node, Scope $scope, TypeSpecifierContext $context): SpecifiedTypes
{
if ($context->null()) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->typeSpecifier->create($node->args[0]->value, new FloatType(), $context);
}
public function setTypeSpecifier(TypeSpecifier $typeSpecifier): void
{
$this->typeSpecifier = $typeSpecifier;
}
}
src/Type/Php/VarExportFunctionDynamicReturnTypeExtension.php 0000666 00000003023 13436755504 0020436 0 ustar 00 getName(),
[
'var_export',
'highlight_file',
'highlight_string',
'print_r',
],
true
);
}
public function getTypeFromFunctionCall(\PHPStan\Reflection\FunctionReflection $functionReflection, \PhpParser\Node\Expr\FuncCall $functionCall, \PHPStan\Analyser\Scope $scope): \PHPStan\Type\Type
{
if ($functionReflection->getName() === 'var_export') {
$fallbackReturnType = new NullType();
} elseif ($functionReflection->getName() === 'print_r') {
$fallbackReturnType = new ConstantBooleanType(true);
} else {
$fallbackReturnType = new BooleanType();
}
if (count($functionCall->args) < 1) {
return TypeCombinator::union(
new StringType(),
$fallbackReturnType
);
}
if (count($functionCall->args) < 2) {
return $fallbackReturnType;
}
$returnArgumentType = $scope->getType($functionCall->args[1]->value);
if ((new ConstantBooleanType(true))->isSuperTypeOf($returnArgumentType)->yes()) {
return new StringType();
}
return $fallbackReturnType;
}
}
src/Type/ObjectWithoutClassType.php 0000666 00000006073 13436755504 0013435 0 ustar 00 isSubTypeOf($this);
}
if ($type instanceof self || $type instanceof TypeWithClassName) {
return TrinaryLogic::createYes();
}
if ($type instanceof ClosureType) {
return TrinaryLogic::createYes();
}
return TrinaryLogic::createNo();
}
public function equals(Type $type): bool
{
return $type instanceof self;
}
public function describe(VerbosityLevel $level): string
{
return 'object';
}
public function canAccessProperties(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function canCallMethods(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasMethod(string $methodName): bool
{
return false;
}
public function getMethod(string $methodName, ClassMemberAccessAnswerer $scope): MethodReflection
{
throw new \PHPStan\ShouldNotHappenException();
}
public function canAccessConstants(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasConstant(string $constantName): bool
{
return false;
}
public function getConstant(string $constantName): ConstantReflection
{
throw new \PHPStan\ShouldNotHappenException();
}
public function isCloneable(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function toNumber(): Type
{
return new ErrorType();
}
public function toString(): Type
{
return new ErrorType();
}
public function toInteger(): Type
{
return new ErrorType();
}
public function toFloat(): Type
{
return new ErrorType();
}
public function toArray(): Type
{
return new ArrayType(new MixedType(), new MixedType());
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self();
}
}
src/Type/StringType.php 0000666 00000005125 13436755504 0011120 0 ustar 00 isSuperTypeOf($offsetType)->and(TrinaryLogic::createMaybe());
}
public function getOffsetValueType(Type $offsetType): Type
{
if ($this->hasOffsetValueType($offsetType)->no()) {
return new ErrorType();
}
return new StringType();
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): Type
{
$valueStringType = $valueType->toString();
if ($valueStringType instanceof ErrorType) {
return new ErrorType();
}
if (
$offsetType === null
|| (new IntegerType())->isSuperTypeOf($offsetType)->yes()
) {
return new StringType();
}
return new ErrorType();
}
public function accepts(Type $type, bool $strictTypes): TrinaryLogic
{
if ($type instanceof self) {
return TrinaryLogic::createYes();
}
if ($type instanceof CompoundType) {
return CompoundTypeHelper::accepts($type, $this, $strictTypes);
}
if ($type instanceof TypeWithClassName && !$strictTypes) {
$broker = Broker::getInstance();
if (!$broker->hasClass($type->getClassName())) {
return TrinaryLogic::createNo();
}
$typeClass = $broker->getClass($type->getClassName());
return TrinaryLogic::createFromBoolean(
$typeClass->hasNativeMethod('__toString')
);
}
return TrinaryLogic::createNo();
}
public function toNumber(): Type
{
return new ErrorType();
}
public function toInteger(): Type
{
return new IntegerType();
}
public function toFloat(): Type
{
return new FloatType();
}
public function toString(): Type
{
return $this;
}
public function toArray(): Type
{
return new ConstantArrayType(
[new ConstantIntegerType(0)],
[$this],
1
);
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self();
}
}
src/Type/CommentHelper.php 0000666 00000000433 13436755504 0011547 0 ustar 00 getDocComment();
if ($phpDoc !== null) {
return $phpDoc->getText();
}
return null;
}
}
src/Type/JustNullableTypeTrait.php 0000666 00000001521 13436755504 0013256 0 ustar 00 isSubTypeOf($this);
}
return TrinaryLogic::createNo();
}
public function equals(Type $type): bool
{
return $type instanceof self;
}
}
src/Type/ConstantScalarType.php 0000666 00000000301 13436755504 0012560 0 ustar 00 keyType = $keyType;
$this->itemType = $itemType;
}
public function getItemType(): Type
{
return $this->itemType;
}
/**
* @return string[]
*/
public function getReferencedClasses(): array
{
return array_merge(
$this->keyType->getReferencedClasses(),
$this->getItemType()->getReferencedClasses()
);
}
public function accepts(Type $type, bool $strictTypes): TrinaryLogic
{
if ($type instanceof CompoundType) {
return CompoundTypeHelper::accepts($type, $this, $strictTypes);
}
if ($type->isIterable()->yes()) {
return $this->getIterableValueType()->accepts($type->getIterableValueType(), $strictTypes)
->and($this->getIterableKeyType()->accepts($type->getIterableKeyType(), $strictTypes));
}
return TrinaryLogic::createNo();
}
public function isSuperTypeOf(Type $type): TrinaryLogic
{
return $type->isIterable()
->and($this->getIterableValueType()->isSuperTypeOf($type->getIterableValueType()))
->and($this->getIterableKeyType()->isSuperTypeOf($type->getIterableKeyType()));
}
public function isSubTypeOf(Type $otherType): TrinaryLogic
{
if ($otherType instanceof IntersectionType || $otherType instanceof UnionType) {
return $otherType->isSuperTypeOf(new UnionType([
new ArrayType($this->keyType, $this->itemType),
new IntersectionType([
new ObjectType(\Traversable::class),
$this,
]),
]));
}
if ($otherType instanceof self) {
$limit = TrinaryLogic::createYes();
} else {
$limit = TrinaryLogic::createMaybe();
}
return $limit->and(
$otherType->isIterable(),
$otherType->getIterableValueType()->isSuperTypeOf($this->itemType),
$otherType->getIterableKeyType()->isSuperTypeOf($this->keyType)
);
}
public function equals(Type $type): bool
{
if (!$type instanceof self) {
return false;
}
return $this->keyType->equals($type->keyType)
&& $this->itemType->equals($type->itemType);
}
public function describe(VerbosityLevel $level): string
{
if ($this->keyType instanceof MixedType) {
if ($this->itemType instanceof MixedType) {
return 'iterable';
}
return sprintf('iterable<%s>', $this->itemType->describe($level));
}
return sprintf('iterable<%s, %s>', $this->keyType->describe($level), $this->itemType->describe($level));
}
public function toNumber(): Type
{
return new ErrorType();
}
public function toString(): Type
{
return new ErrorType();
}
public function toInteger(): Type
{
return new ErrorType();
}
public function toFloat(): Type
{
return new ErrorType();
}
public function toArray(): Type
{
return new ArrayType($this->keyType, $this->getItemType());
}
public function resolveStatic(string $className): Type
{
if ($this->getItemType() instanceof StaticResolvableType) {
return new self(
$this->keyType,
$this->getItemType()->resolveStatic($className)
);
}
return $this;
}
public function changeBaseClass(string $className): StaticResolvableType
{
if ($this->getItemType() instanceof StaticResolvableType) {
return new self(
$this->keyType,
$this->getItemType()->changeBaseClass($className)
);
}
return $this;
}
public function isIterable(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function getIterableKeyType(): Type
{
return $this->keyType;
}
public function getIterableValueType(): Type
{
return $this->getItemType();
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self($properties['keyType'], $properties['itemType']);
}
}
src/Type/ArrayType.php 0000666 00000015757 13436755504 0010744 0 ustar 00 describe(VerbosityLevel::value()) === '(int|string)') {
$keyType = new MixedType();
}
$this->keyType = $keyType;
$this->itemType = $itemType;
}
public function getKeyType(): Type
{
return $this->keyType;
}
public function getItemType(): Type
{
return $this->itemType;
}
/**
* @return string[]
*/
public function getReferencedClasses(): array
{
return array_merge(
$this->keyType->getReferencedClasses(),
$this->getItemType()->getReferencedClasses()
);
}
public function accepts(Type $type, bool $strictTypes): TrinaryLogic
{
$arrays = TypeUtils::getArrays($type);
if (count($arrays) > 0) {
$result = TrinaryLogic::createYes();
foreach ($arrays as $array) {
$result = $result
->and($this->getItemType()->accepts($array->getItemType(), $strictTypes))
->and($this->keyType->accepts($array->keyType, $strictTypes));
}
return $result;
}
if ($type instanceof CompoundType) {
return CompoundTypeHelper::accepts($type, $this, $strictTypes);
}
return TrinaryLogic::createNo();
}
public function isSuperTypeOf(Type $type): TrinaryLogic
{
if ($type instanceof self) {
return $this->getItemType()->isSuperTypeOf($type->getItemType())
->and($this->keyType->isSuperTypeOf($type->keyType));
}
if ($type instanceof CompoundType) {
return $type->isSubTypeOf($this);
}
return TrinaryLogic::createNo();
}
public function equals(Type $type): bool
{
return $type instanceof self
&& $this->getItemType()->equals($type->getItemType())
&& $this->keyType->equals($type->keyType);
}
public function describe(VerbosityLevel $level): string
{
if ($this->keyType instanceof MixedType || $this->keyType instanceof NeverType) {
if ($this->itemType instanceof MixedType || $this->itemType instanceof NeverType) {
return 'array';
}
return sprintf('array<%s>', $this->itemType->describe($level));
}
return sprintf('array<%s, %s>', $this->keyType->describe($level), $this->itemType->describe($level));
}
public function generalizeValues(): self
{
return new self($this->keyType, TypeUtils::generalizeType($this->itemType));
}
public function getKeysArray(): self
{
return new self(new IntegerType(), $this->keyType);
}
public function getValuesArray(): self
{
return new self(new IntegerType(), $this->itemType);
}
public function resolveStatic(string $className): Type
{
if ($this->getItemType() instanceof StaticResolvableType) {
return new self(
$this->keyType,
$this->getItemType()->resolveStatic($className)
);
}
return $this;
}
public function changeBaseClass(string $className): StaticResolvableType
{
if ($this->getItemType() instanceof StaticResolvableType) {
return new self(
$this->keyType,
$this->getItemType()->changeBaseClass($className)
);
}
return $this;
}
public function isIterable(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function getIterableKeyType(): Type
{
$keyType = $this->keyType;
if ($keyType instanceof MixedType) {
return new BenevolentUnionType([new IntegerType(), new StringType()]);
}
return $keyType;
}
public function getIterableValueType(): Type
{
return $this->getItemType();
}
public function isOffsetAccessible(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasOffsetValueType(Type $offsetType): TrinaryLogic
{
$offsetType = self::castToArrayKeyType($offsetType);
if ($this->getKeyType()->isSuperTypeOf($offsetType)->no()) {
return TrinaryLogic::createNo();
}
return TrinaryLogic::createMaybe();
}
public function getOffsetValueType(Type $offsetType): Type
{
$offsetType = self::castToArrayKeyType($offsetType);
if ($this->getKeyType()->isSuperTypeOf($offsetType)->no()) {
return new ErrorType();
}
$type = $this->getItemType();
if ($type instanceof ErrorType) {
return new MixedType();
}
return $type;
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): Type
{
if ($offsetType === null) {
$offsetType = new IntegerType();
}
return new ArrayType(
TypeCombinator::union($this->keyType, self::castToArrayKeyType($offsetType)),
TypeCombinator::union($this->itemType, $valueType)
);
}
public function isCallable(): TrinaryLogic
{
return TrinaryLogic::createMaybe()->and((new StringType())->isSuperTypeOf($this->itemType));
}
/**
* @param \PHPStan\Reflection\ClassMemberAccessAnswerer $scope
* @return \PHPStan\Reflection\ParametersAcceptor[]
*/
public function getCallableParametersAcceptors(ClassMemberAccessAnswerer $scope): array
{
if ($this->isCallable()->no()) {
throw new \PHPStan\ShouldNotHappenException();
}
return [new TrivialParametersAcceptor()];
}
public function toNumber(): Type
{
return new ErrorType();
}
public function toString(): Type
{
return new ErrorType();
}
public function toInteger(): Type
{
return new ErrorType();
}
public function toFloat(): Type
{
return new ErrorType();
}
public function toArray(): Type
{
return $this;
}
public function count(): Type
{
return new IntegerType();
}
public function getFirstValueType(): Type
{
return TypeCombinator::union($this->getItemType(), new NullType());
}
public function getLastValueType(): Type
{
return $this->getFirstValueType();
}
public static function castToArrayKeyType(Type $offsetType): Type
{
if ($offsetType instanceof UnionType) {
return TypeCombinator::union(...array_map(static function (Type $type): Type {
return self::castToArrayKeyType($type);
}, $offsetType->getTypes()));
}
if ($offsetType instanceof ConstantScalarType) {
/** @var int|string $offsetValue */
$offsetValue = key([$offsetType->getValue() => null]);
return is_int($offsetValue) ? new ConstantIntegerType($offsetValue) : new ConstantStringType($offsetValue);
}
if ($offsetType instanceof IntegerType || $offsetType instanceof FloatType || $offsetType instanceof BooleanType) {
return new IntegerType();
}
if ($offsetType instanceof StringType) {
return new StringType();
}
return new UnionType([new IntegerType(), new StringType()]);
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self(
$properties['keyType'],
$properties['itemType']
);
}
}
src/Type/CallableType.php 0000666 00000010112 13436755504 0011341 0 ustar 00 */
private $parameters;
/** @var Type */
private $returnType;
/** @var bool */
private $variadic;
/** @var bool */
private $isCommonCallable;
/**
* @param array $parameters
* @param Type $returnType
* @param bool $variadic
*/
public function __construct(
?array $parameters = null,
?Type $returnType = null,
bool $variadic = true
)
{
if ($returnType === null) {
$returnType = new MixedType();
}
$this->parameters = $parameters ?? [];
$this->returnType = $returnType;
$this->variadic = $variadic;
$this->isCommonCallable = $parameters === null;
}
/**
* @return string[]
*/
public function getReferencedClasses(): array
{
return [];
}
public function accepts(Type $type, bool $strictTypes): TrinaryLogic
{
if ($type instanceof CompoundType) {
return CompoundTypeHelper::accepts($type, $this, $strictTypes);
}
return $this->isSuperTypeOf($type);
}
public function isSuperTypeOf(Type $type): TrinaryLogic
{
$isCallable = $type->isCallable();
if ($isCallable->no() || $this->isCommonCallable) {
return $isCallable;
}
static $scope;
if ($scope === null) {
$scope = new OutOfClassScope();
}
$variantsResult = null;
foreach ($type->getCallableParametersAcceptors($scope) as $variant) {
$isSuperType = CallableTypeHelper::isParametersAcceptorSuperTypeOf($this, $variant);
if ($variantsResult === null) {
$variantsResult = $isSuperType;
} else {
$variantsResult = $variantsResult->or($isSuperType);
}
}
if ($variantsResult === null) {
throw new \PHPStan\ShouldNotHappenException();
}
return $isCallable->and($variantsResult);
}
public function isSubTypeOf(Type $otherType): TrinaryLogic
{
if ($otherType instanceof IntersectionType || $otherType instanceof UnionType) {
return $otherType->isSuperTypeOf($this);
}
return $otherType->isCallable()
->and($otherType instanceof self ? TrinaryLogic::createYes() : TrinaryLogic::createMaybe());
}
public function equals(Type $type): bool
{
return $type instanceof self;
}
public function describe(VerbosityLevel $level): string
{
return 'callable';
}
public function isCallable(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
/**
* @param \PHPStan\Reflection\ClassMemberAccessAnswerer $scope
* @return \PHPStan\Reflection\ParametersAcceptor[]
*/
public function getCallableParametersAcceptors(ClassMemberAccessAnswerer $scope): array
{
return [$this];
}
public function toNumber(): Type
{
return new ErrorType();
}
public function toString(): Type
{
return new ErrorType();
}
public function toInteger(): Type
{
return new ErrorType();
}
public function toFloat(): Type
{
return new ErrorType();
}
public function toArray(): Type
{
return new ArrayType(new MixedType(), new MixedType());
}
/**
* @return array
*/
public function getParameters(): array
{
return $this->parameters;
}
public function isVariadic(): bool
{
return $this->variadic;
}
public function getReturnType(): Type
{
return $this->returnType;
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self(
(bool) $properties['isCommonCallable'] ? null : $properties['parameters'],
$properties['returnType'],
$properties['variadic']
);
}
}
src/Type/ClosureType.php 0000666 00000013761 13436755504 0011273 0 ustar 00 */
private $parameters;
/** @var Type */
private $returnType;
/** @var bool */
private $variadic;
/**
* @param array $parameters
* @param Type $returnType
* @param bool $variadic
*/
public function __construct(
array $parameters,
Type $returnType,
bool $variadic
)
{
$this->objectType = new ObjectType(\Closure::class);
$this->parameters = $parameters;
$this->returnType = $returnType;
$this->variadic = $variadic;
}
/**
* @return string[]
*/
public function getReferencedClasses(): array
{
$classes = $this->objectType->getReferencedClasses();
foreach ($this->parameters as $parameter) {
$classes = array_merge($classes, $parameter->getType()->getReferencedClasses());
}
return array_merge($classes, $this->returnType->getReferencedClasses());
}
public function accepts(Type $type, bool $strictTypes): TrinaryLogic
{
if ($type instanceof CompoundType) {
return CompoundTypeHelper::accepts($type, $this, $strictTypes);
}
if (!$type instanceof ClosureType) {
return $this->objectType->accepts($type, $strictTypes);
}
return $this->isSuperTypeOf($type);
}
public function isSuperTypeOf(Type $type): TrinaryLogic
{
if ($type instanceof self) {
return CallableTypeHelper::isParametersAcceptorSuperTypeOf(
$this,
$type
);
}
if ($type instanceof CompoundType) {
return $type->isSubTypeOf($this);
}
if ($type instanceof ObjectWithoutClassType) {
return TrinaryLogic::createMaybe();
}
if (
$type instanceof TypeWithClassName
&& $type->getClassName() === \Closure::class
) {
return TrinaryLogic::createMaybe();
}
return TrinaryLogic::createNo();
}
public function equals(Type $type): bool
{
if (!$type instanceof self) {
return false;
}
return $this->returnType->equals($type->returnType);
}
public function describe(VerbosityLevel $level): string
{
return sprintf(
'Closure(%s): %s',
implode(', ', array_map(static function (ParameterReflection $parameter) use ($level): string {
return $parameter->getType()->describe($level);
}, $this->parameters)),
$this->returnType->describe($level)
);
}
public function canAccessProperties(): TrinaryLogic
{
return $this->objectType->canAccessProperties();
}
public function hasProperty(string $propertyName): bool
{
return $this->objectType->hasProperty($propertyName);
}
public function getProperty(string $propertyName, ClassMemberAccessAnswerer $scope): PropertyReflection
{
return $this->objectType->getProperty($propertyName, $scope);
}
public function canCallMethods(): TrinaryLogic
{
return $this->objectType->canCallMethods();
}
public function hasMethod(string $methodName): bool
{
return $this->objectType->hasMethod($methodName);
}
public function getMethod(string $methodName, ClassMemberAccessAnswerer $scope): MethodReflection
{
return $this->objectType->getMethod($methodName, $scope);
}
public function canAccessConstants(): TrinaryLogic
{
return $this->objectType->canAccessConstants();
}
public function hasConstant(string $constantName): bool
{
return $this->objectType->hasConstant($constantName);
}
public function getConstant(string $constantName): ConstantReflection
{
return $this->objectType->getConstant($constantName);
}
public function isIterable(): TrinaryLogic
{
return TrinaryLogic::createNo();
}
public function getIterableKeyType(): Type
{
return new ErrorType();
}
public function getIterableValueType(): Type
{
return new ErrorType();
}
public function isOffsetAccessible(): TrinaryLogic
{
return TrinaryLogic::createNo();
}
public function hasOffsetValueType(Type $offsetType): TrinaryLogic
{
return TrinaryLogic::createNo();
}
public function getOffsetValueType(Type $offsetType): Type
{
return new ErrorType();
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): Type
{
return new ErrorType();
}
public function isCallable(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
/**
* @param \PHPStan\Reflection\ClassMemberAccessAnswerer $scope
* @return \PHPStan\Reflection\ParametersAcceptor[]
*/
public function getCallableParametersAcceptors(ClassMemberAccessAnswerer $scope): array
{
return [$this];
}
public function isCloneable(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function toBoolean(): BooleanType
{
return new ConstantBooleanType(true);
}
public function toNumber(): Type
{
return new ErrorType();
}
public function toInteger(): Type
{
return new ErrorType();
}
public function toFloat(): Type
{
return new ErrorType();
}
public function toString(): Type
{
return new ErrorType();
}
public function toArray(): Type
{
return new ConstantArrayType(
[new ConstantIntegerType(0)],
[$this],
1
);
}
/**
* @return array
*/
public function getParameters(): array
{
return $this->parameters;
}
public function isVariadic(): bool
{
return $this->variadic;
}
public function getReturnType(): Type
{
return $this->returnType;
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self(
$properties['parameters'],
$properties['returnType'],
$properties['variadic']
);
}
}
src/Type/StaticType.php 0000666 00000012150 13436755504 0011075 0 ustar 00 baseClass = $baseClass;
$this->staticObjectType = new ObjectType($baseClass);
}
public function getClassName(): string
{
return $this->baseClass;
}
protected function getStaticObjectType(): ObjectType
{
return $this->staticObjectType;
}
/**
* @return string[]
*/
public function getReferencedClasses(): array
{
return $this->staticObjectType->getReferencedClasses();
}
public function getBaseClass(): string
{
return $this->baseClass;
}
public function accepts(Type $type, bool $strictTypes): TrinaryLogic
{
return $this->staticObjectType->accepts($type, $strictTypes);
}
public function isSuperTypeOf(Type $type): TrinaryLogic
{
if ($type instanceof self) {
return $this->staticObjectType->isSuperTypeOf($type);
}
if ($type instanceof ObjectType) {
return TrinaryLogic::createMaybe()->and($this->staticObjectType->isSuperTypeOf($type));
}
if ($type instanceof CompoundType) {
return $type->isSubTypeOf($this);
}
return TrinaryLogic::createNo();
}
public function equals(Type $type): bool
{
return $this->staticObjectType->equals($type);
}
public function describe(VerbosityLevel $level): string
{
return sprintf('static(%s)', $this->staticObjectType->describe($level));
}
public function canAccessProperties(): TrinaryLogic
{
return $this->staticObjectType->canAccessProperties();
}
public function hasProperty(string $propertyName): bool
{
return $this->staticObjectType->hasProperty($propertyName);
}
public function getProperty(string $propertyName, ClassMemberAccessAnswerer $scope): PropertyReflection
{
return $this->staticObjectType->getProperty($propertyName, $scope);
}
public function canCallMethods(): TrinaryLogic
{
return $this->staticObjectType->canCallMethods();
}
public function hasMethod(string $methodName): bool
{
return $this->staticObjectType->hasMethod($methodName);
}
public function getMethod(string $methodName, ClassMemberAccessAnswerer $scope): MethodReflection
{
return $this->staticObjectType->getMethod($methodName, $scope);
}
public function canAccessConstants(): TrinaryLogic
{
return $this->staticObjectType->canAccessConstants();
}
public function hasConstant(string $constantName): bool
{
return $this->staticObjectType->hasConstant($constantName);
}
public function getConstant(string $constantName): ConstantReflection
{
return $this->staticObjectType->getConstant($constantName);
}
public function resolveStatic(string $className): Type
{
return new ObjectType($className);
}
public function changeBaseClass(string $className): StaticResolvableType
{
$thisClass = static::class;
return new $thisClass($className);
}
public function isIterable(): TrinaryLogic
{
return $this->staticObjectType->isInstanceOf(\Traversable::class);
}
public function getIterableKeyType(): Type
{
return $this->staticObjectType->getIterableKeyType();
}
public function getIterableValueType(): Type
{
return $this->staticObjectType->getIterableValueType();
}
public function isOffsetAccessible(): TrinaryLogic
{
return $this->staticObjectType->isInstanceOf(\ArrayAccess::class);
}
public function hasOffsetValueType(Type $offsetType): TrinaryLogic
{
return $this->staticObjectType->hasOffsetValueType($offsetType);
}
public function getOffsetValueType(Type $offsetType): Type
{
return $this->staticObjectType->getOffsetValueType($offsetType);
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): Type
{
return $this->staticObjectType->setOffsetValueType($offsetType, $valueType);
}
public function isCallable(): TrinaryLogic
{
return $this->staticObjectType->isCallable();
}
/**
* @param \PHPStan\Reflection\ClassMemberAccessAnswerer $scope
* @return \PHPStan\Reflection\ParametersAcceptor[]
*/
public function getCallableParametersAcceptors(ClassMemberAccessAnswerer $scope): array
{
return $this->staticObjectType->getCallableParametersAcceptors($scope);
}
public function isCloneable(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function toNumber(): Type
{
return new ErrorType();
}
public function toString(): Type
{
return $this->staticObjectType->toString();
}
public function toInteger(): Type
{
return new ErrorType();
}
public function toFloat(): Type
{
return new ErrorType();
}
public function toArray(): Type
{
return $this->staticObjectType->toArray();
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new static($properties['baseClass']);
}
}
src/Type/MethodTypeSpecifyingExtension.php 0000666 00000001133 13436755504 0015003 0 ustar 00 getTypes() as $type) {
$result = $getType($type);
if ($result instanceof ErrorType) {
continue;
}
$resultTypes[] = $result;
}
if (count($resultTypes) === 0) {
return new ErrorType();
}
return TypeCombinator::union(...$resultTypes);
}
}
src/Type/TypeWithClassName.php 0000666 00000000223 13436755504 0012346 0 ustar 00 describe(VerbosityLevel::value());
}, $types))
));
};
if (count($types) < 2) {
$throwException();
}
foreach ($types as $type) {
if (!($type instanceof UnionType)) {
continue;
}
$throwException();
}
$this->types = UnionTypeHelper::sortTypes($types);
}
/**
* @return \PHPStan\Type\Type[]
*/
public function getTypes(): array
{
return $this->types;
}
/**
* @return string[]
*/
public function getReferencedClasses(): array
{
return UnionTypeHelper::getReferencedClasses($this->getTypes());
}
public function accepts(Type $type, bool $strictTypes): TrinaryLogic
{
if ($type instanceof CompoundType) {
return CompoundTypeHelper::accepts($type, $this, $strictTypes);
}
return $this->unionResults(static function (Type $innerType) use ($strictTypes): TrinaryLogic {
return $innerType->accepts($innerType, $strictTypes);
});
}
public function isSuperTypeOf(Type $otherType): TrinaryLogic
{
if ($otherType instanceof self || $otherType instanceof IterableType) {
return $otherType->isSubTypeOf($this);
}
$results = [];
foreach ($this->getTypes() as $innerType) {
$results[] = $innerType->isSuperTypeOf($otherType);
}
return TrinaryLogic::createNo()->or(...$results);
}
public function isSubTypeOf(Type $otherType): TrinaryLogic
{
$results = [];
foreach ($this->getTypes() as $innerType) {
$results[] = $otherType->isSuperTypeOf($innerType);
}
return TrinaryLogic::extremeIdentity(...$results);
}
public function equals(Type $type): bool
{
if (!$type instanceof self) {
return false;
}
if (count($this->types) !== count($type->types)) {
return false;
}
foreach ($this->types as $i => $innerType) {
if (!$innerType->equals($type->types[$i])) {
return false;
}
}
return true;
}
public function describe(VerbosityLevel $level): string
{
$joinTypes = static function (array $types) use ($level): string {
$typeNames = [];
foreach ($types as $type) {
if ($type instanceof IntersectionType || $type instanceof ClosureType) {
$typeNames[] = sprintf('(%s)', $type->describe($level));
} else {
$typeNames[] = $type->describe($level);
}
}
return implode('|', $typeNames);
};
return $level->handle(
function () use ($joinTypes): string {
$types = TypeCombinator::union(...array_map(static function (Type $type): Type {
if (
$type instanceof ConstantType
&& !$type instanceof ConstantBooleanType
) {
return $type->generalize();
}
return $type;
}, $this->types));
if ($types instanceof UnionType) {
return $joinTypes($types->getTypes());
}
return $joinTypes([$types]);
},
function () use ($joinTypes): string {
$arrayDescription = [];
$constantArrays = [];
$commonTypes = [];
foreach ($this->types as $type) {
if (!$type instanceof ConstantArrayType) {
$commonTypes[] = $type;
continue;
}
$constantArrays[] = $type;
foreach ($type->getKeyTypes() as $i => $keyType) {
if (!isset($arrayDescription[$keyType->getValue()])) {
$arrayDescription[$keyType->getValue()] = [
'key' => $keyType,
'value' => $type->getValueTypes()[$i],
'count' => 1,
];
continue;
}
$arrayDescription[$keyType->getValue()] = [
'key' => $keyType,
'value' => TypeCombinator::union(
$arrayDescription[$keyType->getValue()]['value'],
$type->getValueTypes()[$i]
),
'count' => $arrayDescription[$keyType->getValue()]['count'] + 1,
];
}
}
$someKeyCountIsHigherThanOne = false;
foreach ($arrayDescription as $value) {
if ($value['count'] > 1) {
$someKeyCountIsHigherThanOne = true;
break;
}
}
if (!$someKeyCountIsHigherThanOne) {
return $joinTypes(UnionTypeHelper::sortTypes(array_merge(
$commonTypes,
$constantArrays
)));
}
$constantArraysCount = count($constantArrays);
$constantArraysDescriptions = [];
foreach ($arrayDescription as $value) {
$constantArraysDescriptions[] = sprintf(
'%s%s => %s',
$value['count'] < $constantArraysCount ? '?' : '',
$value['key']->describe(VerbosityLevel::value()),
$value['value']->describe(VerbosityLevel::value())
);
}
$description = '';
if (count($commonTypes) > 0) {
$description = $joinTypes($commonTypes);
if (count($constantArraysDescriptions) > 0) {
$description .= '|';
}
}
if (count($constantArraysDescriptions) > 0) {
$description .= 'array(' . implode(', ', $constantArraysDescriptions) . ')';
}
return $description;
}
);
}
/**
* @param callable(Type $type): TrinaryLogic $canCallback
* @param callable(Type $type): bool $hasCallback
* @return bool
*/
private function hasInternal(
callable $canCallback,
callable $hasCallback
): bool
{
$typesWithCan = 0;
$typesWithHas = 0;
foreach ($this->types as $type) {
if ($canCallback($type)->no()) {
continue;
}
$typesWithCan++;
if (!$hasCallback($type)) {
continue;
}
$typesWithHas++;
}
return $typesWithCan > 0 && $typesWithHas === $typesWithCan;
}
public function canAccessProperties(): TrinaryLogic
{
return $this->unionResults(static function (Type $type): TrinaryLogic {
return $type->canAccessProperties();
});
}
public function hasProperty(string $propertyName): bool
{
return $this->hasInternal(
static function (Type $type): TrinaryLogic {
return $type->canAccessProperties();
},
static function (Type $type) use ($propertyName): bool {
return $type->hasProperty($propertyName);
}
);
}
public function getProperty(string $propertyName, ClassMemberAccessAnswerer $scope): PropertyReflection
{
foreach ($this->types as $type) {
if ($type->canAccessProperties()->no()) {
continue;
}
return $type->getProperty($propertyName, $scope);
}
throw new \PHPStan\ShouldNotHappenException();
}
public function canCallMethods(): TrinaryLogic
{
return $this->unionResults(static function (Type $type): TrinaryLogic {
return $type->canCallMethods();
});
}
public function hasMethod(string $methodName): bool
{
return $this->hasInternal(
static function (Type $type): TrinaryLogic {
return $type->canCallMethods();
},
static function (Type $type) use ($methodName): bool {
return $type->hasMethod($methodName);
}
);
}
public function getMethod(string $methodName, ClassMemberAccessAnswerer $scope): MethodReflection
{
foreach ($this->types as $type) {
if ($type->canCallMethods()->no()) {
continue;
}
return $type->getMethod($methodName, $scope);
}
throw new \PHPStan\ShouldNotHappenException();
}
public function canAccessConstants(): TrinaryLogic
{
return $this->unionResults(static function (Type $type): TrinaryLogic {
return $type->canAccessConstants();
});
}
public function hasConstant(string $constantName): bool
{
return $this->hasInternal(
static function (Type $type): TrinaryLogic {
return $type->canAccessConstants();
},
static function (Type $type) use ($constantName): bool {
return $type->hasConstant($constantName);
}
);
}
public function getConstant(string $constantName): ConstantReflection
{
foreach ($this->types as $type) {
if ($type->canAccessConstants()->no()) {
continue;
}
return $type->getConstant($constantName);
}
throw new \PHPStan\ShouldNotHappenException();
}
public function resolveStatic(string $className): Type
{
return new self(UnionTypeHelper::resolveStatic($className, $this->getTypes()));
}
public function changeBaseClass(string $className): StaticResolvableType
{
return new self(UnionTypeHelper::changeBaseClass($className, $this->getTypes()));
}
public function isIterable(): TrinaryLogic
{
return $this->unionResults(static function (Type $type): TrinaryLogic {
return $type->isIterable();
});
}
public function getIterableKeyType(): Type
{
return $this->unionTypes(static function (Type $type): Type {
return $type->getIterableKeyType();
});
}
public function getIterableValueType(): Type
{
return $this->unionTypes(static function (Type $type): Type {
return $type->getIterableValueType();
});
}
public function isOffsetAccessible(): TrinaryLogic
{
return $this->unionResults(static function (Type $type): TrinaryLogic {
return $type->isOffsetAccessible();
});
}
public function hasOffsetValueType(Type $offsetType): TrinaryLogic
{
return $this->unionResults(static function (Type $type) use ($offsetType): TrinaryLogic {
return $type->hasOffsetValueType($offsetType);
});
}
public function getOffsetValueType(Type $offsetType): Type
{
$types = [];
foreach ($this->types as $innerType) {
$valueType = $innerType->getOffsetValueType($offsetType);
if ($valueType instanceof ErrorType) {
continue;
}
$types[] = $valueType;
}
if (count($types) === 0) {
return new ErrorType();
}
return TypeCombinator::union(...$types);
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): Type
{
return $this->unionTypes(static function (Type $type) use ($offsetType, $valueType): Type {
return $type->setOffsetValueType($offsetType, $valueType);
});
}
public function isCallable(): TrinaryLogic
{
return $this->unionResults(static function (Type $type): TrinaryLogic {
return $type->isCallable();
});
}
/**
* @param \PHPStan\Reflection\ClassMemberAccessAnswerer $scope
* @return \PHPStan\Reflection\ParametersAcceptor[]
*/
public function getCallableParametersAcceptors(ClassMemberAccessAnswerer $scope): array
{
foreach ($this->types as $type) {
if ($type->isCallable()->no()) {
continue;
}
return $type->getCallableParametersAcceptors($scope);
}
throw new \PHPStan\ShouldNotHappenException();
}
public function isCloneable(): TrinaryLogic
{
return $this->unionResults(static function (Type $type): TrinaryLogic {
return $type->isCloneable();
});
}
public function toBoolean(): BooleanType
{
/** @var BooleanType $type */
$type = $this->unionTypes(static function (Type $type): BooleanType {
return $type->toBoolean();
});
return $type;
}
public function toNumber(): Type
{
$type = $this->unionTypes(static function (Type $type): Type {
return $type->toNumber();
});
return $type;
}
public function toString(): Type
{
$type = $this->unionTypes(static function (Type $type): Type {
return $type->toString();
});
return $type;
}
public function toInteger(): Type
{
$type = $this->unionTypes(static function (Type $type): Type {
return $type->toInteger();
});
return $type;
}
public function toFloat(): Type
{
$type = $this->unionTypes(static function (Type $type): Type {
return $type->toFloat();
});
return $type;
}
public function toArray(): Type
{
$type = $this->unionTypes(static function (Type $type): Type {
return $type->toArray();
});
return $type;
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self($properties['types']);
}
/**
* @param callable(Type $type): TrinaryLogic $getResult
* @return TrinaryLogic
*/
private function unionResults(callable $getResult): TrinaryLogic
{
return TrinaryLogic::extremeIdentity(...array_map($getResult, $this->types));
}
/**
* @param callable(Type $type): Type $getType
* @return Type
*/
protected function unionTypes(callable $getType): Type
{
return TypeCombinator::union(...array_map($getType, $this->types));
}
}
src/Type/UnionTypeHelper.php 0000666 00000005613 13436755504 0012104 0 ustar 00 $type) {
if (!($type instanceof StaticResolvableType)) {
continue;
}
$types[$i] = $type->resolveStatic($className);
}
return $types;
}
/**
* @param string $className
* @param \PHPStan\Type\Type[] $types
* @return \PHPStan\Type\Type[]
*/
public static function changeBaseClass(string $className, array $types): array
{
foreach ($types as $i => $type) {
if (!($type instanceof StaticResolvableType)) {
continue;
}
$types[$i] = $type->changeBaseClass($className);
}
return $types;
}
/**
* @param \PHPStan\Type\Type[] $types
* @return string[]
*/
public static function getReferencedClasses(array $types): array
{
$subTypeClasses = [];
foreach ($types as $type) {
$subTypeClasses[] = $type->getReferencedClasses();
}
return array_merge(...$subTypeClasses);
}
/**
* @param \PHPStan\Type\Type[] $types
* @return \PHPStan\Type\Type[]
*/
public static function sortTypes(array $types): array
{
usort($types, static function (Type $a, Type $b): float {
if ($a instanceof NullType) {
return 1;
} elseif ($b instanceof NullType) {
return -1;
}
if ($a instanceof AccessoryType) {
if ($b instanceof AccessoryType) {
return strcasecmp($a->describe(VerbosityLevel::value()), $b->describe(VerbosityLevel::value()));
}
return 1;
}
if ($b instanceof AccessoryType) {
return -1;
}
$aIsNullOrBool = ($a instanceof NullType || $a instanceof ConstantBooleanType);
$bIsNullOrBool = ($b instanceof NullType || $b instanceof ConstantBooleanType);
if ($aIsNullOrBool && !$bIsNullOrBool) {
return 1;
} elseif ($bIsNullOrBool && !$aIsNullOrBool) {
return -1;
}
if ($a instanceof ConstantScalarType && !$b instanceof ConstantScalarType) {
return -1;
} elseif (!$a instanceof ConstantScalarType && $b instanceof ConstantScalarType) {
return 1;
}
if (
(
$a instanceof ConstantIntegerType
|| $a instanceof ConstantFloatType
)
&& (
$b instanceof ConstantIntegerType
|| $b instanceof ConstantFloatType
)
) {
return $a->getValue() - $b->getValue();
}
if ($a instanceof ConstantStringType && $b instanceof ConstantStringType) {
return strcasecmp($a->getValue(), $b->getValue());
}
return strcasecmp($a->describe(VerbosityLevel::typeOnly()), $b->describe(VerbosityLevel::typeOnly()));
});
return $types;
}
}
src/Type/DynamicStaticMethodReturnTypeExtension.php 0000666 00000000725 13436755504 0016645 0 ustar 00 true,
'DOMNodeList' => true,
];
/** @var string */
private $className;
public function __construct(string $className)
{
$this->className = $className;
}
public function getClassName(): string
{
return $this->className;
}
public function hasProperty(string $propertyName): bool
{
$broker = Broker::getInstance();
if (!$broker->hasClass($this->className)) {
return false;
}
return $broker->getClass($this->className)->hasProperty($propertyName);
}
public function getProperty(string $propertyName, ClassMemberAccessAnswerer $scope): PropertyReflection
{
$broker = Broker::getInstance();
return $broker->getClass($this->className)->getProperty($propertyName, $scope);
}
/**
* @return string[]
*/
public function getReferencedClasses(): array
{
return [$this->className];
}
public function accepts(Type $type, bool $strictTypes): TrinaryLogic
{
if ($type instanceof StaticType) {
return $this->checkSubclassAcceptability($type->getBaseClass());
}
if ($type instanceof CompoundType) {
return CompoundTypeHelper::accepts($type, $this, $strictTypes);
}
if ($type instanceof ClosureType) {
return $this->isInstanceOf(\Closure::class);
}
if (
$this->isInstanceOf('SimpleXMLElement')->yes()
&& $type->isSuperTypeOf($this)->no()
) {
return (new UnionType([
new IntegerType(),
new FloatType(),
new StringType(),
new BooleanType(),
]))->accepts($type, $strictTypes);
}
if (!$type instanceof TypeWithClassName) {
return TrinaryLogic::createNo();
}
return $this->checkSubclassAcceptability($type->getClassName());
}
public function isSuperTypeOf(Type $type): TrinaryLogic
{
if ($type instanceof CompoundType) {
return $type->isSubTypeOf($this);
}
if ($type instanceof ObjectWithoutClassType) {
return TrinaryLogic::createMaybe();
}
if ($type instanceof ClosureType) {
return $this->isInstanceOf(\Closure::class);
}
if (!$type instanceof TypeWithClassName) {
return TrinaryLogic::createNo();
}
$thisClassName = $this->className;
$thatClassName = $type->getClassName();
if ($thatClassName === $thisClassName) {
return TrinaryLogic::createYes();
}
$broker = Broker::getInstance();
if (!$broker->hasClass($thisClassName) || !$broker->hasClass($thatClassName)) {
return TrinaryLogic::createMaybe();
}
$thisClassReflection = $broker->getClass($thisClassName);
$thatClassReflection = $broker->getClass($thatClassName);
if ($thisClassReflection->getName() === $thatClassReflection->getName()) {
return TrinaryLogic::createYes();
}
if ($thatClassReflection->isSubclassOf($thisClassName)) {
return TrinaryLogic::createYes();
}
if ($thisClassReflection->isSubclassOf($thatClassName)) {
return TrinaryLogic::createMaybe();
}
if ($thisClassReflection->isInterface() && !$thatClassReflection->getNativeReflection()->isFinal()) {
return TrinaryLogic::createMaybe();
}
if ($thatClassReflection->isInterface() && !$thisClassReflection->getNativeReflection()->isFinal()) {
return TrinaryLogic::createMaybe();
}
return TrinaryLogic::createNo();
}
public function equals(Type $type): bool
{
return $type instanceof self && $this->className === $type->className;
}
private function checkSubclassAcceptability(string $thatClass): TrinaryLogic
{
if ($this->className === $thatClass) {
return TrinaryLogic::createYes();
}
$broker = Broker::getInstance();
if (!$broker->hasClass($this->className) || !$broker->hasClass($thatClass)) {
return TrinaryLogic::createNo();
}
$thisReflection = $broker->getClass($this->className);
$thatReflection = $broker->getClass($thatClass);
if ($thisReflection->getName() === $thatReflection->getName()) {
// class alias
return TrinaryLogic::createYes();
}
if ($thisReflection->isInterface() && $thatReflection->isInterface()) {
return TrinaryLogic::createFromBoolean(
$thatReflection->getNativeReflection()->implementsInterface($this->className)
);
}
return TrinaryLogic::createFromBoolean(
$thatReflection->isSubclassOf($this->className)
);
}
public function describe(VerbosityLevel $level): string
{
return $level->handle(
function (): string {
$broker = Broker::getInstance();
if (!$broker->hasClass($this->className)) {
return $this->className;
}
return $broker->getClass($this->className)->getDisplayName();
},
function (): string {
return $this->className;
}
);
}
public function toNumber(): Type
{
if ($this->isInstanceOf('SimpleXMLElement')->yes()) {
return new UnionType([
new FloatType(),
new IntegerType(),
]);
}
return new ErrorType();
}
public function toInteger(): Type
{
if ($this->isInstanceOf('SimpleXMLElement')->yes()) {
return new IntegerType();
}
return new ErrorType();
}
public function toFloat(): Type
{
if ($this->isInstanceOf('SimpleXMLElement')->yes()) {
return new FloatType();
}
return new ErrorType();
}
public function toString(): Type
{
$broker = Broker::getInstance();
if (!$broker->hasClass($this->className)) {
return new ErrorType();
}
$classReflection = $broker->getClass($this->className);
if ($classReflection->hasNativeMethod('__toString')) {
return new StringType();
}
return new ErrorType();
}
public function toArray(): Type
{
$broker = Broker::getInstance();
if (!$broker->hasClass($this->className)) {
return new ArrayType(new MixedType(), new MixedType());
}
$classReflection = $broker->getClass($this->className);
if (
!$classReflection->getNativeReflection()->isUserDefined()
|| UniversalObjectCratesClassReflectionExtension::isUniversalObjectCrate(
$broker,
$broker->getUniversalObjectCratesClasses(),
$classReflection
)
) {
return new ArrayType(new MixedType(), new MixedType());
}
$arrayKeys = [];
$arrayValues = [];
do {
foreach ($classReflection->getNativeReflection()->getProperties() as $nativeProperty) {
if ($nativeProperty->isStatic()) {
continue;
}
$declaringClass = $broker->getClass($nativeProperty->getDeclaringClass()->getName());
$property = $declaringClass->getNativeProperty($nativeProperty->getName());
$keyName = $nativeProperty->getName();
if ($nativeProperty->isPrivate()) {
$keyName = sprintf(
"\0%s\0%s",
$declaringClass->getName(),
$keyName
);
} elseif ($nativeProperty->isProtected()) {
$keyName = sprintf(
"\0*\0%s",
$keyName
);
}
$arrayKeys[] = new ConstantStringType($keyName);
$arrayValues[] = $property->getType();
}
$classReflection = $classReflection->getParentClass();
} while ($classReflection !== false);
return new ConstantArrayType($arrayKeys, $arrayValues);
}
public function canAccessProperties(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function canCallMethods(): TrinaryLogic
{
if (strtolower($this->className) === 'stdclass') {
return TrinaryLogic::createNo();
}
return TrinaryLogic::createYes();
}
public function hasMethod(string $methodName): bool
{
$broker = Broker::getInstance();
if (!$broker->hasClass($this->className)) {
return false;
}
return $broker->getClass($this->className)->hasMethod($methodName);
}
public function getMethod(string $methodName, ClassMemberAccessAnswerer $scope): MethodReflection
{
$broker = Broker::getInstance();
return $broker->getClass($this->className)->getMethod($methodName, $scope);
}
public function canAccessConstants(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasConstant(string $constantName): bool
{
$broker = Broker::getInstance();
if (!$broker->hasClass($this->className)) {
return false;
}
return $broker->getClass($this->className)->hasConstant($constantName);
}
public function getConstant(string $constantName): ConstantReflection
{
$broker = Broker::getInstance();
return $broker->getClass($this->className)->getConstant($constantName);
}
public function isIterable(): TrinaryLogic
{
return $this->isInstanceOf(\Traversable::class);
}
public function getIterableKeyType(): Type
{
$broker = Broker::getInstance();
if (!$broker->hasClass($this->className)) {
return new ErrorType();
}
$classReflection = $broker->getClass($this->className);
if ($this->isInstanceOf(\Iterator::class)->yes()) {
return ParametersAcceptorSelector::selectSingle($classReflection->getNativeMethod('key')->getVariants())->getReturnType();
}
if ($this->isInstanceOf(\IteratorAggregate::class)->yes()) {
return RecursionGuard::run($this, static function () use ($classReflection) {
return ParametersAcceptorSelector::selectSingle(
$classReflection->getNativeMethod('getIterator')->getVariants()
)->getReturnType()->getIterableKeyType();
});
}
if ($this->isInstanceOf(\Traversable::class)->yes()) {
return new MixedType();
}
return new ErrorType();
}
public function getIterableValueType(): Type
{
$broker = Broker::getInstance();
if (!$broker->hasClass($this->className)) {
return new ErrorType();
}
$classReflection = $broker->getClass($this->className);
if ($this->isInstanceOf(\Iterator::class)->yes()) {
return ParametersAcceptorSelector::selectSingle(
$classReflection->getNativeMethod('current')->getVariants()
)->getReturnType();
}
if ($this->isInstanceOf(\IteratorAggregate::class)->yes()) {
return RecursionGuard::run($this, static function () use ($classReflection) {
return ParametersAcceptorSelector::selectSingle(
$classReflection->getNativeMethod('getIterator')->getVariants()
)->getReturnType()->getIterableValueType();
});
}
if ($this->isInstanceOf(\Traversable::class)->yes()) {
return new MixedType();
}
return new ErrorType();
}
private function isExtraOffsetAccessibleClass(): TrinaryLogic
{
$broker = Broker::getInstance();
if (!$broker->hasClass($this->className)) {
return TrinaryLogic::createMaybe();
}
$classReflection = $broker->getClass($this->className);
if (array_key_exists($classReflection->getName(), self::EXTRA_OFFSET_CLASSES)) {
return TrinaryLogic::createYes();
}
return TrinaryLogic::createNo();
}
public function isOffsetAccessible(): TrinaryLogic
{
return $this->isInstanceOf(\ArrayAccess::class)->or(
$this->isExtraOffsetAccessibleClass()
);
}
public function hasOffsetValueType(Type $offsetType): TrinaryLogic
{
$broker = Broker::getInstance();
if (!$broker->hasClass($this->className)) {
return TrinaryLogic::createNo();
}
return $this->isExtraOffsetAccessibleClass()
->or($this->isInstanceOf(\ArrayAccess::class));
}
public function getOffsetValueType(Type $offsetType): Type
{
$broker = Broker::getInstance();
if (!$broker->hasClass($this->className)) {
return new ErrorType();
}
if (!$this->isExtraOffsetAccessibleClass()->no()) {
return new MixedType();
}
if ($this->isInstanceOf(\ArrayAccess::class)->yes()) {
$classReflection = $broker->getClass($this->className);
return RecursionGuard::run($this, static function () use ($classReflection) {
return ParametersAcceptorSelector::selectSingle($classReflection->getNativeMethod('offsetGet')->getVariants())->getReturnType();
});
}
return new ErrorType();
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): Type
{
// in the future we may return intersection of $this and OffsetAccessibleType()
return $this;
}
public function isCallable(): TrinaryLogic
{
$parametersAcceptors = $this->findCallableParametersAcceptors();
if ($parametersAcceptors === null) {
return TrinaryLogic::createNo();
}
if (
count($parametersAcceptors) === 1
&& $parametersAcceptors[0] instanceof TrivialParametersAcceptor
) {
return TrinaryLogic::createMaybe();
}
return TrinaryLogic::createYes();
}
/**
* @param \PHPStan\Reflection\ClassMemberAccessAnswerer $scope
* @return \PHPStan\Reflection\ParametersAcceptor[]
*/
public function getCallableParametersAcceptors(ClassMemberAccessAnswerer $scope): array
{
if ($this->className === \Closure::class) {
return [new TrivialParametersAcceptor()];
}
$parametersAcceptors = $this->findCallableParametersAcceptors();
if ($parametersAcceptors === null) {
throw new \PHPStan\ShouldNotHappenException();
}
return $parametersAcceptors;
}
/**
* @return \PHPStan\Reflection\ParametersAcceptor[]|null
*/
private function findCallableParametersAcceptors(): ?array
{
$broker = Broker::getInstance();
if (!$broker->hasClass($this->className)) {
return [new TrivialParametersAcceptor()];
}
$classReflection = $broker->getClass($this->className);
if ($classReflection->hasNativeMethod('__invoke')) {
return $classReflection->getNativeMethod('__invoke')->getVariants();
}
if (!$classReflection->getNativeReflection()->isFinal()) {
return [new TrivialParametersAcceptor()];
}
return null;
}
public function isCloneable(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self($properties['className']);
}
public function isInstanceOf(string $className): TrinaryLogic
{
$broker = Broker::getInstance();
if (!$broker->hasClass($this->className)) {
return TrinaryLogic::createMaybe();
}
$classReflection = $broker->getClass($this->className);
if ($classReflection->isSubclassOf($className) || $classReflection->getName() === $className) {
return TrinaryLogic::createYes();
}
if ($classReflection->isInterface()) {
return TrinaryLogic::createMaybe();
}
return TrinaryLogic::createNo();
}
}
src/Type/IntegerType.php 0000666 00000003024 13436755504 0011243 0 ustar 00 generalize();
} elseif ($type instanceof UnionType) {
return TypeCombinator::union(...array_map(static function (Type $innerType): Type {
return self::generalizeType($innerType);
}, $type->getTypes()));
}
return $type;
}
/**
* @param Type $type
* @return string[]
*/
public static function getDirectClassNames(Type $type): array
{
if ($type instanceof TypeWithClassName) {
return [$type->getClassName()];
}
if ($type instanceof UnionType || $type instanceof IntersectionType) {
$classNames = [];
foreach ($type->getTypes() as $innerType) {
if (!$innerType instanceof TypeWithClassName) {
continue;
}
$classNames[] = $innerType->getClassName();
}
return $classNames;
}
return [];
}
/**
* @param Type $type
* @return \PHPStan\Type\ConstantScalarType[]
*/
public static function getConstantScalars(Type $type): array
{
return self::map(ConstantScalarType::class, $type, false);
}
/**
* @param string $typeClass
* @param Type $type
* @param bool $inspectIntersections
* @return mixed[]
*/
private static function map(
string $typeClass,
Type $type,
bool $inspectIntersections
): array
{
if ($type instanceof $typeClass) {
return [$type];
}
if ($type instanceof UnionType) {
$matchingTypes = [];
foreach ($type->getTypes() as $innerType) {
if (!$innerType instanceof $typeClass) {
return [];
}
$matchingTypes[] = $innerType;
}
return $matchingTypes;
}
if ($inspectIntersections && $type instanceof IntersectionType) {
$matchingTypes = [];
foreach ($type->getTypes() as $innerType) {
if (!$innerType instanceof $typeClass) {
continue;
}
$matchingTypes[] = $innerType;
}
return $matchingTypes;
}
return [];
}
public static function toBenevolentUnion(Type $type): Type
{
if ($type instanceof BenevolentUnionType) {
return $type;
}
if ($type instanceof UnionType) {
return new BenevolentUnionType($type->getTypes());
}
return $type;
}
public static function findThisType(Type $type): ?ThisType
{
if ($type instanceof ThisType) {
return $type;
}
if ($type instanceof UnionType || $type instanceof IntersectionType) {
foreach ($type->getTypes() as $innerType) {
$thisType = self::findThisType($innerType);
if ($thisType !== null) {
return $thisType;
}
}
}
return null;
}
/**
* @param Type $type
* @return HasPropertyType[]
*/
public static function getHasPropertyTypes(Type $type): array
{
if ($type instanceof HasPropertyType) {
return [$type];
}
if ($type instanceof UnionType || $type instanceof IntersectionType) {
$hasPropertyTypes = [];
foreach ($type->getTypes() as $innerType) {
$hasPropertyTypes = array_merge($hasPropertyTypes, self::getHasPropertyTypes($innerType));
}
return $hasPropertyTypes;
}
return [];
}
}
src/Type/DynamicMethodReturnTypeExtension.php 0000666 00000000703 13436755504 0015471 0 ustar 00 isExplicitMixed = $isExplicitMixed;
}
/**
* @return string[]
*/
public function getReferencedClasses(): array
{
return [];
}
public function accepts(Type $type, bool $strictTypes): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function isSuperTypeOf(Type $type): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function equals(Type $type): bool
{
return $type instanceof self;
}
public function isSubTypeOf(Type $otherType): TrinaryLogic
{
if ($otherType instanceof self) {
return TrinaryLogic::createYes();
}
return TrinaryLogic::createMaybe();
}
public function canAccessProperties(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasProperty(string $propertyName): bool
{
return true;
}
public function getProperty(string $propertyName, ClassMemberAccessAnswerer $scope): PropertyReflection
{
return new DummyPropertyReflection();
}
public function canCallMethods(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasMethod(string $methodName): bool
{
return true;
}
public function getMethod(string $methodName, ClassMemberAccessAnswerer $scope): MethodReflection
{
return new DummyMethodReflection($methodName);
}
public function canAccessConstants(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasConstant(string $constantName): bool
{
return true;
}
public function getConstant(string $constantName): ConstantReflection
{
return new DummyConstantReflection($constantName);
}
public function isCloneable(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function describe(VerbosityLevel $level): string
{
return 'mixed';
}
public function toNumber(): Type
{
return new UnionType([
$this->toInteger(),
$this->toFloat(),
]);
}
public function toInteger(): Type
{
return new IntegerType();
}
public function toFloat(): Type
{
return new FloatType();
}
public function toString(): Type
{
return new StringType();
}
public function toArray(): Type
{
return new ArrayType(new MixedType(), new MixedType());
}
public function isExplicitMixed(): bool
{
return $this->isExplicitMixed;
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self($properties['isExplicitMixed']);
}
}
src/Type/VoidType.php 0000666 00000003150 13436755504 0010547 0 ustar 00 isSubTypeOf($this);
}
return TrinaryLogic::createNo();
}
public function equals(Type $type): bool
{
return $type instanceof self;
}
public function describe(VerbosityLevel $level): string
{
return 'void';
}
public function toNumber(): Type
{
return new ErrorType();
}
public function toString(): Type
{
return new ErrorType();
}
public function toInteger(): Type
{
return new ErrorType();
}
public function toFloat(): Type
{
return new ErrorType();
}
public function toArray(): Type
{
return new ErrorType();
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self();
}
}
src/Type/FunctionTypeSpecifyingExtension.php 0000666 00000001075 13436755504 0015355 0 ustar 00 methodName = $methodName;
}
private function getCanonicalMethodName(): string
{
return strtolower($this->methodName);
}
public function getReferencedClasses(): array
{
return [];
}
public function accepts(Type $type, bool $strictTypes): TrinaryLogic
{
return TrinaryLogic::createFromBoolean($this->equals($type));
}
public function isSuperTypeOf(Type $type): TrinaryLogic
{
if ($type instanceof self) {
return $this->equals($type)
? TrinaryLogic::createYes()
: TrinaryLogic::createMaybe();
}
if ($type instanceof CompoundType) {
return $type->isSubTypeOf($this);
}
if (!(new ObjectWithoutClassType())->isSuperTypeOf($type)->yes()) {
return TrinaryLogic::createNo();
}
if ($type->hasMethod($this->methodName)) {
return TrinaryLogic::createYes();
}
if ($type instanceof TypeWithClassName) {
$broker = Broker::getInstance();
if ($broker->hasClass($type->getClassName())) {
$classReflection = $broker->getClass($type->getClassName());
if ($classReflection->isFinal()) {
return TrinaryLogic::createNo();
}
}
}
return TrinaryLogic::createMaybe();
}
public function isSubTypeOf(Type $otherType): TrinaryLogic
{
if (
$otherType instanceof self
|| $otherType instanceof UnionType
|| $otherType instanceof IntersectionType
) {
return $otherType->isSuperTypeOf($this);
}
if (!(new ObjectWithoutClassType())->isSuperTypeOf($otherType)->yes()) {
return TrinaryLogic::createNo();
}
if ($otherType instanceof TypeWithClassName) {
$broker = Broker::getInstance();
if ($broker->hasClass($otherType->getClassName())) {
$classReflection = $broker->getClass($otherType->getClassName());
if ($classReflection->isFinal()) {
return TrinaryLogic::createNo();
}
}
}
return TrinaryLogic::createMaybe();
}
public function equals(Type $type): bool
{
return $type instanceof self
&& $this->getCanonicalMethodName() === $type->getCanonicalMethodName();
}
public function describe(\PHPStan\Type\VerbosityLevel $level): string
{
return sprintf('hasMethod(%s)', $this->methodName);
}
public function canAccessProperties(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasProperty(string $propertyName): bool
{
return false;
}
public function getProperty(string $propertyName, ClassMemberAccessAnswerer $scope): PropertyReflection
{
throw new \PHPStan\ShouldNotHappenException();
}
public function canCallMethods(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasMethod(string $methodName): bool
{
return $this->getCanonicalMethodName() === strtolower($methodName);
}
public function getMethod(string $methodName, ClassMemberAccessAnswerer $scope): MethodReflection
{
return new DummyMethodReflection($this->methodName);
}
public function canAccessConstants(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasConstant(string $constantName): bool
{
return false;
}
public function getConstant(string $constantName): ConstantReflection
{
throw new \PHPStan\ShouldNotHappenException();
}
public function isIterable(): TrinaryLogic
{
return TrinaryLogic::createNo();
}
public function getIterableKeyType(): Type
{
return new ErrorType();
}
public function getIterableValueType(): Type
{
return new ErrorType();
}
public function isOffsetAccessible(): TrinaryLogic
{
return TrinaryLogic::createNo();
}
public function hasOffsetValueType(Type $offsetType): TrinaryLogic
{
return TrinaryLogic::createNo();
}
public function getOffsetValueType(Type $offsetType): Type
{
return new ErrorType();
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): Type
{
return new ErrorType();
}
public function isCallable(): TrinaryLogic
{
return TrinaryLogic::createFromBoolean(
$this->getCanonicalMethodName() === '__invoke'
);
}
public function getCallableParametersAcceptors(ClassMemberAccessAnswerer $scope): array
{
return [
new TrivialParametersAcceptor(),
];
}
public function isCloneable(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function toNumber(): Type
{
return new ErrorType();
}
public function toInteger(): Type
{
return new ErrorType();
}
public function toFloat(): Type
{
return new ErrorType();
}
public function toString(): Type
{
if ($this->getCanonicalMethodName() === '__tostring') {
return new StringType();
}
return new ErrorType();
}
public function toArray(): Type
{
return new ArrayType(new MixedType(), new MixedType());
}
public static function __set_state(array $properties): Type
{
return new self($properties['methodName']);
}
}
src/Type/Accessory/HasPropertyType.php 0000666 00000012450 13436755504 0014064 0 ustar 00 propertyName = $propertyName;
}
public function getPropertyName(): string
{
return $this->propertyName;
}
public function getReferencedClasses(): array
{
return [];
}
public function accepts(Type $type, bool $strictTypes): TrinaryLogic
{
return TrinaryLogic::createFromBoolean($this->equals($type));
}
public function isSuperTypeOf(Type $type): TrinaryLogic
{
if ($type instanceof self) {
return $this->equals($type)
? TrinaryLogic::createYes()
: TrinaryLogic::createMaybe();
}
if ($type instanceof CompoundType) {
return $type->isSubTypeOf($this);
}
if (!(new ObjectWithoutClassType())->isSuperTypeOf($type)->yes()) {
return TrinaryLogic::createNo();
}
if ($type->hasProperty($this->propertyName)) {
return TrinaryLogic::createYes();
}
if ($type instanceof TypeWithClassName) {
$broker = Broker::getInstance();
if ($broker->hasClass($type->getClassName())) {
$classReflection = $broker->getClass($type->getClassName());
if ($classReflection->isFinal()) {
return TrinaryLogic::createNo();
}
}
}
return TrinaryLogic::createMaybe();
}
public function isSubTypeOf(Type $otherType): TrinaryLogic
{
if (
$otherType instanceof self
|| $otherType instanceof UnionType
|| $otherType instanceof IntersectionType
) {
return $otherType->isSuperTypeOf($this);
}
if (!(new ObjectWithoutClassType())->isSuperTypeOf($otherType)->yes()) {
return TrinaryLogic::createNo();
}
if ($otherType instanceof TypeWithClassName) {
$broker = Broker::getInstance();
if ($broker->hasClass($otherType->getClassName())) {
$classReflection = $broker->getClass($otherType->getClassName());
if ($classReflection->isFinal()) {
return TrinaryLogic::createNo();
}
}
}
return TrinaryLogic::createMaybe();
}
public function equals(Type $type): bool
{
return $type instanceof self
&& $this->propertyName === $type->propertyName;
}
public function describe(\PHPStan\Type\VerbosityLevel $level): string
{
return sprintf('hasProperty(%s)', $this->propertyName);
}
public function canAccessProperties(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasProperty(string $propertyName): bool
{
return $this->propertyName === $propertyName;
}
public function getProperty(string $propertyName, ClassMemberAccessAnswerer $scope): PropertyReflection
{
return new DummyPropertyReflection();
}
public function canCallMethods(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasMethod(string $methodName): bool
{
return false;
}
public function getMethod(string $methodName, ClassMemberAccessAnswerer $scope): MethodReflection
{
throw new \PHPStan\ShouldNotHappenException();
}
public function canAccessConstants(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasConstant(string $constantName): bool
{
return false;
}
public function getConstant(string $constantName): ConstantReflection
{
throw new \PHPStan\ShouldNotHappenException();
}
public function isIterable(): TrinaryLogic
{
return TrinaryLogic::createNo();
}
public function getIterableKeyType(): Type
{
return new ErrorType();
}
public function getIterableValueType(): Type
{
return new ErrorType();
}
public function isOffsetAccessible(): TrinaryLogic
{
return TrinaryLogic::createNo();
}
public function hasOffsetValueType(Type $offsetType): TrinaryLogic
{
return TrinaryLogic::createNo();
}
public function getOffsetValueType(Type $offsetType): Type
{
return new ErrorType();
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): Type
{
return new ErrorType();
}
public function isCallable(): TrinaryLogic
{
return TrinaryLogic::createNo();
}
public function getCallableParametersAcceptors(ClassMemberAccessAnswerer $scope): array
{
throw new \PHPStan\ShouldNotHappenException();
}
public function isCloneable(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function toNumber(): Type
{
return new ErrorType();
}
public function toInteger(): Type
{
return new ErrorType();
}
public function toFloat(): Type
{
return new ErrorType();
}
public function toString(): Type
{
return new ErrorType();
}
public function toArray(): Type
{
return new ArrayType(new MixedType(), new MixedType());
}
public static function __set_state(array $properties): Type
{
return new self($properties['propertyName']);
}
}
src/Type/Accessory/HasOffsetType.php 0000666 00000006036 13436755504 0013471 0 ustar 00 offsetType = $offsetType;
}
public function getReferencedClasses(): array
{
return [];
}
public function accepts(Type $type, bool $strictTypes): TrinaryLogic
{
if ($type instanceof CompoundType) {
return CompoundTypeHelper::accepts($type, $this, $strictTypes);
}
return $type->isOffsetAccessible()
->and($type->hasOffsetValueType($this->offsetType));
}
public function isSuperTypeOf(Type $type): TrinaryLogic
{
if ($this->equals($type)) {
return TrinaryLogic::createYes();
}
return $type->isOffsetAccessible()
->and($type->hasOffsetValueType($this->offsetType));
}
public function isSubTypeOf(Type $otherType): TrinaryLogic
{
if ($otherType instanceof UnionType || $otherType instanceof IntersectionType) {
return $otherType->isSuperTypeOf($this);
}
return $otherType->isOffsetAccessible()
->and($otherType->hasOffsetValueType($this->offsetType))
->and($otherType instanceof self ? TrinaryLogic::createYes() : TrinaryLogic::createMaybe());
}
public function equals(Type $type): bool
{
return $type instanceof self
&& $this->offsetType->equals($type->offsetType);
}
public function describe(\PHPStan\Type\VerbosityLevel $level): string
{
return sprintf('hasOffset(%s)', $this->offsetType->describe($level));
}
public function isOffsetAccessible(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasOffsetValueType(Type $offsetType): TrinaryLogic
{
if ($offsetType instanceof ConstantScalarType && $offsetType->equals($this->offsetType)) {
return TrinaryLogic::createYes();
}
return TrinaryLogic::createMaybe();
}
public function getOffsetValueType(Type $offsetType): Type
{
return new MixedType();
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): Type
{
return $this;
}
public function toNumber(): Type
{
return new ErrorType();
}
public function toInteger(): Type
{
return new ErrorType();
}
public function toFloat(): Type
{
return new ErrorType();
}
public function toString(): Type
{
return new ErrorType();
}
public function toArray(): Type
{
return new MixedType();
}
public static function __set_state(array $properties): Type
{
return new self($properties['offsetType']);
}
}
src/Type/VerbosityLevel.php 0000666 00000002356 13436755504 0011771 0 ustar 00 value = $value;
}
private static function create(int $value): self
{
self::$registry[$value] = self::$registry[$value] ?? new self($value);
return self::$registry[$value];
}
public static function typeOnly(): self
{
return self::create(self::TYPE_ONLY);
}
public static function value(): self
{
return self::create(self::VALUE);
}
public static function precise(): self
{
return self::create(self::PRECISE);
}
/**
* @param callable(): string $typeOnlyCallback
* @param callable(): string $valueCallback
* @param callable(): string|null $preciseCallback
* @return string
*/
public function handle(
callable $typeOnlyCallback,
callable $valueCallback,
?callable $preciseCallback = null
): string
{
if ($this->value === self::TYPE_ONLY) {
return $typeOnlyCallback();
}
if ($this->value === self::VALUE || $preciseCallback === null) {
return $valueCallback();
}
return $preciseCallback();
}
}
src/Type/FloatType.php 0000666 00000004444 13436755504 0010722 0 ustar 00 isSubTypeOf($this);
}
return TrinaryLogic::createNo();
}
public function equals(Type $type): bool
{
return $type instanceof self;
}
public function describe(VerbosityLevel $level): string
{
return 'float';
}
public function toNumber(): Type
{
return $this;
}
public function toFloat(): Type
{
return $this;
}
public function toInteger(): Type
{
return new IntegerType();
}
public function toString(): Type
{
return new StringType();
}
public function toArray(): Type
{
return new ConstantArrayType(
[new ConstantIntegerType(0)],
[$this],
1
);
}
public function isOffsetAccessible(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasOffsetValueType(Type $offsetType): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function getOffsetValueType(Type $offsetType): Type
{
return new NullType();
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): Type
{
return new ErrorType();
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self();
}
}
src/Type/Constant/ConstantFloatType.php 0000666 00000003470 13436755504 0014223 0 ustar 00 value = $value;
}
public function getValue(): float
{
return $this->value;
}
public function describe(VerbosityLevel $level): string
{
return $level->handle(
static function (): string {
return 'float';
},
function (): string {
$formatted = (string) $this->value;
if (strpos($formatted, '.') === false) {
$formatted .= '.0';
}
return $formatted;
}
);
}
public function isSuperTypeOf(Type $type): TrinaryLogic
{
if ($type instanceof self) {
if (!$this->equals($type)) {
if ($this->describe(VerbosityLevel::value()) === $type->describe(VerbosityLevel::value())) {
return TrinaryLogic::createMaybe();
}
return TrinaryLogic::createNo();
}
return TrinaryLogic::createYes();
}
if ($type instanceof parent) {
return TrinaryLogic::createMaybe();
}
if ($type instanceof CompoundType) {
return $type->isSubTypeOf($this);
}
return TrinaryLogic::createNo();
}
public function toString(): Type
{
return new ConstantStringType((string) $this->value);
}
public function toInteger(): Type
{
return new ConstantIntegerType((int) $this->value);
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self($properties['value']);
}
}
src/Type/Constant/ConstantArrayTypeBuilder.php 0000666 00000004655 13436755504 0015551 0 ustar 00 */
private $keyTypes = [];
/** @var array */
private $valueTypes = [];
/** @var int */
private $nextAutoIndex;
/** @var bool */
private $degradeToGeneralArray = false;
/**
* @param array $keyTypes
* @param array $valueTypes
* @param int $nextAutoIndex
*/
private function __construct(
array $keyTypes,
array $valueTypes,
int $nextAutoIndex
)
{
$this->keyTypes = $keyTypes;
$this->valueTypes = $valueTypes;
$this->nextAutoIndex = $nextAutoIndex;
}
public static function createEmpty(): self
{
return new self([], [], 0);
}
public static function createFromConstantArray(ConstantArrayType $startArrayType): self
{
return new self(
$startArrayType->getKeyTypes(),
$startArrayType->getValueTypes(),
$startArrayType->getNextAutoIndex()
);
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): void
{
if ($offsetType === null) {
$offsetType = new ConstantIntegerType($this->nextAutoIndex);
} else {
$offsetType = ArrayType::castToArrayKeyType($offsetType);
}
if (
!$this->degradeToGeneralArray
&& ($offsetType instanceof ConstantIntegerType || $offsetType instanceof ConstantStringType)
) {
/** @var ConstantIntegerType|ConstantStringType $keyType */
foreach ($this->keyTypes as $i => $keyType) {
if ($keyType->getValue() === $offsetType->getValue()) {
$this->valueTypes[$i] = $valueType;
return;
}
}
$this->keyTypes[] = $offsetType;
$this->valueTypes[] = $valueType;
$this->nextAutoIndex = $offsetType instanceof ConstantIntegerType
? max($this->nextAutoIndex, $offsetType->getValue() + 1)
: $this->nextAutoIndex;
return;
}
$this->keyTypes[] = $offsetType;
$this->valueTypes[] = $valueType;
$this->degradeToGeneralArray = true;
}
public function getArray(): ArrayType
{
if (!$this->degradeToGeneralArray) {
/** @var array $keyTypes */
$keyTypes = $this->keyTypes;
return new ConstantArrayType($keyTypes, $this->valueTypes, $this->nextAutoIndex);
}
return new ArrayType(
TypeCombinator::union(...$this->keyTypes),
TypeCombinator::union(...$this->valueTypes)
);
}
}
src/Type/Constant/ConstantArrayTypeAndMethod.php 0000666 00000001627 13436755504 0016022 0 ustar 00 type = $type;
$this->method = $method;
}
public static function createConcrete(Type $type, string $method): self
{
return new self($type, $method);
}
public static function createUnknown(): self
{
return new self(null, null);
}
public function isUnknown(): bool
{
return $this->type === null;
}
public function getType(): Type
{
if ($this->type === null) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->type;
}
public function getMethod(): string
{
if ($this->method === null) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->method;
}
}
src/Type/Constant/ConstantIntegerType.php 0000666 00000002151 13436755504 0014546 0 ustar 00 value = $value;
}
public function getValue(): int
{
return $this->value;
}
public function describe(VerbosityLevel $level): string
{
return $level->handle(
static function (): string {
return 'int';
},
function (): string {
return sprintf('%s', $this->value);
}
);
}
public function toFloat(): Type
{
return new ConstantFloatType($this->value);
}
public function toString(): Type
{
return new ConstantStringType((string) $this->value);
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self($properties['value']);
}
}
src/Type/Constant/ConstantBooleanType.php 0000666 00000002337 13436755504 0014536 0 ustar 00 value = $value;
}
public function getValue(): bool
{
return $this->value;
}
public function describe(VerbosityLevel $level): string
{
return $this->value ? 'true' : 'false';
}
public function toBoolean(): BooleanType
{
return $this;
}
public function toNumber(): Type
{
return new ConstantIntegerType((int) $this->value);
}
public function toString(): Type
{
return new ConstantStringType((string) $this->value);
}
public function toInteger(): Type
{
return new ConstantIntegerType((int) $this->value);
}
public function toFloat(): Type
{
return new ConstantFloatType((float) $this->value);
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self($properties['value']);
}
}
src/Type/Constant/ConstantArrayType.php 0000666 00000026662 13436755504 0014244 0 ustar 00 */
private $keyTypes;
/** @var array */
private $valueTypes;
/** @var int */
private $nextAutoIndex;
/**
* @param array $keyTypes
* @param array $valueTypes
* @param int $nextAutoIndex
*/
public function __construct(array $keyTypes, array $valueTypes, int $nextAutoIndex = 0)
{
assert(count($keyTypes) === count($valueTypes));
parent::__construct(
count($keyTypes) > 0 ? TypeCombinator::union(...$keyTypes) : new NeverType(),
count($valueTypes) > 0 ? TypeCombinator::union(...$valueTypes) : new NeverType()
);
$this->keyTypes = $keyTypes;
$this->valueTypes = $valueTypes;
$this->nextAutoIndex = $nextAutoIndex;
}
public function getNextAutoIndex(): int
{
return $this->nextAutoIndex;
}
public function getKeyType(): Type
{
if (count($this->keyTypes) > 1) {
return new UnionType($this->keyTypes);
}
return parent::getKeyType();
}
/**
* @return array
*/
public function getKeyTypes(): array
{
return $this->keyTypes;
}
/**
* @return array
*/
public function getValueTypes(): array
{
return $this->valueTypes;
}
public function accepts(Type $type, bool $strictTypes): TrinaryLogic
{
if ($type instanceof self) {
if (count($this->keyTypes) !== count($type->keyTypes)) {
return TrinaryLogic::createNo();
}
$result = TrinaryLogic::createYes();
foreach (array_keys($this->keyTypes) as $i) {
$result = $result
->and($this->keyTypes[$i]->accepts($type->keyTypes[$i], $strictTypes))
->and($this->valueTypes[$i]->accepts($type->valueTypes[$i], $strictTypes));
}
return $result;
}
return TrinaryLogic::createNo();
}
public function isSuperTypeOf(Type $type): TrinaryLogic
{
if ($type instanceof self) {
if (count($this->keyTypes) !== count($type->keyTypes)) {
return TrinaryLogic::createNo();
}
$results = [];
foreach (array_keys($this->keyTypes) as $i) {
$results[] = $this->keyTypes[$i]->isSuperTypeOf($type->keyTypes[$i]);
$results[] = $this->valueTypes[$i]->isSuperTypeOf($type->valueTypes[$i]);
}
return TrinaryLogic::createYes()->and(...$results);
}
if ($type instanceof ArrayType) {
$result = TrinaryLogic::createMaybe();
if (count($this->keyTypes) === 0) {
return $result;
}
return $result->and(
$this->getKeyType()->isSuperTypeOf($type->getKeyType()),
$this->getItemType()->isSuperTypeOf($type->getItemType())
);
}
if ($type instanceof CompoundType) {
return $type->isSubTypeOf($this);
}
return TrinaryLogic::createNo();
}
public function equals(Type $type): bool
{
if (!$type instanceof self) {
return false;
}
if (count($this->keyTypes) !== count($type->keyTypes)) {
return false;
}
foreach ($this->keyTypes as $i => $keyType) {
$valueType = $this->valueTypes[$i];
if (!$valueType->equals($type->valueTypes[$i])) {
return false;
}
if (!$keyType->equals($type->keyTypes[$i])) {
return false;
}
}
return true;
}
public function isCallable(): TrinaryLogic
{
$typeAndMethod = $this->findTypeAndMethodName();
if ($typeAndMethod === null) {
return TrinaryLogic::createNo();
}
if ($typeAndMethod->isUnknown()) {
return TrinaryLogic::createMaybe();
}
return TrinaryLogic::createYes();
}
/**
* @param \PHPStan\Reflection\ClassMemberAccessAnswerer $scope
* @return \PHPStan\Reflection\ParametersAcceptor[]
*/
public function getCallableParametersAcceptors(ClassMemberAccessAnswerer $scope): array
{
$typeAndMethodName = $this->findTypeAndMethodName();
if ($typeAndMethodName === null) {
throw new \PHPStan\ShouldNotHappenException();
}
if ($typeAndMethodName->isUnknown()) {
return [new TrivialParametersAcceptor()];
}
$method = $typeAndMethodName->getType()
->getMethod($typeAndMethodName->getMethod(), $scope);
if (!$scope->canCallMethod($method)) {
return [new InaccessibleMethod($method)];
}
return $method->getVariants();
}
private function findTypeAndMethodName(): ?ConstantArrayTypeAndMethod
{
if (count($this->keyTypes) !== 2) {
return null;
}
if ($this->keyTypes[0]->isSuperTypeOf(new ConstantIntegerType(0))->no()) {
return null;
}
if ($this->keyTypes[1]->isSuperTypeOf(new ConstantIntegerType(1))->no()) {
return null;
}
[$classOrObject, $method] = $this->valueTypes;
if (!$method instanceof ConstantStringType) {
return ConstantArrayTypeAndMethod::createUnknown();
}
if ($classOrObject instanceof ConstantStringType) {
$broker = Broker::getInstance();
if (!$broker->hasClass($classOrObject->getValue())) {
return ConstantArrayTypeAndMethod::createUnknown();
}
$type = new ObjectType($broker->getClass($classOrObject->getValue())->getName());
} elseif ((new \PHPStan\Type\ObjectWithoutClassType())->isSuperTypeOf($classOrObject)->yes()) {
$type = $classOrObject;
} else {
return ConstantArrayTypeAndMethod::createUnknown();
}
if ($type->hasMethod($method->getValue())) {
return ConstantArrayTypeAndMethod::createConcrete($type, $method->getValue());
}
return null;
}
public function hasOffsetValueType(Type $offsetType): TrinaryLogic
{
if ($offsetType instanceof UnionType) {
$results = [];
foreach ($offsetType->getTypes() as $innerType) {
$results[] = $this->hasOffsetValueType($innerType);
}
return TrinaryLogic::extremeIdentity(...$results);
}
return $this->getKeyType()->isSuperTypeOf($offsetType);
}
public function getOffsetValueType(Type $offsetType): Type
{
$offsetType = ArrayType::castToArrayKeyType($offsetType);
$matchingValueTypes = [];
foreach ($this->keyTypes as $i => $keyType) {
if ($keyType->isSuperTypeOf($offsetType)->no()) {
continue;
}
$matchingValueTypes[] = $this->valueTypes[$i];
}
if (count($matchingValueTypes) > 0) {
$type = TypeCombinator::union(...$matchingValueTypes);
if ($type instanceof ErrorType) {
return new MixedType();
}
return $type;
}
return new ErrorType(); // undefined offset
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): Type
{
$builder = ConstantArrayTypeBuilder::createFromConstantArray($this);
$builder->setOffsetValueType($offsetType, $valueType);
return $builder->getArray();
}
public function unsetOffset(Type $offsetType): self
{
$offsetType = ArrayType::castToArrayKeyType($offsetType);
if ($offsetType instanceof ConstantIntegerType || $offsetType instanceof ConstantStringType) {
foreach ($this->keyTypes as $i => $keyType) {
if ($keyType->getValue() === $offsetType->getValue()) {
$newKeyTypes = $this->keyTypes;
unset($newKeyTypes[$i]);
$newValueTypes = $this->valueTypes;
unset($newValueTypes[$i]);
return new self(array_values($newKeyTypes), array_values($newValueTypes), $this->nextAutoIndex);
}
}
}
return $this;
}
public function removeLast(): self
{
if (count($this->keyTypes) === 0) {
return $this;
}
$keyTypes = $this->keyTypes;
$valueTypes = $this->valueTypes;
$removedKeyType = array_pop($keyTypes);
array_pop($valueTypes);
$nextAutoindex = $removedKeyType instanceof ConstantIntegerType
? $removedKeyType->getValue()
: $this->nextAutoIndex;
return new self(
$keyTypes,
$valueTypes,
$nextAutoindex
);
}
public function removeFirst(): ArrayType
{
$builder = ConstantArrayTypeBuilder::createEmpty();
foreach ($this->keyTypes as $i => $keyType) {
if ($i === 0) {
continue;
}
$valueType = $this->valueTypes[$i];
if ($keyType instanceof ConstantIntegerType) {
$keyType = null;
}
$builder->setOffsetValueType($keyType, $valueType);
}
return $builder->getArray();
}
public function getFirstValueType(): Type
{
if (count($this->valueTypes) === 0) {
return new NullType();
}
return $this->valueTypes[0];
}
public function getLastValueType(): Type
{
$length = count($this->valueTypes);
if ($length === 0) {
return new NullType();
}
return $this->valueTypes[$length - 1];
}
public function toBoolean(): BooleanType
{
return new ConstantBooleanType(count($this->keyTypes) > 0);
}
public function generalize(): Type
{
return new ArrayType(
TypeUtils::generalizeType($this->getKeyType()),
$this->getItemType()
);
}
/**
* @return static
*/
public function generalizeValues(): ArrayType
{
$valueTypes = [];
foreach ($this->valueTypes as $valueType) {
$valueTypes[] = TypeUtils::generalizeType($valueType);
}
return new self($this->keyTypes, $valueTypes, $this->nextAutoIndex);
}
/**
* @return static
*/
public function getKeysArray(): ArrayType
{
$keyTypes = [];
$valueTypes = [];
$autoIndex = 0;
foreach ($this->keyTypes as $i => $keyType) {
$keyTypes[] = new ConstantIntegerType($i);
$valueTypes[] = $keyType;
$autoIndex++;
}
return new self($keyTypes, $valueTypes, $autoIndex);
}
/**
* @return static
*/
public function getValuesArray(): ArrayType
{
$keyTypes = [];
$valueTypes = [];
$autoIndex = 0;
foreach ($this->valueTypes as $i => $valueType) {
$keyTypes[] = new ConstantIntegerType($i);
$valueTypes[] = $valueType;
$autoIndex++;
}
return new self($keyTypes, $valueTypes, $autoIndex);
}
public function count(): Type
{
return new ConstantIntegerType(count($this->getKeyTypes()));
}
public function describe(VerbosityLevel $level): string
{
$describeValue = function (bool $truncate) use ($level): string {
$items = [];
$values = [];
$exportValuesOnly = true;
foreach ($this->keyTypes as $i => $keyType) {
$valueType = $this->valueTypes[$i];
if ($keyType->getValue() !== $i) {
$exportValuesOnly = false;
}
$items[] = sprintf('%s => %s', var_export($keyType->getValue(), true), $valueType->describe($level));
$values[] = $valueType->describe($level);
}
$append = '';
if ($truncate && count($items) > self::DESCRIBE_LIMIT) {
$items = array_slice($items, 0, self::DESCRIBE_LIMIT);
$values = array_slice($values, 0, self::DESCRIBE_LIMIT);
$append = ', ...';
}
return sprintf(
'array(%s%s)',
implode(', ', $exportValuesOnly ? $values : $items),
$append
);
};
return $level->handle(
function () use ($level): string {
return parent::describe($level);
},
static function () use ($describeValue): string {
return $describeValue(true);
},
static function () use ($describeValue): string {
return $describeValue(false);
}
);
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self($properties['keyTypes'], $properties['valueTypes'], $properties['nextAutoIndex']);
}
}
src/Type/Constant/ConstantStringType.php 0000666 00000012403 13436755504 0014420 0 ustar 00 value = $value;
}
public function getValue(): string
{
return $this->value;
}
public function describe(VerbosityLevel $level): string
{
return $level->handle(
static function (): string {
return 'string';
},
function (): string {
return var_export(
\Nette\Utils\Strings::truncate($this->value, self::DESCRIBE_LIMIT),
true
);
},
function (): string {
return var_export($this->value, true);
}
);
}
public function isCallable(): TrinaryLogic
{
if ($this->value === '') {
return TrinaryLogic::createNo();
}
$broker = Broker::getInstance();
// 'my_function'
if ($broker->hasFunction(new Name($this->value), null)) {
return TrinaryLogic::createYes();
}
// 'MyClass::myStaticFunction'
$matches = \Nette\Utils\Strings::match($this->value, '#^([a-zA-Z_\\x7f-\\xff\\\\][a-zA-Z0-9_\\x7f-\\xff\\\\]*)::([a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*)\z#');
if ($matches !== null) {
if (!$broker->hasClass($matches[1])) {
return TrinaryLogic::createMaybe();
}
$classRef = $broker->getClass($matches[1]);
if ($classRef->hasMethod($matches[2])) {
return TrinaryLogic::createYes();
}
if (!$classRef->getNativeReflection()->isFinal()) {
return TrinaryLogic::createMaybe();
}
return TrinaryLogic::createNo();
}
return TrinaryLogic::createNo();
}
/**
* @param \PHPStan\Reflection\ClassMemberAccessAnswerer $scope
* @return \PHPStan\Reflection\ParametersAcceptor[]
*/
public function getCallableParametersAcceptors(ClassMemberAccessAnswerer $scope): array
{
$broker = Broker::getInstance();
// 'my_function'
$functionName = new Name($this->value);
if ($broker->hasFunction($functionName, null)) {
return $broker->getFunction($functionName, null)->getVariants();
}
// 'MyClass::myStaticFunction'
$matches = \Nette\Utils\Strings::match($this->value, '#^([a-zA-Z_\\x7f-\\xff\\\\][a-zA-Z0-9_\\x7f-\\xff\\\\]*)::([a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*)\z#');
if ($matches !== null) {
if (!$broker->hasClass($matches[1])) {
return [new TrivialParametersAcceptor()];
}
$classReflection = $broker->getClass($matches[1]);
if ($classReflection->hasMethod($matches[2])) {
$method = $classReflection->getMethod($matches[2], $scope);
if (!$scope->canCallMethod($method)) {
return [new InaccessibleMethod($method)];
}
return $method->getVariants();
}
if (!$classReflection->getNativeReflection()->isFinal()) {
return [new TrivialParametersAcceptor()];
}
}
throw new \PHPStan\ShouldNotHappenException();
}
public function toNumber(): Type
{
if (is_numeric($this->value)) {
/** @var mixed $value */
$value = $this->value;
$value = +$value;
if (is_float($value)) {
return new ConstantFloatType($value);
}
return new ConstantIntegerType($value);
}
return new ErrorType();
}
public function toInteger(): Type
{
$type = $this->toNumber();
if ($type instanceof ErrorType) {
return $type;
}
return $type->toInteger();
}
public function toFloat(): Type
{
$type = $this->toNumber();
if ($type instanceof ErrorType) {
return $type;
}
return $type->toFloat();
}
public function hasOffsetValueType(Type $offsetType): TrinaryLogic
{
if ($offsetType instanceof ConstantIntegerType) {
return TrinaryLogic::createFromBoolean(
$offsetType->getValue() < strlen($this->value)
);
}
return parent::hasOffsetValueType($offsetType);
}
public function getOffsetValueType(Type $offsetType): Type
{
if ($offsetType instanceof ConstantIntegerType) {
if ($offsetType->getValue() < strlen($this->value)) {
return new self($this->value[$offsetType->getValue()]);
}
return new ErrorType();
}
return parent::getOffsetValueType($offsetType);
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): Type
{
$valueStringType = $valueType->toString();
if ($valueStringType instanceof ErrorType) {
return new ErrorType();
}
if (
$offsetType instanceof ConstantIntegerType
&& $valueStringType instanceof ConstantStringType
) {
$value = $this->value;
$value[$offsetType->getValue()] = $valueStringType->getValue();
return new self($value);
}
return parent::setOffsetValueType($offsetType, $valueType);
}
public function append(self $otherString): self
{
return new self($this->getValue() . $otherString->getValue());
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self($properties['value']);
}
}
src/Type/Constant/ConstantScalarToBooleanTrait.php 0000666 00000000363 13436755504 0016326 0 ustar 00 value);
}
}
src/Type/CompoundTypeHelper.php 0000666 00000001171 13436755504 0012573 0 ustar 00 getTypes() as $innerType) {
if ($otherType->accepts($innerType, $strictTypes)->yes()) {
return TrinaryLogic::createYes();
}
}
return TrinaryLogic::createNo();
}
return $compoundType->isSubTypeOf($otherType);
}
}
src/Type/StringAlwaysAcceptingObjectWithToStringType.php 0000666 00000001204 13436755504 0017566 0 ustar 00 hasClass($type->getClassName())) {
return TrinaryLogic::createNo();
}
$typeClass = $broker->getClass($type->getClassName());
return TrinaryLogic::createFromBoolean(
$typeClass->hasNativeMethod('__toString')
);
}
return parent::accepts($type, $strictTypes);
}
}
src/Type/FileTypeMapper.php 0000666 00000021414 13436755504 0011675 0 ustar 00 phpParser = $phpParser;
$this->phpDocStringResolver = $phpDocStringResolver;
$this->cache = $cache;
$this->anonymousClassNameHelper = $anonymousClassNameHelper;
$this->typeNodeResolver = $typeNodeResolver;
}
public function getResolvedPhpDoc(
string $fileName,
?string $className,
?string $traitName,
string $docComment
): ResolvedPhpDocBlock
{
if ($className === null && $traitName !== null) {
throw new \PHPStan\ShouldNotHappenException();
}
$phpDocKey = $this->getPhpDocKey($className, $traitName, $docComment);
$phpDocMap = [];
if (!isset($this->inProcess[$fileName])) {
$phpDocMap = $this->getResolvedPhpDocMap($fileName);
}
if (isset($phpDocMap[$phpDocKey])) {
return $phpDocMap[$phpDocKey];
}
if (!isset($this->inProcess[$fileName][$phpDocKey])) { // wrong $fileName due to traits
return ResolvedPhpDocBlock::createEmpty();
}
if ($this->inProcess[$fileName][$phpDocKey] === false) { // PHPDoc has cyclic dependency
return ResolvedPhpDocBlock::createEmpty();
}
if (is_callable($this->inProcess[$fileName][$phpDocKey])) {
$resolveCallback = $this->inProcess[$fileName][$phpDocKey];
$this->inProcess[$fileName][$phpDocKey] = false;
$this->inProcess[$fileName][$phpDocKey] = $resolveCallback();
}
assert($this->inProcess[$fileName][$phpDocKey] instanceof ResolvedPhpDocBlock);
return $this->inProcess[$fileName][$phpDocKey];
}
/**
* @param string $fileName
* @return \PHPStan\PhpDoc\ResolvedPhpDocBlock[]
*/
private function getResolvedPhpDocMap(string $fileName): array
{
if (!isset($this->memoryCache[$fileName])) {
$modifiedTime = filemtime($fileName);
if ($modifiedTime === false) {
$modifiedTime = time();
}
$cacheKey = sprintf('%s-%d-%s', $fileName, $modifiedTime, $this->typeNodeResolver->getCacheKey());
$map = $this->cache->load($cacheKey);
if ($map === null) {
$map = $this->createResolvedPhpDocMap($fileName);
$this->cache->save($cacheKey, $map);
}
$this->memoryCache[$fileName] = $map;
}
return $this->memoryCache[$fileName];
}
/**
* @param string $fileName
* @return \PHPStan\PhpDoc\ResolvedPhpDocBlock[]
*/
private function createResolvedPhpDocMap(string $fileName): array
{
$phpDocMap = $this->createFilePhpDocMap($fileName, null, null);
try {
$this->inProcess[$fileName] = $phpDocMap;
foreach ($phpDocMap as $phpDocKey => $resolveCallback) {
$this->inProcess[$fileName][$phpDocKey] = false;
$this->inProcess[$fileName][$phpDocKey] = $data = $resolveCallback();
$phpDocMap[$phpDocKey] = $data;
}
} finally {
unset($this->inProcess[$fileName]);
}
return $phpDocMap;
}
/**
* @param string $fileName
* @param string|null $lookForTrait
* @param string|null $traitUseClass
* @return callable[]
*/
private function createFilePhpDocMap(
string $fileName,
?string $lookForTrait,
?string $traitUseClass
): array
{
/** @var callable[] $phpDocMap */
$phpDocMap = [];
/** @var string[] $classStack */
$classStack = [];
if ($lookForTrait !== null && $traitUseClass !== null) {
$classStack[] = $traitUseClass;
}
$namespace = null;
$uses = [];
$this->processNodes(
$this->phpParser->parseFile($fileName),
function (\PhpParser\Node $node) use ($fileName, $lookForTrait, &$phpDocMap, &$classStack, &$namespace, &$uses) {
if ($node instanceof Node\Stmt\ClassLike) {
if ($lookForTrait !== null) {
if (!$node instanceof Node\Stmt\Trait_) {
return false;
}
if ((string) $node->namespacedName !== $lookForTrait) {
return false;
}
} else {
if ($node->name === null) {
if (!$node instanceof Node\Stmt\Class_) {
throw new \PHPStan\ShouldNotHappenException();
}
$className = $this->anonymousClassNameHelper->getAnonymousClassName(
new Node\Expr\New_($node),
$fileName
);
} else {
$className = ltrim(sprintf('%s\\%s', $namespace, $node->name->name), '\\');
}
$classStack[] = $className;
}
} elseif ($node instanceof Node\Stmt\TraitUse) {
foreach ($node->traits as $traitName) {
$traitName = (string) $traitName;
if (!trait_exists($traitName)) {
continue;
}
$traitReflection = new \ReflectionClass($traitName);
if ($traitReflection->getFileName() === false) {
continue;
}
$className = $classStack[count($classStack) - 1] ?? null;
if ($className === null) {
throw new \PHPStan\ShouldNotHappenException();
}
$traitPhpDocMap = $this->createFilePhpDocMap(
$traitReflection->getFileName(),
$traitName,
$className
);
$phpDocMap = array_merge($phpDocMap, $traitPhpDocMap);
}
return;
} elseif ($node instanceof \PhpParser\Node\Stmt\Namespace_) {
$namespace = (string) $node->name;
return;
} elseif ($node instanceof \PhpParser\Node\Stmt\Use_ && $node->type === \PhpParser\Node\Stmt\Use_::TYPE_NORMAL) {
foreach ($node->uses as $use) {
$uses[strtolower($use->getAlias()->name)] = (string) $use->name;
}
return;
} elseif ($node instanceof \PhpParser\Node\Stmt\GroupUse) {
$prefix = (string) $node->prefix;
foreach ($node->uses as $use) {
if ($node->type !== \PhpParser\Node\Stmt\Use_::TYPE_NORMAL && $use->type !== \PhpParser\Node\Stmt\Use_::TYPE_NORMAL) {
continue;
}
$uses[strtolower($use->getAlias()->name)] = sprintf('%s\\%s', $prefix, (string) $use->name);
}
return;
} elseif (!in_array(get_class($node), [
Node\Stmt\Property::class,
Node\Stmt\ClassMethod::class,
Node\Stmt\Function_::class,
Node\Stmt\Foreach_::class,
Node\Expr\Assign::class,
Node\Expr\AssignRef::class,
Node\Stmt\Class_::class,
Node\Stmt\ClassConst::class,
], true)) {
return;
}
$phpDocString = CommentHelper::getDocComment($node);
if ($phpDocString === null) {
return;
}
$className = $classStack[count($classStack) - 1] ?? null;
$nameScope = new NameScope($namespace, $uses, $className);
$phpDocKey = $this->getPhpDocKey($className, $lookForTrait, $phpDocString);
$phpDocMap[$phpDocKey] = function () use ($phpDocString, $nameScope): ResolvedPhpDocBlock {
return $this->phpDocStringResolver->resolve($phpDocString, $nameScope);
};
},
static function (\PhpParser\Node $node) use ($lookForTrait, &$namespace, &$classStack, &$uses): void {
if ($node instanceof Node\Stmt\ClassLike && $lookForTrait === null) {
if (count($classStack) === 0) {
throw new \PHPStan\ShouldNotHappenException();
}
array_pop($classStack);
} elseif ($node instanceof \PhpParser\Node\Stmt\Namespace_) {
$namespace = null;
$uses = [];
}
}
);
return $phpDocMap;
}
/**
* @param \PhpParser\Node[]|\PhpParser\Node|scalar $node
* @param \Closure(\PhpParser\Node $node): mixed $nodeCallback
* @param \Closure(\PhpParser\Node $node): void $endNodeCallback
*/
private function processNodes($node, \Closure $nodeCallback, \Closure $endNodeCallback): void
{
if ($node instanceof Node) {
$callbackResult = $nodeCallback($node);
if ($callbackResult === false) {
return;
}
foreach ($node->getSubNodeNames() as $subNodeName) {
$subNode = $node->{$subNodeName};
$this->processNodes($subNode, $nodeCallback, $endNodeCallback);
}
$endNodeCallback($node);
} elseif (is_array($node)) {
foreach ($node as $subNode) {
$this->processNodes($subNode, $nodeCallback, $endNodeCallback);
}
}
}
private function getPhpDocKey(
?string $class,
?string $trait,
string $docComment
): string
{
$docComment = \Nette\Utils\Strings::replace($docComment, '#\s+#', ' ');
return md5(sprintf('%s-%s-%s', $class, $trait, $docComment));
}
}
src/Type/TypeCombinator.php 0000666 00000025376 13436755504 0011761 0 ustar 00 getTypes() as $unionTypeToRemove) {
$fromType = self::remove($fromType, $unionTypeToRemove);
}
return $fromType;
}
if ($fromType instanceof UnionType) {
$innerTypes = [];
foreach ($fromType->getTypes() as $innerType) {
$innerTypes[] = self::remove($innerType, $typeToRemove);
}
return self::union(...$innerTypes);
}
if ($fromType instanceof BooleanType && $fromType->isSuperTypeOf(new BooleanType())->yes()) {
if ($typeToRemove instanceof ConstantBooleanType) {
return new ConstantBooleanType(!$typeToRemove->getValue());
}
} elseif ($fromType instanceof IterableType) {
$traversableType = new ObjectType(\Traversable::class);
$arrayType = new ArrayType(new MixedType(), new MixedType());
if ($typeToRemove->isSuperTypeOf($arrayType)->yes()) {
return $traversableType;
}
if ($typeToRemove->isSuperTypeOf($traversableType)->yes()) {
return $arrayType;
}
}
if ($typeToRemove->isSuperTypeOf($fromType)->yes()) {
return new NeverType();
}
return $fromType;
}
public static function removeNull(Type $type): Type
{
return self::remove($type, new NullType());
}
public static function containsNull(Type $type): bool
{
if ($type instanceof UnionType) {
foreach ($type->getTypes() as $innerType) {
if ($innerType instanceof NullType) {
return true;
}
}
return false;
}
return $type instanceof NullType;
}
public static function union(Type ...$types): Type
{
// transform A | (B | C) to A | B | C
for ($i = 0; $i < count($types); $i++) {
if (!($types[$i] instanceof UnionType)) {
continue;
}
array_splice($types, $i, 1, $types[$i]->getTypes());
}
$typesCount = count($types);
$arrayTypes = [];
$arrayAccessoryTypes = [];
$scalarTypes = [];
$hasGenericScalarTypes = [];
for ($i = 0; $i < $typesCount; $i++) {
if ($types[$i] instanceof NeverType) {
unset($types[$i]);
continue;
}
if ($types[$i] instanceof MixedType) {
return $types[$i];
}
if ($types[$i] instanceof ConstantScalarType) {
$type = $types[$i];
$scalarTypes[get_class($type)][md5($type->describe(VerbosityLevel::precise()))] = $type;
unset($types[$i]);
continue;
}
if ($types[$i] instanceof BooleanType) {
$hasGenericScalarTypes[ConstantBooleanType::class] = true;
}
if ($types[$i] instanceof FloatType) {
$hasGenericScalarTypes[ConstantFloatType::class] = true;
}
if ($types[$i] instanceof IntegerType) {
$hasGenericScalarTypes[ConstantIntegerType::class] = true;
}
if ($types[$i] instanceof StringType) {
$hasGenericScalarTypes[ConstantStringType::class] = true;
}
if ($types[$i] instanceof IntersectionType) {
$intermediateArrayType = null;
$intermediateAccessoryTypes = [];
foreach ($types[$i]->getTypes() as $innerType) {
if ($innerType instanceof ArrayType) {
$intermediateArrayType = $innerType;
continue;
}
if ($innerType instanceof AccessoryType) {
$intermediateAccessoryTypes[] = $innerType;
continue;
}
}
if ($intermediateArrayType !== null) {
$arrayTypes[] = $intermediateArrayType;
$arrayAccessoryTypes = array_merge($arrayAccessoryTypes, $intermediateAccessoryTypes);
unset($types[$i]);
continue;
}
}
if (!$types[$i] instanceof ArrayType) {
continue;
}
$arrayTypes[] = $types[$i];
unset($types[$i]);
}
/** @var ArrayType[] $arrayTypes */
$arrayTypes = $arrayTypes;
$types = array_values(
array_merge($types, self::processArrayTypes($arrayTypes, $arrayAccessoryTypes))
);
// simplify string[] | int[] to (string|int)[]
for ($i = 0; $i < count($types); $i++) {
for ($j = $i + 1; $j < count($types); $j++) {
if ($types[$i] instanceof IterableType && $types[$j] instanceof IterableType) {
$types[$i] = new IterableType(
self::union($types[$i]->getIterableKeyType(), $types[$j]->getIterableKeyType()),
self::union($types[$i]->getIterableValueType(), $types[$j]->getIterableValueType())
);
array_splice($types, $j, 1);
continue 2;
}
}
}
// transform A | A to A
// transform A | never to A
for ($i = 0; $i < count($types); $i++) {
for ($j = $i + 1; $j < count($types); $j++) {
if (
!$types[$j] instanceof ConstantArrayType
&& $types[$j]->isSuperTypeOf($types[$i])->yes()
) {
array_splice($types, $i--, 1);
continue 2;
}
if (
!$types[$i] instanceof ConstantArrayType
&& $types[$i]->isSuperTypeOf($types[$j])->yes()
) {
array_splice($types, $j--, 1);
continue 1;
}
}
}
foreach ($scalarTypes as $classType => $scalarTypeItems) {
if (isset($hasGenericScalarTypes[$classType])) {
continue;
}
if ($classType === ConstantBooleanType::class && count($scalarTypeItems) === 2) {
$types[] = new BooleanType();
continue;
}
foreach ($scalarTypeItems as $type) {
if (count($scalarTypeItems) > self::CONSTANT_SCALAR_UNION_THRESHOLD) {
$types[] = $type->generalize();
break;
}
$types[] = $type;
}
}
if (count($types) === 0) {
return new NeverType();
} elseif (count($types) === 1) {
return $types[0];
}
return new UnionType($types);
}
/**
* @param ArrayType[] $arrayTypes
* @param AccessoryType[] $accessoryTypes
* @return Type[]
*/
private static function processArrayTypes(array $arrayTypes, array $accessoryTypes): array
{
if (count($arrayTypes) === 0) {
return [];
} elseif (count($arrayTypes) === 1) {
return [
self::intersect($arrayTypes[0], ...$accessoryTypes),
];
}
$keyTypesForGeneralArray = [];
$valueTypesForGeneralArray = [];
$generalArrayOcurred = false;
$constantKeyTypesNumbered = [];
/** @var int|float $nextConstantKeyTypeIndex */
$nextConstantKeyTypeIndex = 1;
foreach ($arrayTypes as $arrayType) {
if (!$arrayType instanceof ConstantArrayType || $generalArrayOcurred) {
$keyTypesForGeneralArray[] = $arrayType->getKeyType();
$valueTypesForGeneralArray[] = $arrayType->getItemType();
$generalArrayOcurred = true;
continue;
}
foreach ($arrayType->getKeyTypes() as $i => $keyType) {
$keyTypesForGeneralArray[] = $keyType;
$valueTypesForGeneralArray[] = $arrayType->getValueTypes()[$i];
$keyTypeValue = $keyType->getValue();
if (array_key_exists($keyTypeValue, $constantKeyTypesNumbered)) {
continue;
}
$constantKeyTypesNumbered[$keyTypeValue] = $nextConstantKeyTypeIndex;
$nextConstantKeyTypeIndex *= 2;
if (!is_int($nextConstantKeyTypeIndex)) {
$generalArrayOcurred = true;
continue;
}
}
}
$createGeneralArray = static function () use ($keyTypesForGeneralArray, $valueTypesForGeneralArray, $accessoryTypes): Type {
return TypeCombinator::intersect(new ArrayType(
self::union(...$keyTypesForGeneralArray),
self::union(...$valueTypesForGeneralArray)
), ...$accessoryTypes);
};
if ($generalArrayOcurred) {
return [
$createGeneralArray(),
];
}
/** @var ConstantArrayType[] $arrayTypes */
$arrayTypes = $arrayTypes;
/** @var int[] $constantKeyTypesNumbered */
$constantKeyTypesNumbered = $constantKeyTypesNumbered;
$constantArraysBuckets = [];
foreach ($arrayTypes as $arrayType) {
$arrayIndex = 0;
foreach ($arrayType->getKeyTypes() as $keyType) {
$arrayIndex += $constantKeyTypesNumbered[$keyType->getValue()];
}
if (!array_key_exists($arrayIndex, $constantArraysBuckets)) {
$bucket = [];
foreach ($arrayType->getKeyTypes() as $i => $keyType) {
$bucket[$keyType->getValue()] = [
'keyType' => $keyType,
'valueType' => $arrayType->getValueTypes()[$i],
];
}
$constantArraysBuckets[$arrayIndex] = $bucket;
continue;
}
$bucket = $constantArraysBuckets[$arrayIndex];
foreach ($arrayType->getKeyTypes() as $i => $keyType) {
$bucket[$keyType->getValue()]['valueType'] = self::union(
$bucket[$keyType->getValue()]['valueType'],
$arrayType->getValueTypes()[$i]
);
}
$constantArraysBuckets[$arrayIndex] = $bucket;
}
if (count($constantArraysBuckets) > self::CONSTANT_ARRAY_UNION_THRESHOLD) {
return [
$createGeneralArray(),
];
}
$resultArrays = [];
foreach ($constantArraysBuckets as $bucket) {
$builder = ConstantArrayTypeBuilder::createEmpty();
foreach ($bucket as $data) {
$builder->setOffsetValueType($data['keyType'], $data['valueType']);
}
$resultArrays[] = self::intersect($builder->getArray(), ...$accessoryTypes);
}
return $resultArrays;
}
public static function intersect(Type ...$types): Type
{
// transform A & (B | C) to (A & B) | (A & C)
foreach ($types as $i => $type) {
if ($type instanceof UnionType) {
$topLevelUnionSubTypes = [];
foreach ($type->getTypes() as $innerUnionSubType) {
$topLevelUnionSubTypes[] = self::intersect(
$innerUnionSubType,
...array_slice($types, 0, $i),
...array_slice($types, $i + 1)
);
}
return self::union(...$topLevelUnionSubTypes);
}
}
// transform A & (B & C) to A & B & C
foreach ($types as $i => &$type) {
if (!($type instanceof IntersectionType)) {
continue;
}
array_splice($types, $i, 1, $type->getTypes());
}
// transform IntegerType & ConstantIntegerType to ConstantIntegerType
// transform Child & Parent to Child
// transform Object & ~null to Object
// transform A & A to A
// transform int[] & string to never
// transform callable & int to never
// transform A & ~A to never
// transform int & string to never
for ($i = 0; $i < count($types); $i++) {
for ($j = $i + 1; $j < count($types); $j++) {
$isSuperTypeA = $types[$j]->isSuperTypeOf($types[$i]);
if ($isSuperTypeA->no()) {
return new NeverType();
} elseif ($isSuperTypeA->yes()) {
array_splice($types, $j--, 1);
continue;
}
$isSuperTypeB = $types[$i]->isSuperTypeOf($types[$j]);
if ($isSuperTypeB->maybe()) {
continue;
}
if ($isSuperTypeB->yes()) {
array_splice($types, $i--, 1);
continue 2;
}
}
}
if (count($types) === 1) {
return $types[0];
}
return new IntersectionType($types);
}
}
src/Type/ErrorType.php 0000666 00000000621 13436755504 0010737 0 ustar 00 isSubTypeOf($this);
}
return TrinaryLogic::createNo();
}
public function equals(Type $type): bool
{
return $type instanceof self;
}
public function describe(VerbosityLevel $level): string
{
return 'null';
}
public function toNumber(): Type
{
return new ConstantIntegerType(0);
}
public function toString(): Type
{
return new ConstantStringType('');
}
public function toInteger(): Type
{
return $this->toNumber();
}
public function toFloat(): Type
{
return $this->toNumber()->toFloat();
}
public function toArray(): Type
{
return new ConstantArrayType([], []);
}
public function isOffsetAccessible(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasOffsetValueType(Type $offsetType): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function getOffsetValueType(Type $offsetType): Type
{
return new NullType();
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): Type
{
$array = new ConstantArrayType([], []);
return $array->setOffsetValueType($offsetType, $valueType);
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self();
}
}
src/Type/IntersectionType.php 0000666 00000020646 13436755504 0012325 0 ustar 00 types = UnionTypeHelper::sortTypes($types);
}
/**
* @return Type[]
*/
public function getTypes(): array
{
return $this->types;
}
/**
* @return string[]
*/
public function getReferencedClasses(): array
{
return UnionTypeHelper::getReferencedClasses($this->types);
}
public function accepts(Type $otherType, bool $strictTypes): TrinaryLogic
{
foreach ($this->types as $type) {
if (!$type->accepts($otherType, $strictTypes)->yes()) {
return TrinaryLogic::createNo();
}
}
return TrinaryLogic::createYes();
}
public function isSuperTypeOf(Type $otherType): TrinaryLogic
{
$results = [];
foreach ($this->getTypes() as $innerType) {
$results[] = $innerType->isSuperTypeOf($otherType);
}
return TrinaryLogic::createYes()->and(...$results);
}
public function isSubTypeOf(Type $otherType): TrinaryLogic
{
if ($otherType instanceof self || $otherType instanceof UnionType) {
return $otherType->isSuperTypeOf($this);
}
$results = [];
foreach ($this->getTypes() as $innerType) {
$results[] = $otherType->isSuperTypeOf($innerType);
}
return TrinaryLogic::maxMin(...$results);
}
public function equals(Type $type): bool
{
if (!$type instanceof self) {
return false;
}
if (count($this->types) !== count($type->types)) {
return false;
}
foreach ($this->types as $i => $innerType) {
if (!$innerType->equals($type->types[$i])) {
return false;
}
}
return true;
}
public function describe(VerbosityLevel $level): string
{
return $level->handle(
function () use ($level): string {
$typeNames = [];
foreach ($this->types as $type) {
if ($type instanceof AccessoryType) {
continue;
}
$typeNames[] = TypeUtils::generalizeType($type)->describe($level);
}
return implode('&', $typeNames);
},
function () use ($level): string {
$typeNames = [];
foreach ($this->types as $type) {
$typeNames[] = $type->describe($level);
}
return implode('&', $typeNames);
}
);
}
public function canAccessProperties(): TrinaryLogic
{
return $this->intersectResults(static function (Type $type): TrinaryLogic {
return $type->canAccessProperties();
});
}
public function hasProperty(string $propertyName): bool
{
foreach ($this->types as $type) {
if ($type->hasProperty($propertyName)) {
return true;
}
}
return false;
}
public function getProperty(string $propertyName, ClassMemberAccessAnswerer $scope): PropertyReflection
{
foreach ($this->types as $type) {
if ($type->hasProperty($propertyName)) {
return $type->getProperty($propertyName, $scope);
}
}
throw new \PHPStan\ShouldNotHappenException();
}
public function canCallMethods(): TrinaryLogic
{
return $this->intersectResults(static function (Type $type): TrinaryLogic {
return $type->canCallMethods();
});
}
public function hasMethod(string $methodName): bool
{
foreach ($this->types as $type) {
if ($type->hasMethod($methodName)) {
return true;
}
}
return false;
}
public function getMethod(string $methodName, ClassMemberAccessAnswerer $scope): MethodReflection
{
foreach ($this->types as $type) {
if ($type->hasMethod($methodName)) {
return $type->getMethod($methodName, $scope);
}
}
throw new \PHPStan\ShouldNotHappenException();
}
public function canAccessConstants(): TrinaryLogic
{
return $this->intersectResults(static function (Type $type): TrinaryLogic {
return $type->canAccessConstants();
});
}
public function hasConstant(string $constantName): bool
{
foreach ($this->types as $type) {
if ($type->hasConstant($constantName)) {
return true;
}
}
return false;
}
public function getConstant(string $constantName): ConstantReflection
{
foreach ($this->types as $type) {
if ($type->hasConstant($constantName)) {
return $type->getConstant($constantName);
}
}
throw new \PHPStan\ShouldNotHappenException();
}
public function isIterable(): TrinaryLogic
{
return $this->intersectResults(static function (Type $type): TrinaryLogic {
return $type->isIterable();
});
}
public function getIterableKeyType(): Type
{
return $this->intersectTypes(static function (Type $type): Type {
return $type->getIterableKeyType();
});
}
public function getIterableValueType(): Type
{
return $this->intersectTypes(static function (Type $type): Type {
return $type->getIterableValueType();
});
}
public function isOffsetAccessible(): TrinaryLogic
{
return $this->intersectResults(static function (Type $type): TrinaryLogic {
return $type->isOffsetAccessible();
});
}
public function hasOffsetValueType(Type $offsetType): TrinaryLogic
{
return $this->intersectResults(static function (Type $type) use ($offsetType): TrinaryLogic {
return $type->hasOffsetValueType($offsetType);
});
}
public function getOffsetValueType(Type $offsetType): Type
{
return $this->intersectTypes(static function (Type $type) use ($offsetType): Type {
return $type->getOffsetValueType($offsetType);
});
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): Type
{
return $this->intersectTypes(static function (Type $type) use ($offsetType, $valueType): Type {
return $type->setOffsetValueType($offsetType, $valueType);
});
}
public function isCallable(): TrinaryLogic
{
return $this->intersectResults(static function (Type $type): TrinaryLogic {
return $type->isCallable();
});
}
/**
* @param \PHPStan\Reflection\ClassMemberAccessAnswerer $scope
* @return \PHPStan\Reflection\ParametersAcceptor[]
*/
public function getCallableParametersAcceptors(ClassMemberAccessAnswerer $scope): array
{
if ($this->isCallable()->no()) {
throw new \PHPStan\ShouldNotHappenException();
}
return [new TrivialParametersAcceptor()];
}
public function isCloneable(): TrinaryLogic
{
return $this->intersectResults(static function (Type $type): TrinaryLogic {
return $type->isCloneable();
});
}
public function toBoolean(): BooleanType
{
/** @var BooleanType $type */
$type = $this->intersectTypes(static function (Type $type): BooleanType {
return $type->toBoolean();
});
return $type;
}
public function toNumber(): Type
{
$type = $this->intersectTypes(static function (Type $type): Type {
return $type->toNumber();
});
return $type;
}
public function toString(): Type
{
$type = $this->intersectTypes(static function (Type $type): Type {
return $type->toString();
});
return $type;
}
public function toInteger(): Type
{
$type = $this->intersectTypes(static function (Type $type): Type {
return $type->toInteger();
});
return $type;
}
public function toFloat(): Type
{
$type = $this->intersectTypes(static function (Type $type): Type {
return $type->toFloat();
});
return $type;
}
public function toArray(): Type
{
$type = $this->intersectTypes(static function (Type $type): Type {
return $type->toArray();
});
return $type;
}
public function resolveStatic(string $className): Type
{
return new self(UnionTypeHelper::resolveStatic($className, $this->getTypes()));
}
public function changeBaseClass(string $className): StaticResolvableType
{
return new self(UnionTypeHelper::changeBaseClass($className, $this->getTypes()));
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new self($properties['types']);
}
/**
* @param callable(Type $type): TrinaryLogic $getResult
* @return TrinaryLogic
*/
private function intersectResults(callable $getResult): TrinaryLogic
{
$operands = array_map($getResult, $this->types);
return TrinaryLogic::maxMin(...$operands);
}
/**
* @param callable(Type $type): Type $getType
* @return Type
*/
private function intersectTypes(callable $getType): Type
{
$operands = array_map($getType, $this->types);
return TypeCombinator::intersect(...$operands);
}
}
src/Type/ThisType.php 0000666 00000001106 13436755504 0010554 0 ustar 00 getStaticObjectType()->describe($level));
}
public function accepts(Type $type, bool $strictTypes): TrinaryLogic
{
if ($type instanceof CompoundType) {
return CompoundTypeHelper::accepts($type, $this, $strictTypes);
}
return TrinaryLogic::createFromBoolean(
$type instanceof self
&& $type->getBaseClass() === $this->getBaseClass()
);
}
}
src/Type/Type.php 0000666 00000004337 13436755504 0007735 0 ustar 00 toInteger();
}
public function toString(): Type
{
return TypeCombinator::union(
new ConstantStringType(''),
new ConstantStringType('1')
);
}
public function toInteger(): Type
{
return TypeCombinator::union(
new ConstantIntegerType(0),
new ConstantIntegerType(1)
);
}
public function toFloat(): Type
{
return TypeCombinator::union(
new ConstantFloatType(0.0),
new ConstantFloatType(1.0)
);
}
public function toArray(): Type
{
return new ConstantArrayType(
[new ConstantIntegerType(0)],
[$this],
1
);
}
public function isOffsetAccessible(): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function hasOffsetValueType(Type $offsetType): TrinaryLogic
{
return TrinaryLogic::createYes();
}
public function getOffsetValueType(Type $offsetType): Type
{
return new NullType();
}
public function setOffsetValueType(?Type $offsetType, Type $valueType): Type
{
return new ErrorType();
}
/**
* @param mixed[] $properties
* @return Type
*/
public static function __set_state(array $properties): Type
{
return new static();
}
}
src/Type/RecursionGuard.php 0000666 00000000673 13436755504 0011747 0 ustar 00 describe(VerbosityLevel::value());
if (isset(self::$context[$key])) {
return new ErrorType();
}
try {
self::$context[$key] = true;
return $callback();
} finally {
unset(self::$context[$key]);
}
}
}
src/Analyser/NodeScopeResolver.php 0000666 00000205105 13436755504 0013246 0 ustar 00 methods(string[]) */
private $earlyTerminatingMethodCalls;
/** @var \PHPStan\Reflection\ClassReflection|null */
private $anonymousClassReflection;
/** @var bool[] filePath(string) => bool(true) */
private $analysedFiles;
/**
* @param Broker $broker
* @param Parser $parser
* @param FileTypeMapper $fileTypeMapper
* @param FileHelper $fileHelper
* @param TypeSpecifier $typeSpecifier
* @param bool $polluteScopeWithLoopInitialAssignments
* @param bool $polluteCatchScopeWithTryAssignments
* @param string[][] $earlyTerminatingMethodCalls className(string) => methods(string[])
*/
public function __construct(
Broker $broker,
Parser $parser,
FileTypeMapper $fileTypeMapper,
FileHelper $fileHelper,
TypeSpecifier $typeSpecifier,
bool $polluteScopeWithLoopInitialAssignments,
bool $polluteCatchScopeWithTryAssignments,
array $earlyTerminatingMethodCalls
)
{
$this->broker = $broker;
$this->parser = $parser;
$this->fileTypeMapper = $fileTypeMapper;
$this->fileHelper = $fileHelper;
$this->typeSpecifier = $typeSpecifier;
$this->polluteScopeWithLoopInitialAssignments = $polluteScopeWithLoopInitialAssignments;
$this->polluteCatchScopeWithTryAssignments = $polluteCatchScopeWithTryAssignments;
$this->earlyTerminatingMethodCalls = $earlyTerminatingMethodCalls;
}
/**
* @param string[] $files
*/
public function setAnalysedFiles(array $files): void
{
$this->analysedFiles = array_fill_keys($files, true);
}
/**
* @param \PhpParser\Node[] $nodes
* @param \PHPStan\Analyser\Scope $scope
* @param \Closure(\PhpParser\Node $node, Scope $scope): void $nodeCallback
* @param \PHPStan\Analyser\Scope $closureBindScope
*/
public function processNodes(
array $nodes,
Scope $scope,
\Closure $nodeCallback,
?Scope $closureBindScope = null
): void
{
$nodesCount = count($nodes);
/** @var \PhpParser\Node|string $node */
foreach ($nodes as $i => $node) {
if (!($node instanceof \PhpParser\Node)) {
continue;
}
if ($scope->getInFunctionCall() !== null && $node instanceof Arg) {
$functionCall = $scope->getInFunctionCall();
$value = $node->value;
$parametersAcceptor = $this->findParametersAcceptorInFunctionCall($functionCall, $scope);
if ($parametersAcceptor !== null) {
$parameters = $parametersAcceptor->getParameters();
$assignByReference = false;
if (isset($parameters[$i])) {
$assignByReference = $parameters[$i]->passedByReference()->createsNewVariable();
} elseif (count($parameters) > 0 && $parametersAcceptor->isVariadic()) {
$lastParameter = $parameters[count($parameters) - 1];
$assignByReference = $lastParameter->passedByReference()->createsNewVariable();
}
if ($assignByReference && $value instanceof Variable && is_string($value->name)) {
$scope = $scope->assignVariable($value->name, new MixedType(), TrinaryLogic::createYes());
}
}
}
$nodeScope = $scope;
if ($i === 0 && $closureBindScope !== null) {
$nodeScope = $closureBindScope;
}
$this->processNode($node, $nodeScope, $nodeCallback);
if ($i === $nodesCount - 1) {
break;
}
$scope = $this->lookForAssigns(
$scope,
$node,
TrinaryLogic::createYes(),
LookForAssignsSettings::default()
);
if ($node instanceof If_) {
if ($this->findEarlyTermination($node->stmts, $scope) !== null) {
$scope = $scope->filterByFalseyValue($node->cond);
$this->processNode($node->cond, $scope, function (Node $node, Scope $inScope) use (&$scope): void {
$this->specifyFetchedPropertyForInnerScope($node, $inScope, true, $scope);
});
}
} elseif ($node instanceof Node\Stmt\Declare_) {
foreach ($node->declares as $declare) {
if (
$declare->key->name === 'strict_types'
&& $declare->value instanceof Node\Scalar\LNumber
&& $declare->value->value === 1
) {
$scope = $scope->enterDeclareStrictTypes();
break;
}
}
} elseif ($node instanceof Node\Stmt\Expression) {
$scope = $scope->filterBySpecifiedTypes($this->typeSpecifier->specifyTypesInCondition(
$scope,
$node->expr,
TypeSpecifierContext::createNull()
));
}
}
}
private function specifyProperty(Scope $scope, Expr $expr): Scope
{
if (
$expr instanceof PropertyFetch
&& $expr->name instanceof Node\Identifier
) {
return $scope->filterByTruthyValue(
new FuncCall(
new Node\Name('property_exists'),
[
new Arg($expr->var),
new Arg(new Node\Scalar\String_($expr->name->name)),
]
)
);
} elseif (
$expr instanceof Expr\StaticPropertyFetch
) {
if (
$expr->class instanceof Name
) {
if ((string) $expr->class === 'static') {
return $scope->specifyFetchedStaticPropertyFromIsset($expr);
}
} elseif ($expr->name instanceof Node\VarLikeIdentifier) {
return $scope->filterByTruthyValue(
new FuncCall(
new Node\Name('property_exists'),
[
new Arg($expr->class),
new Arg(new Node\Scalar\String_($expr->name->name)),
]
)
);
}
}
return $scope;
}
private function specifyFetchedPropertyForInnerScope(Node $node, Scope $inScope, bool $inEarlyTermination, Scope &$scope): void
{
if ($inEarlyTermination === $inScope->isNegated()) {
if ($node instanceof Isset_) {
foreach ($node->vars as $var) {
$scope = $this->specifyProperty($scope, $var);
}
}
} else {
if ($node instanceof Expr\Empty_) {
$scope = $this->specifyProperty($scope, $node->expr);
}
}
}
private function lookForArrayDestructuringArray(Scope $scope, Node $node, Type $valueType): Scope
{
if ($node instanceof Array_ || $node instanceof List_) {
foreach ($node->items as $key => $item) {
/** @var \PhpParser\Node\Expr\ArrayItem|null $itemValue */
$itemValue = $item;
if ($itemValue === null) {
continue;
}
$keyType = $itemValue->key === null ? new ConstantIntegerType($key) : $scope->getType($itemValue->key);
$scope = $this->specifyItemFromArrayDestructuring($scope, $itemValue, $valueType, $keyType);
}
} elseif ($node instanceof Variable && is_string($node->name)) {
$scope = $scope->assignVariable($node->name, new MixedType(), TrinaryLogic::createYes());
} elseif ($node instanceof ArrayDimFetch && $node->var instanceof Variable && is_string($node->var->name)) {
$scope = $scope->assignVariable(
$node->var->name,
new MixedType(),
TrinaryLogic::createYes()
);
}
return $scope;
}
private function specifyItemFromArrayDestructuring(Scope $scope, ArrayItem $arrayItem, Type $valueType, Type $keyType): Scope
{
$type = $valueType->getOffsetValueType($keyType);
$itemNode = $arrayItem->value;
if ($itemNode instanceof Variable && is_string($itemNode->name)) {
$scope = $scope->assignVariable($itemNode->name, $type, TrinaryLogic::createYes());
} elseif ($itemNode instanceof ArrayDimFetch && $itemNode->var instanceof Variable && is_string($itemNode->var->name)) {
$scope = $scope->assignVariable(
$itemNode->var->name,
$type,
TrinaryLogic::createYes()
);
} else {
$scope = $this->lookForArrayDestructuringArray($scope, $itemNode, $type);
}
return $scope;
}
private function enterForeach(Scope $scope, Foreach_ $node): Scope
{
if ($node->keyVar !== null && $node->keyVar instanceof Variable && is_string($node->keyVar->name)) {
$scope = $scope->assignVariable($node->keyVar->name, new MixedType(), TrinaryLogic::createYes());
}
$comment = CommentHelper::getDocComment($node);
if ($node->valueVar instanceof Variable && is_string($node->valueVar->name)) {
$scope = $scope->enterForeach(
$node->expr,
$node->valueVar->name,
$node->keyVar !== null
&& $node->keyVar instanceof Variable
&& is_string($node->keyVar->name)
? $node->keyVar->name
: null
);
if ($comment !== null) {
$scope = $this->processVarAnnotation($scope, $node->valueVar->name, $comment, true);
}
}
if (
$node->keyVar instanceof Variable && is_string($node->keyVar->name)
&& $comment !== null
) {
$scope = $this->processVarAnnotation($scope, $node->keyVar->name, $comment, true);
}
if ($node->valueVar instanceof List_ || $node->valueVar instanceof Array_) {
$itemTypes = [];
$exprType = $scope->getType($node->expr);
$arrayTypes = TypeUtils::getArrays($exprType);
foreach ($arrayTypes as $arrayType) {
$itemTypes[] = $arrayType->getItemType();
}
$itemType = count($itemTypes) > 0 ? TypeCombinator::union(...$itemTypes) : new MixedType();
$scope = $this->lookForArrayDestructuringArray($scope, $node->valueVar, $itemType);
}
return $this->lookForAssigns($scope, $node->valueVar, TrinaryLogic::createYes(), LookForAssignsSettings::default());
}
/**
* @param \PhpParser\Node $node
* @param Scope $scope
* @param \Closure(\PhpParser\Node $node, Scope $scope): void $nodeCallback
* @param bool $stopImmediately
*/
private function processNode(\PhpParser\Node $node, Scope $scope, \Closure $nodeCallback, bool $stopImmediately = false): void
{
$nodeCallback($node, $scope);
if ($stopImmediately) {
return;
}
if (
$node instanceof \PhpParser\Node\Stmt\ClassLike
) {
if ($node instanceof Node\Stmt\Trait_) {
return;
}
if (isset($node->namespacedName)) {
$scope = $scope->enterClass($this->broker->getClass((string) $node->namespacedName));
} elseif ($this->anonymousClassReflection !== null) {
$scope = $scope->enterAnonymousClass($this->anonymousClassReflection);
} else {
throw new \PHPStan\ShouldNotHappenException();
}
} elseif ($node instanceof Node\Stmt\TraitUse) {
$this->processTraitUse($node, $scope, $nodeCallback);
} elseif ($node instanceof \PhpParser\Node\Stmt\Function_) {
$scope = $this->enterFunction($scope, $node);
} elseif ($node instanceof \PhpParser\Node\Stmt\ClassMethod) {
$scope = $this->enterClassMethod($scope, $node);
} elseif ($node instanceof \PhpParser\Node\Stmt\Namespace_) {
$scope = $scope->enterNamespace((string) $node->name);
} elseif (
$node instanceof \PhpParser\Node\Expr\StaticCall
&& $node->class instanceof \PhpParser\Node\Name
&& $node->name instanceof Node\Identifier
&& (string) $node->class === 'Closure'
&& $node->name->name === 'bind'
) {
$thisType = null;
if (isset($node->args[1])) {
$argValue = $node->args[1]->value;
if ($argValue instanceof Expr\ConstFetch && ((string) $argValue->name === 'null')) {
$thisType = null;
} else {
$thisType = $scope->getType($argValue);
}
}
$scopeClass = 'static';
if (isset($node->args[2])) {
$argValue = $node->args[2]->value;
$argValueType = $scope->getType($argValue);
$directClassNames = TypeUtils::getDirectClassNames($argValueType);
if (count($directClassNames) === 1) {
$scopeClass = $directClassNames[0];
} elseif (
$argValue instanceof Expr\ClassConstFetch
&& $argValue->name instanceof Node\Identifier
&& strtolower($argValue->name->name) === 'class'
&& $argValue->class instanceof Name
) {
$scopeClass = $scope->resolveName($argValue->class);
} elseif ($argValueType instanceof ConstantStringType) {
$scopeClass = $argValueType->getValue();
}
}
$closureBindScope = $scope->enterClosureBind($thisType, $scopeClass);
} elseif ($node instanceof Foreach_) {
$scope = $scope->exitFirstLevelStatements();
$this->processNode($node->expr, $scope, $nodeCallback);
$scope = $this->lookForAssigns($scope, $node->expr, TrinaryLogic::createYes(), LookForAssignsSettings::default());
if ($node->keyVar !== null) {
$this->processNode($node->keyVar, $scope->enterExpressionAssign($node->keyVar), $nodeCallback);
}
$this->processNode(
$node->valueVar,
$this->lookForEnterVariableAssign($scope, $node->valueVar),
$nodeCallback
);
$scope = $this->lookForAssignsInBranches($scope, [
new StatementList($scope, $node->stmts, false, function (Scope $scope) use ($node): Scope {
return $this->enterForeach($scope, $node);
}),
new StatementList($scope, []),
], LookForAssignsSettings::insideLoop());
$scope = $this->enterForeach($scope, $node);
$this->processNodes($node->stmts, $scope->enterFirstLevelStatements(), $nodeCallback);
return;
} elseif ($node instanceof For_) {
$this->processNodes($node->init, $scope, $nodeCallback);
foreach ($node->init as $initExpr) {
$scope = $this->lookForAssigns($scope, $initExpr, TrinaryLogic::createYes(), LookForAssignsSettings::insideLoop());
}
$scopeLoopMightHaveRun = $this->lookForAssignsInBranches($scope, [
new StatementList($scope, $node->cond),
new StatementList($scope, $node->stmts),
new StatementList($scope, $node->loop),
new StatementList($scope, []),
], LookForAssignsSettings::insideLoop());
$this->processNodes($node->cond, $scopeLoopMightHaveRun, $nodeCallback);
$scopeLoopDefinitelyRan = $this->lookForAssignsInBranches($scope, [
new StatementList($scope, $node->stmts, false, static function (Scope $scope) use ($node): Scope {
foreach ($node->cond as $condExpr) {
$scope = $scope->filterByTruthyValue($condExpr);
}
return $scope;
}),
], LookForAssignsSettings::insideLoop());
$this->processNodes($node->loop, $scopeLoopDefinitelyRan, $nodeCallback);
foreach ($node->cond as $condExpr) {
$scopeLoopMightHaveRun = $this->lookForAssigns($scopeLoopMightHaveRun, $condExpr, TrinaryLogic::createYes(), LookForAssignsSettings::insideLoop());
}
foreach ($node->cond as $condExpr) {
$scopeLoopMightHaveRun = $scopeLoopMightHaveRun->filterByTruthyValue($condExpr);
}
$this->processNodes($node->stmts, $scopeLoopMightHaveRun, $nodeCallback);
return;
} elseif ($node instanceof While_) {
$bodyScope = $this->lookForAssigns(
$scope,
$node->cond,
TrinaryLogic::createYes(),
LookForAssignsSettings::default()
);
$condScope = $this->lookForAssignsInBranches($scope, [
new StatementList($bodyScope, $node->stmts, false, static function (Scope $scope) use ($node): Scope {
return $scope->filterByTruthyValue($node->cond);
}),
new StatementList($scope, []),
], LookForAssignsSettings::insideLoop());
$this->processNode($node->cond, $condScope, $nodeCallback);
$bodyScope = $this->lookForAssignsInBranches($bodyScope, [
new StatementList($bodyScope, $node->stmts, false, static function (Scope $scope) use ($node): Scope {
return $scope->filterByTruthyValue($node->cond);
}),
new StatementList($bodyScope, []),
], LookForAssignsSettings::insideLoop());
$bodyScope = $this->lookForAssigns($bodyScope, $node->cond, TrinaryLogic::createYes(), LookForAssignsSettings::insideLoop());
$bodyScope = $bodyScope->filterByTruthyValue($node->cond);
$this->processNodes($node->stmts, $bodyScope, $nodeCallback);
return;
} elseif ($node instanceof Catch_) {
if (!is_string($node->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
$scope = $scope->enterCatch(
$node->types,
$node->var->name
);
} elseif ($node instanceof Array_) {
$scope = $scope->exitFirstLevelStatements();
foreach ($node->items as $item) {
if ($item === null) {
continue;
}
$this->processNode($item, $scope, $nodeCallback);
if ($item->key !== null) {
$scope = $this->lookForAssigns($scope, $item->key, TrinaryLogic::createYes(), LookForAssignsSettings::default());
}
$scope = $this->lookForAssigns($scope, $item->value, TrinaryLogic::createYes(), LookForAssignsSettings::default());
}
return;
} elseif ($node instanceof Expr\Closure) {
$this->processNodes($node->uses, $scope, $nodeCallback);
$usesByRef = [];
foreach ($node->uses as $closureUse) {
if (!$closureUse->byRef) {
continue;
}
$usesByRef[] = $closureUse;
}
if (count($usesByRef) > 0) {
$closureScope = $this->lookForAssignsInBranches($scope, [
new StatementList($scope, $node->stmts),
new StatementList($scope, []),
], LookForAssignsSettings::insideClosure());
/** @var Expr\ClosureUse $closureUse */
foreach ($usesByRef as $closureUse) {
if (!is_string($closureUse->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
$variableCertainty = $closureScope->hasVariableType($closureUse->var->name);
if ($variableCertainty->no()) {
continue;
}
$scope = $scope->assignVariable(
$closureUse->var->name,
$closureScope->getVariableType($closureUse->var->name),
$variableCertainty
);
}
}
$scope = $scope->enterAnonymousFunction($node);
$this->processNodes($node->stmts, $scope, $nodeCallback);
return;
} elseif ($node instanceof If_) {
$this->processNode($node->cond, $scope->exitFirstLevelStatements(), $nodeCallback);
$scope = $this->lookForAssigns(
$scope,
$node->cond,
TrinaryLogic::createYes(),
LookForAssignsSettings::default()
);
$ifScope = $scope;
$scope = $scope->filterByTruthyValue($node->cond);
$specifyFetchedProperty = function (Node $node, Scope $inScope) use (&$scope): void {
$this->specifyFetchedPropertyForInnerScope($node, $inScope, false, $scope);
};
$this->processNode($node->cond, $scope, $specifyFetchedProperty);
$this->processNodes($node->stmts, $scope->enterFirstLevelStatements(), $nodeCallback);
if (count($node->elseifs) > 0 || $node->else !== null) {
$elseifScope = $ifScope->filterByFalseyValue($node->cond);
foreach ($node->elseifs as $elseif) {
$scope = $elseifScope;
$this->processNode($elseif, $scope, $nodeCallback, true);
$this->processNode($elseif->cond, $scope->exitFirstLevelStatements(), $nodeCallback);
$scope = $this->lookForAssigns(
$scope,
$elseif->cond,
TrinaryLogic::createYes(),
LookForAssignsSettings::default()
);
$scope = $scope->filterByTruthyValue($elseif->cond);
$this->processNode($elseif->cond, $scope, $specifyFetchedProperty);
$this->processNodes($elseif->stmts, $scope->enterFirstLevelStatements(), $nodeCallback);
$elseifScope = $this->lookForAssigns(
$elseifScope,
$elseif->cond,
TrinaryLogic::createYes(),
LookForAssignsSettings::default()
)->filterByFalseyValue($elseif->cond);
}
if ($node->else !== null) {
$this->processNode($node->else, $elseifScope, $nodeCallback);
}
}
return;
} elseif ($node instanceof Switch_) {
$scope = $scope->exitFirstLevelStatements();
$this->processNode($node->cond, $scope, $nodeCallback);
$scope = $this->lookForAssigns(
$scope,
$node->cond,
TrinaryLogic::createYes(),
LookForAssignsSettings::default()
);
$switchScope = $scope;
$switchConditionType = $scope->getType($node->cond)->toBoolean();
$switchConditionIsTrue = $switchConditionType instanceof ConstantBooleanType && $switchConditionType->getValue();
$switchConditionGetClassExpression = null;
if (
$node->cond instanceof FuncCall
&& $node->cond->name instanceof Name
&& strtolower((string) $node->cond->name) === 'get_class'
&& isset($node->cond->args[0])
) {
$switchConditionGetClassExpression = $node->cond->args[0]->value;
}
foreach ($node->cases as $caseNode) {
$this->processNode($caseNode, $scope, $nodeCallback, true);
if ($caseNode->cond !== null) {
$this->processNode($caseNode->cond, $switchScope, $nodeCallback);
$switchScope = $this->lookForAssigns(
$switchScope,
$caseNode->cond,
TrinaryLogic::createYes(),
LookForAssignsSettings::default()
);
$scope = $this->lookForAssigns(
$scope,
$caseNode->cond,
TrinaryLogic::createYes(),
LookForAssignsSettings::default()
);
$caseScope = $switchScope;
if ($switchConditionIsTrue) {
$caseScope = $caseScope->filterByTruthyValue($caseNode->cond);
} elseif (
$switchConditionGetClassExpression !== null
&& $caseNode->cond instanceof Expr\ClassConstFetch
&& $caseNode->cond->class instanceof Name
&& $caseNode->cond->name instanceof Node\Identifier
&& strtolower($caseNode->cond->name->name) === 'class'
) {
$caseScope = $caseScope->specifyExpressionType(
$switchConditionGetClassExpression,
new ObjectType($scope->resolveName($caseNode->cond->class))
);
}
} else {
$caseScope = $switchScope;
}
$this->processNodes(
$caseNode->stmts,
$caseScope->enterFirstLevelStatements(),
$nodeCallback
);
if ($this->findEarlyTermination($caseNode->stmts, $switchScope) === null) {
foreach ($caseNode->stmts as $statement) {
$switchScope = $this->lookForAssigns($switchScope, $statement, TrinaryLogic::createMaybe(), LookForAssignsSettings::default());
}
} else {
$switchScope = $scope;
}
}
return;
} elseif ($node instanceof TryCatch) {
$statements = [];
$this->processNodes($node->stmts, $scope->enterFirstLevelStatements(), $nodeCallback);
$scopeForLookForAssignsInBranches = $scope;
$tryAssignmentsCertainty = $this->polluteCatchScopeWithTryAssignments ? TrinaryLogic::createYes() : TrinaryLogic::createMaybe();
foreach ($node->stmts as $statement) {
$scope = $this->lookForAssigns($scope, $statement, $tryAssignmentsCertainty, LookForAssignsSettings::default());
}
if ($node->finally !== null) {
$statements[] = new StatementList($scopeForLookForAssignsInBranches, $node->stmts);
$statements[] = new StatementList($scopeForLookForAssignsInBranches, []);
}
foreach ($node->catches as $catch) {
$this->processNode($catch, $scope, $nodeCallback);
if ($node->finally === null) {
continue;
}
if (!is_string($catch->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
$statements[] = new StatementList($scope->enterCatch(
$catch->types,
$catch->var->name
), $catch->stmts);
}
if ($node->finally !== null) {
$finallyScope = $this->lookForAssignsInBranches($scopeForLookForAssignsInBranches, $statements, LookForAssignsSettings::insideFinally());
$this->processNode($node->finally, $finallyScope, $nodeCallback);
}
return;
} elseif ($node instanceof FuncCall) {
$scope = $scope->enterFunctionCall($node);
} elseif ($node instanceof Expr\StaticCall) {
$scope = $scope->enterFunctionCall($node);
} elseif ($node instanceof MethodCall) {
if (
$node->var instanceof Expr\Closure
&& $node->name instanceof Node\Identifier
&& $node->name->name === 'call'
&& isset($node->args[0])
) {
$closureCallScope = $scope->enterClosureCall($scope->getType($node->args[0]->value));
}
$scope = $scope->enterFunctionCall($node);
} elseif ($node instanceof New_ && $node->class instanceof Class_) {
$this->anonymousClassReflection = $this->broker->getAnonymousClassReflection($node, $scope);
} elseif ($node instanceof BooleanNot) {
$scope = $scope->enterNegation();
} elseif ($node instanceof Unset_ || $node instanceof Isset_) {
foreach ($node->vars as $unsetVar) {
while (
$unsetVar instanceof ArrayDimFetch
|| $unsetVar instanceof PropertyFetch
|| (
$unsetVar instanceof StaticPropertyFetch
&& $unsetVar->class instanceof Expr
)
) {
$scope = $scope->enterExpressionAssign($unsetVar);
if ($unsetVar instanceof StaticPropertyFetch) {
/** @var Expr $unsetVar */
$unsetVar = $unsetVar->class;
} else {
$unsetVar = $unsetVar->var;
}
}
$scope = $scope->enterExpressionAssign($unsetVar);
}
} elseif ($node instanceof Node\Stmt\Global_) {
foreach ($node->vars as $var) {
$scope = $scope->enterExpressionAssign($var);
}
}
$originalScope = $scope;
foreach ($node->getSubNodeNames() as $subNodeName) {
$scope = $originalScope;
$subNode = $node->{$subNodeName};
if (is_array($subNode)) {
$argClosureBindScope = null;
if (isset($closureBindScope) && $subNodeName === 'args') {
$argClosureBindScope = $closureBindScope;
}
if ($subNodeName === 'stmts') {
$scope = $scope->enterFirstLevelStatements();
} else {
$scope = $scope->exitFirstLevelStatements();
}
if ($node instanceof Isset_ && $subNodeName === 'vars') {
foreach ($node->vars as $issetVar) {
$scope = $this->specifyProperty($scope, $issetVar);
$scope = $this->ensureNonNullability($scope, $issetVar, true);
}
}
if ($node instanceof MethodCall && $subNodeName === 'args') {
$scope = $this->lookForAssigns($scope, $node->var, TrinaryLogic::createYes(), LookForAssignsSettings::default());
}
if ($node instanceof Do_ && $subNodeName === 'stmts') {
$scope = $this->lookForAssignsInBranches($scope, [
new StatementList($scope, $node->stmts),
new StatementList($scope, [$node->cond], true),
new StatementList($scope, []),
], LookForAssignsSettings::insideLoop());
}
$this->processNodes($subNode, $scope, $nodeCallback, $argClosureBindScope);
} elseif ($subNode instanceof \PhpParser\Node) {
if ($node instanceof Coalesce && $subNodeName === 'left') {
$scope = $this->ensureNonNullability($scope, $subNode, false);
$scope = $this->lookForEnterVariableAssign($scope, $node->left);
}
if (
($node instanceof BooleanAnd || $node instanceof BinaryOp\LogicalAnd)
&& $subNodeName === 'right') {
$scope = $scope->filterByTruthyValue($node->left);
}
if (
($node instanceof BooleanOr || $node instanceof BinaryOp\LogicalOr)
&& $subNodeName === 'right') {
$scope = $scope->filterByFalseyValue($node->left);
}
if ($node instanceof Assign || $node instanceof AssignRef) {
if ($subNodeName === 'var') {
$scope = $this->lookForEnterVariableAssign($scope, $node->var);
} elseif ($subNodeName === 'expr') {
$scope = $this->lookForEnterVariableAssign($scope, $node);
}
}
if ($node instanceof BinaryOp && $subNodeName === 'right') {
$scope = $this->lookForAssigns($scope, $node->left, TrinaryLogic::createYes(), LookForAssignsSettings::default());
}
if ($node instanceof Expr\Empty_ && $subNodeName === 'expr') {
$scope = $this->specifyProperty($scope, $node->expr);
$scope = $this->lookForEnterVariableAssign($scope, $node->expr);
}
if (
$node instanceof ArrayItem
&& $subNodeName === 'value'
&& $node->key !== null
) {
$scope = $this->lookForAssigns($scope, $node->key, TrinaryLogic::createYes(), LookForAssignsSettings::default());
}
if (
$node instanceof Ternary
&& $subNodeName !== 'cond'
) {
$scope = $this->lookForAssigns($scope, $node->cond, TrinaryLogic::createYes(), LookForAssignsSettings::default());
if ($subNodeName === 'if') {
$scope = $scope->filterByTruthyValue($node->cond);
$this->processNode($node->cond, $scope, function (Node $node, Scope $inScope) use (&$scope): void {
$this->specifyFetchedPropertyForInnerScope($node, $inScope, false, $scope);
});
} elseif ($subNodeName === 'else') {
$scope = $scope->filterByFalseyValue($node->cond);
$this->processNode($node->cond, $scope, function (Node $node, Scope $inScope) use (&$scope): void {
$this->specifyFetchedPropertyForInnerScope($node, $inScope, true, $scope);
});
}
}
if ($node instanceof Do_ && $subNodeName === 'cond') {
foreach ($node->stmts as $statement) {
$scope = $this->lookForAssigns($scope, $statement, TrinaryLogic::createYes(), LookForAssignsSettings::default());
}
}
if ($node instanceof Expr\Empty_ && $subNodeName === 'expr') {
$scope = $this->ensureNonNullability($scope, $subNode, true);
}
if ($node instanceof StaticVar && $subNodeName === 'var') {
$scope = $scope->enterExpressionAssign($node->var);
} elseif ($node instanceof Expr\ClosureUse && $subNodeName === 'var') {
$scope = $scope->enterExpressionAssign($node->var);
}
$nodeScope = $scope;
if (!$node instanceof ErrorSuppress && !$node instanceof Node\Stmt\Expression) {
$nodeScope = $nodeScope->exitFirstLevelStatements();
}
if ($scope->isInFirstLevelStatement()) {
if ($node instanceof Ternary && $subNodeName !== 'cond') {
$nodeScope = $scope->enterFirstLevelStatements();
} elseif (
($node instanceof BooleanAnd || $node instanceof BinaryOp\BooleanOr)
&& $subNodeName === 'right'
) {
$nodeScope = $scope->enterFirstLevelStatements();
}
}
if ($node instanceof MethodCall && $subNodeName === 'var' && isset($closureCallScope)) {
$nodeScope = $closureCallScope->exitFirstLevelStatements();
}
$this->processNode($subNode, $nodeScope, $nodeCallback);
}
}
}
private function ensureNonNullability(
Scope $scope,
Node $node,
bool $findMethods
): Scope
{
$nodeToSpecify = $node;
while (
$nodeToSpecify instanceof PropertyFetch
|| $nodeToSpecify instanceof StaticPropertyFetch
|| (
$findMethods && (
$nodeToSpecify instanceof MethodCall
|| $nodeToSpecify instanceof StaticCall
)
)
) {
if (
$nodeToSpecify instanceof PropertyFetch
|| $nodeToSpecify instanceof MethodCall
) {
$nodeToSpecify = $nodeToSpecify->var;
} elseif ($nodeToSpecify->class instanceof Expr) {
$nodeToSpecify = $nodeToSpecify->class;
} else {
break;
}
$scope = $scope->specifyExpressionType(
$nodeToSpecify,
TypeCombinator::removeNull($scope->getType($nodeToSpecify))
);
}
return $scope;
}
private function lookForEnterVariableAssign(Scope $scope, Expr $node): Scope
{
if ($node instanceof Variable) {
$scope = $scope->enterExpressionAssign($node);
} elseif ($node instanceof ArrayDimFetch) {
while ($node instanceof ArrayDimFetch) {
$scope = $scope->enterExpressionAssign($node);
$node = $node->var;
}
if ($node instanceof Variable) {
$scope = $scope->enterExpressionAssign($node);
}
} elseif ($node instanceof List_ || $node instanceof Array_) {
foreach ($node->items as $listItem) {
if ($listItem === null) {
continue;
}
$scope = $this->lookForEnterVariableAssign($scope, $listItem->value);
}
} elseif ($node instanceof AssignRef) {
$scope = $scope->enterExpressionAssign($node->expr);
} elseif ($node instanceof Assign && $node->expr instanceof Expr\Closure) {
foreach ($node->expr->uses as $closureUse) {
if (
!$closureUse->byRef
|| !$node->var instanceof Variable
|| !is_string($closureUse->var->name)
|| $node->var->name !== $closureUse->var->name
) {
continue;
}
$scope = $scope->enterExpressionAssign(new Variable($closureUse->var->name));
}
} else {
$scope = $scope->enterExpressionAssign($node);
}
return $scope;
}
private function lookForAssigns(
Scope $scope,
\PhpParser\Node $node,
TrinaryLogic $certainty,
LookForAssignsSettings $lookForAssignsSettings
): Scope
{
if ($node instanceof Node\Stmt\Expression) {
$node = $node->expr;
}
if ($node instanceof StaticVar) {
if (!is_string($node->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
$scope = $scope->assignVariable(
$node->var->name,
new MixedType(),
$certainty
);
} elseif ($node instanceof Static_) {
foreach ($node->vars as $var) {
$scope = $this->lookForAssigns($scope, $var, $certainty, $lookForAssignsSettings);
}
} elseif ($node instanceof If_) {
$conditionType = $scope->getType($node->cond)->toBoolean();
$scope = $this->lookForAssigns($scope, $node->cond, $certainty, $lookForAssignsSettings);
$statements = [];
if (!$conditionType instanceof ConstantBooleanType || $conditionType->getValue() || !$lookForAssignsSettings->skipDeadBranches()) {
$statements[] = new StatementList(
$scope,
array_merge([$node->cond], $node->stmts),
false,
static function (Scope $scope) use ($node): Scope {
return $scope->filterByTruthyValue($node->cond);
}
);
}
if (!$conditionType instanceof ConstantBooleanType || !$conditionType->getValue() || !$lookForAssignsSettings->skipDeadBranches()) {
$lastElseIfConditionIsTrue = false;
$elseIfScope = $scope;
$lastCond = $node->cond;
foreach ($node->elseifs as $elseIf) {
$elseIfScope = $elseIfScope->filterByFalseyValue($lastCond);
$lastCond = $elseIf->cond;
$elseIfConditionType = $elseIfScope->getType($elseIf->cond)->toBoolean();
if (
$elseIfConditionType instanceof ConstantBooleanType
&& !$elseIfConditionType->getValue()
&& $lookForAssignsSettings->skipDeadBranches()
) {
break;
}
$statements[] = new StatementList(
$elseIfScope,
array_merge([$elseIf->cond], $elseIf->stmts),
false,
static function (Scope $scope) use ($elseIf): Scope {
return $scope->filterByTruthyValue($elseIf->cond);
}
);
if (
$elseIfConditionType instanceof ConstantBooleanType
&& $elseIfConditionType->getValue()
&& $lookForAssignsSettings->skipDeadBranches()
) {
$lastElseIfConditionIsTrue = true;
break;
}
}
if (!$lastElseIfConditionIsTrue) {
$statements[] = new StatementList(
$elseIfScope,
$node->else !== null ? $node->else->stmts : [],
false,
static function (Scope $scope) use ($lastCond): Scope {
return $scope->filterByFalseyValue($lastCond);
}
);
}
}
$scope = $this->lookForAssignsInBranches($scope, $statements, $lookForAssignsSettings);
} elseif ($node instanceof TryCatch) {
$statements = [
new StatementList($scope, $node->stmts),
];
foreach ($node->catches as $catch) {
if (!is_string($catch->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
$statements[] = new StatementList($scope->enterCatch(
$catch->types,
$catch->var->name
), array_merge([new Node\Stmt\Nop()], $catch->stmts));
}
$scope = $this->lookForAssignsInBranches($scope, $statements, $lookForAssignsSettings);
if ($node->finally !== null) {
foreach ($node->finally->stmts as $statement) {
$scope = $this->lookForAssigns($scope, $statement, $certainty, $lookForAssignsSettings);
}
}
} elseif ($node instanceof MethodCall || $node instanceof FuncCall || $node instanceof Expr\StaticCall) {
if ($node instanceof MethodCall) {
$scope = $this->lookForAssigns($scope, $node->var, $certainty, $lookForAssignsSettings);
}
foreach ($node->args as $argument) {
$scope = $this->lookForAssigns($scope, $argument, $certainty, $lookForAssignsSettings);
}
$parametersAcceptor = $this->findParametersAcceptorInFunctionCall($node, $scope);
if ($parametersAcceptor !== null) {
$parameters = $parametersAcceptor->getParameters();
foreach ($node->args as $i => $arg) {
$assignByReference = false;
if (isset($parameters[$i])) {
$assignByReference = $parameters[$i]->passedByReference()->createsNewVariable();
} elseif (count($parameters) > 0 && $parametersAcceptor->isVariadic()) {
$lastParameter = $parameters[count($parameters) - 1];
$assignByReference = $lastParameter->passedByReference()->createsNewVariable();
}
if (!$assignByReference) {
continue;
}
$arg = $node->args[$i]->value;
if (!($arg instanceof Variable) || !is_string($arg->name)) {
continue;
}
$scope = $scope->assignVariable($arg->name, new MixedType(), $certainty);
}
}
if (
$node instanceof FuncCall
&& $node->name instanceof Name
&& in_array((string) $node->name, [
'fopen',
'file_get_contents',
], true)
) {
$scope = $scope->assignVariable('http_response_header', new ArrayType(new IntegerType(), new StringType()), $certainty);
}
if (
$node instanceof FuncCall
&& $node->name instanceof Name
&& in_array(strtolower((string) $node->name), [
'array_push',
'array_unshift',
], true)
&& count($node->args) >= 2
) {
$argumentTypes = [];
foreach (array_slice($node->args, 1) as $callArg) {
$callArgType = $scope->getType($callArg->value);
if ($callArg->unpack) {
$iterableValueType = $callArgType->getIterableValueType();
if ($iterableValueType instanceof UnionType) {
foreach ($iterableValueType->getTypes() as $innerType) {
$argumentTypes[] = $innerType;
}
} else {
$argumentTypes[] = $iterableValueType;
}
continue;
}
$argumentTypes[] = $callArgType;
}
$arrayArg = $node->args[0]->value;
$originalArrayType = $scope->getType($arrayArg);
$functionName = strtolower((string) $node->name);
$constantArrays = TypeUtils::getConstantArrays($originalArrayType);
if (
$functionName === 'array_push'
|| ($originalArrayType instanceof ArrayType && count($constantArrays) === 0)
) {
$arrayType = $originalArrayType;
foreach ($argumentTypes as $argType) {
$arrayType = $arrayType->setOffsetValueType(null, $argType);
}
$scope = $scope->specifyExpressionType($arrayArg, $arrayType);
} elseif (count($constantArrays) > 0) {
$defaultArrayBuilder = ConstantArrayTypeBuilder::createEmpty();
foreach ($argumentTypes as $argType) {
$defaultArrayBuilder->setOffsetValueType(null, $argType);
}
$defaultArrayType = $defaultArrayBuilder->getArray();
$arrayTypes = [];
foreach ($constantArrays as $constantArray) {
$arrayType = $defaultArrayType;
foreach ($constantArray->getKeyTypes() as $i => $keyType) {
$valueType = $constantArray->getValueTypes()[$i];
if ($keyType instanceof ConstantIntegerType) {
$keyType = null;
}
$arrayType = $arrayType->setOffsetValueType($keyType, $valueType);
}
$arrayTypes[] = $arrayType;
}
$scope = $scope->specifyExpressionType(
$arrayArg,
TypeCombinator::union(...$arrayTypes)
);
}
}
if (
$node instanceof FuncCall
&& $node->name instanceof Name
&& in_array(strtolower((string) $node->name), [
'array_pop',
'array_shift',
], true)
&& count($node->args) >= 1
) {
$arrayArg = $node->args[0]->value;
$constantArrays = TypeUtils::getConstantArrays($scope->getType($arrayArg));
$functionName = strtolower((string) $node->name);
if (count($constantArrays) > 0) {
$resultArrayTypes = [];
foreach ($constantArrays as $constantArray) {
if ($functionName === 'array_pop') {
$resultArrayTypes[] = $constantArray->removeLast();
} else {
$resultArrayTypes[] = $constantArray->removeFirst();
}
}
$scope = $scope->specifyExpressionType(
$arrayArg,
TypeCombinator::union(...$resultArrayTypes)
);
}
}
} elseif ($node instanceof BinaryOp) {
$scope = $this->lookForAssigns($scope, $node->left, $certainty, $lookForAssignsSettings);
$scope = $this->lookForAssigns($scope, $node->right, $certainty, $lookForAssignsSettings);
} elseif ($node instanceof Arg) {
$scope = $this->lookForAssigns($scope, $node->value, $certainty, $lookForAssignsSettings);
} elseif ($node instanceof BooleanNot) {
$scope = $this->lookForAssigns($scope, $node->expr, $certainty, $lookForAssignsSettings);
} elseif ($node instanceof Ternary) {
$scope = $this->lookForAssigns($scope, $node->cond, $certainty, $lookForAssignsSettings);
$statements = [];
if ($node->if !== null) {
$statements[] = new StatementList(
$scope->filterByTruthyValue($node->cond),
[$node->if]
);
} else {
$statements[] = new StatementList(
$scope->filterByTruthyValue($node->cond),
[$node->cond]
);
}
$statements[] = new StatementList(
$scope->filterByFalseyValue($node->cond),
[$node->else]
);
$scope = $this->lookForAssignsInBranches($scope, $statements, $lookForAssignsSettings);
} elseif ($node instanceof Array_) {
foreach ($node->items as $item) {
if ($item === null) {
continue;
}
if ($item->key !== null) {
$scope = $this->lookForAssigns($scope, $item->key, $certainty, $lookForAssignsSettings);
}
$scope = $this->lookForAssigns($scope, $item->value, $certainty, $lookForAssignsSettings);
}
} elseif ($node instanceof New_) {
foreach ($node->args as $arg) {
$scope = $this->lookForAssigns($scope, $arg, $certainty, $lookForAssignsSettings);
}
} elseif ($node instanceof Do_) {
$scope = $this->lookForAssignsInBranches($scope, [
new StatementList($scope, $node->stmts),
], LookForAssignsSettings::afterLoop());
$scope = $this->lookForAssigns($scope, $node->cond, TrinaryLogic::createYes(), LookForAssignsSettings::afterLoop());
$scope = $scope->filterByFalseyValue($node->cond);
} elseif ($node instanceof Switch_) {
$scope = $this->lookForAssigns(
$scope,
$node->cond,
TrinaryLogic::createYes(),
LookForAssignsSettings::default()
);
$statementLists = [];
$tmpStatements = [];
$hasDefault = false;
foreach ($node->cases as $case) {
if ($case->cond === null) {
$hasDefault = true;
}
foreach ($case->stmts as $statement) {
$tmpStatements[] = $statement;
if ($this->findStatementEarlyTermination($statement, $scope) !== null) {
$statementLists[] = new StatementList($scope, $tmpStatements);
$tmpStatements = [];
break;
}
}
}
if (count($tmpStatements) > 0) {
$statementLists[] = new StatementList($scope, $tmpStatements);
}
if (!$hasDefault) {
$statementLists[] = new StatementList($scope, []);
}
$scope = $this->lookForAssignsInBranches($scope, $statementLists, LookForAssignsSettings::afterSwitch());
} elseif ($node instanceof Cast) {
$scope = $this->lookForAssigns($scope, $node->expr, $certainty, $lookForAssignsSettings);
} elseif ($node instanceof For_) {
$forAssignmentsCertainty = $this->polluteScopeWithLoopInitialAssignments ? TrinaryLogic::createYes() : TrinaryLogic::createMaybe();
foreach ($node->init as $initExpr) {
$scope = $this->lookForAssigns($scope, $initExpr, $forAssignmentsCertainty, LookForAssignsSettings::afterLoop());
}
foreach ($node->cond as $condExpr) {
$scope = $this->lookForAssigns($scope, $condExpr, $forAssignmentsCertainty, LookForAssignsSettings::afterLoop());
}
$statements = [
new StatementList($scope, $node->stmts),
new StatementList($scope, []), // in order not to add variables existing only inside the for loop
];
$scope = $this->lookForAssignsInBranches($scope, $statements, LookForAssignsSettings::afterLoop());
foreach ($node->loop as $loopExpr) {
$scope = $this->lookForAssigns($scope, $loopExpr, TrinaryLogic::createMaybe(), LookForAssignsSettings::afterLoop());
}
} elseif ($node instanceof While_) {
$whileAssignmentsCertainty = $this->polluteScopeWithLoopInitialAssignments ? TrinaryLogic::createYes() : TrinaryLogic::createMaybe();
$scope = $this->lookForAssigns($scope, $node->cond, $whileAssignmentsCertainty, LookForAssignsSettings::afterLoop());
$statements = [
new StatementList($scope, $node->stmts, false, static function (Scope $scope) use ($node): Scope {
return $scope->filterByTruthyValue($node->cond);
}),
new StatementList($scope, []), // in order not to add variables existing only inside the for loop
];
$scope = $this->lookForAssignsInBranches($scope, $statements, LookForAssignsSettings::afterLoop());
} elseif ($node instanceof ErrorSuppress) {
$scope = $this->lookForAssigns($scope, $node->expr, $certainty, $lookForAssignsSettings);
} elseif ($node instanceof \PhpParser\Node\Stmt\Unset_) {
foreach ($node->vars as $var) {
$scope = $scope->unsetExpression($var);
}
} elseif ($node instanceof Echo_) {
foreach ($node->exprs as $echoedExpr) {
$scope = $this->lookForAssigns($scope, $echoedExpr, $certainty, $lookForAssignsSettings);
}
} elseif ($node instanceof Print_) {
$scope = $this->lookForAssigns($scope, $node->expr, $certainty, $lookForAssignsSettings);
} elseif ($node instanceof Foreach_) {
$scope = $this->lookForAssigns($scope, $node->expr, $certainty, $lookForAssignsSettings);
$statements = [
new StatementList($scope, array_merge(
[new Node\Stmt\Nop()],
$node->stmts
), false, function (Scope $scope) use ($node): Scope {
return $this->enterForeach($scope, $node);
}),
new StatementList($scope, []), // in order not to add variables existing only inside the for loop
];
$scope = $this->lookForAssignsInBranches($scope, $statements, LookForAssignsSettings::afterLoop());
} elseif ($node instanceof Isset_) {
foreach ($node->vars as $var) {
$scope = $this->lookForAssigns($scope, $var, $certainty, $lookForAssignsSettings);
}
} elseif ($node instanceof Expr\Empty_) {
$scope = $this->lookForAssigns($scope, $node->expr, $certainty, $lookForAssignsSettings);
} elseif ($node instanceof ArrayDimFetch && $node->dim !== null) {
$scope = $this->lookForAssigns($scope, $node->dim, $certainty, $lookForAssignsSettings);
} elseif ($node instanceof Expr\Closure) {
$closureScope = $scope->enterAnonymousFunction($node);
$statements = [
new StatementList($closureScope, array_merge(
[new Node\Stmt\Nop()],
$node->stmts
)),
new StatementList($closureScope, []),
];
$closureScope = $this->lookForAssignsInBranches($scope, $statements, LookForAssignsSettings::insideClosure());
foreach ($node->uses as $closureUse) {
if (!$closureUse->byRef) {
continue;
}
if (!is_string($closureUse->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
$variableCertainty = $closureScope->hasVariableType($closureUse->var->name);
if ($variableCertainty->no()) {
continue;
}
$scope = $scope->assignVariable(
$closureUse->var->name,
$closureScope->getVariableType($closureUse->var->name),
$variableCertainty
);
}
} elseif ($node instanceof Instanceof_) {
$scope = $this->lookForAssigns($scope, $node->expr, $certainty, $lookForAssignsSettings);
} elseif ($node instanceof Expr\Include_) {
$scope = $this->lookForAssigns($scope, $node->expr, $certainty, $lookForAssignsSettings);
} elseif (
(
$node instanceof Expr\PostInc
|| $node instanceof Expr\PostDec
|| $node instanceof Expr\PreInc
|| $node instanceof Expr\PreDec
) && (
$node->var instanceof Variable
|| $node->var instanceof ArrayDimFetch
|| $node->var instanceof PropertyFetch
|| $node->var instanceof StaticPropertyFetch
)
) {
$expressionType = $scope->getType($node->var);
if ($expressionType instanceof ConstantScalarType) {
$afterValue = $expressionType->getValue();
if (
$node instanceof Expr\PostInc
|| $node instanceof Expr\PreInc
) {
$afterValue++;
} else {
$afterValue--;
}
$newExpressionType = $scope->getTypeFromValue($afterValue);
if ($lookForAssignsSettings->shouldGeneralizeConstantTypesOfNonIdempotentOperations()) {
$newExpressionType = TypeUtils::generalizeType($newExpressionType);
}
$scope = $this->assignVariable(
$scope,
$node->var,
$certainty,
$newExpressionType
);
}
} elseif ($node instanceof Expr\Yield_) {
if ($node->key !== null) {
$scope = $this->lookForAssigns($scope, $node->key, $certainty, $lookForAssignsSettings);
}
if ($node->value !== null) {
$scope = $this->lookForAssigns($scope, $node->value, $certainty, $lookForAssignsSettings);
}
} elseif ($node instanceof Expr\YieldFrom) {
$scope = $this->lookForAssigns($scope, $node->expr, $certainty, $lookForAssignsSettings);
}
$scope = $this->updateScopeForVariableAssign($scope, $node, $certainty, $lookForAssignsSettings);
return $scope;
}
private function updateScopeForVariableAssign(
Scope $scope,
\PhpParser\Node $node,
TrinaryLogic $certainty,
LookForAssignsSettings $lookForAssignsSettings
): Scope
{
if ($node instanceof Assign || $node instanceof AssignRef || $node instanceof Expr\AssignOp || $node instanceof Node\Stmt\Global_) {
if ($node instanceof Assign || $node instanceof AssignRef || $node instanceof Expr\AssignOp) {
$scope = $this->lookForAssigns($scope, $node->var, TrinaryLogic::createYes(), $lookForAssignsSettings);
$vars = [$node->var];
} else {
$vars = $node->vars;
}
foreach ($vars as $var) {
if (
!$var instanceof Variable
&& !$var instanceof ArrayDimFetch
&& !$var instanceof PropertyFetch
&& !$var instanceof StaticPropertyFetch
) {
continue;
}
$type = null;
if ($node instanceof Assign || $node instanceof AssignRef) {
$type = $scope->getType($node->expr);
} elseif ($node instanceof Expr\AssignOp) {
$type = $scope->getType($node);
if ($lookForAssignsSettings->shouldGeneralizeConstantTypesOfNonIdempotentOperations()) {
$type = TypeUtils::generalizeType($type);
}
}
$scope = $this->assignVariable($scope, $var, $certainty, $type);
if (
(!$node instanceof Assign && !$node instanceof AssignRef)
|| !$lookForAssignsSettings->shouldGeneralizeConstantTypesOfNonIdempotentOperations()
|| !($var instanceof ArrayDimFetch)
|| $var->dim !== null
) {
continue;
}
$type = $scope->getType($var->var);
$scope = $this->assignVariable($scope, $var->var, $certainty, TypeUtils::generalizeType($type));
}
if ($node instanceof Assign || $node instanceof AssignRef) {
if ($node->var instanceof Array_ || $node->var instanceof List_) {
$scope = $this->lookForArrayDestructuringArray($scope, $node->var, $scope->getType($node->expr));
}
}
if (!$node instanceof Node\Stmt\Global_) {
$scope = $this->lookForAssigns($scope, $node->expr, TrinaryLogic::createYes(), $lookForAssignsSettings);
}
if ($node instanceof Assign || $node instanceof AssignRef) {
if ($node->var instanceof Variable && is_string($node->var->name)) {
$comment = CommentHelper::getDocComment($node);
if ($comment !== null) {
$scope = $this->processVarAnnotation($scope, $node->var->name, $comment, false);
}
}
}
}
return $scope;
}
private function processVarAnnotation(Scope $scope, string $variableName, string $comment, bool $strict): Scope
{
$resolvedPhpDoc = $this->fileTypeMapper->getResolvedPhpDoc(
$scope->getFile(),
$scope->isInClass() ? $scope->getClassReflection()->getName() : null,
$scope->isInTrait() ? $scope->getTraitReflection()->getName() : null,
$comment
);
$varTags = $resolvedPhpDoc->getVarTags();
if (isset($varTags[$variableName])) {
$variableType = $varTags[$variableName]->getType();
return $scope->assignVariable($variableName, $variableType, TrinaryLogic::createYes());
}
if (!$strict && count($varTags) === 1 && isset($varTags[0])) {
$variableType = $varTags[0]->getType();
return $scope->assignVariable($variableName, $variableType, TrinaryLogic::createYes());
}
return $scope;
}
private function assignVariable(
Scope $scope,
Node $var,
TrinaryLogic $certainty,
?Type $subNodeType = null
): Scope
{
if ($var instanceof Variable && is_string($var->name)) {
$scope = $scope->assignVariable($var->name, $subNodeType ?? new MixedType(), $certainty);
} elseif ($var instanceof ArrayDimFetch) {
$subNodeType = $subNodeType ?? new MixedType();
$dimExprStack = [];
while ($var instanceof ArrayDimFetch) {
$dimExprStack[] = $var->dim;
$var = $var->var;
}
// 1. eval root expr
$scope = $this->lookForAssigns($scope, $var, TrinaryLogic::createYes(), LookForAssignsSettings::default());
// 2. eval dimensions
$offsetTypes = [];
foreach (array_reverse($dimExprStack) as $dimExpr) {
if ($dimExpr === null) {
$offsetTypes[] = null;
} else {
$scope = $this->lookForAssigns($scope, $dimExpr, TrinaryLogic::createYes(), LookForAssignsSettings::default());
$offsetTypes[] = $scope->getType($dimExpr);
}
}
// 3. eval assigned expr, unfortunately this was already done
// 4. compose types
$varType = $scope->getType($var);
if ($varType instanceof ErrorType) {
$varType = new ConstantArrayType([], []);
}
$offsetValueType = $varType;
$offsetValueTypeStack = [$offsetValueType];
foreach (array_slice($offsetTypes, 0, -1) as $offsetType) {
if ($offsetType === null) {
$offsetValueType = new ConstantArrayType([], []);
} else {
$offsetValueType = $offsetValueType->getOffsetValueType($offsetType);
if ($offsetValueType instanceof ErrorType) {
$offsetValueType = new ConstantArrayType([], []);
}
}
$offsetValueTypeStack[] = $offsetValueType;
}
$valueToWrite = $subNodeType;
foreach (array_reverse($offsetTypes) as $offsetType) {
/** @var Type $offsetValueType */
$offsetValueType = array_pop($offsetValueTypeStack);
$valueToWrite = $offsetValueType->setOffsetValueType($offsetType, $valueToWrite);
}
if ($valueToWrite instanceof ErrorType) {
$valueToWrite = new ArrayType(new MixedType(), new MixedType());
}
if ($var instanceof Variable && is_string($var->name)) {
$scope = $scope->assignVariable(
$var->name,
$valueToWrite,
$certainty
);
} else {
$scope = $scope->specifyExpressionType(
$var,
$valueToWrite
);
}
} elseif ($var instanceof PropertyFetch && $subNodeType !== null) {
$scope = $scope->specifyExpressionType($var, $subNodeType);
} elseif ($var instanceof Expr\StaticPropertyFetch && $subNodeType !== null) {
$scope = $scope->specifyExpressionType($var, $subNodeType);
} else {
$scope = $this->lookForAssigns($scope, $var, TrinaryLogic::createYes(), LookForAssignsSettings::default());
}
return $scope;
}
/**
* @param \PHPStan\Analyser\Scope $initialScope
* @param \PHPStan\Analyser\StatementList[] $statementsLists
* @param \PHPStan\Analyser\LookForAssignsSettings $lookForAssignsSettings
* @param int $counter
* @return Scope
*/
private function lookForAssignsInBranches(
Scope $initialScope,
array $statementsLists,
LookForAssignsSettings $lookForAssignsSettings,
int $counter = 0
): Scope
{
/** @var \PHPStan\Analyser\Scope|null $intersectedScope */
$intersectedScope = null;
foreach ($statementsLists as $statementList) {
$statements = $statementList->getStatements();
$branchScope = $statementList->getScope();
$branchScopeWithInitialScopeRemoved = $branchScope->removeVariables($initialScope, true);
$earlyTerminationStatement = null;
foreach ($statements as $statement) {
$branchScope = $this->lookForAssigns($branchScope, $statement, TrinaryLogic::createYes(), $lookForAssignsSettings);
$branchScopeWithInitialScopeRemoved = $branchScope->removeVariables($initialScope, false);
$earlyTerminationStatement = $this->findStatementEarlyTermination($statement, $branchScope);
if ($earlyTerminationStatement !== null) {
if ($lookForAssignsSettings->shouldSkipBranch($earlyTerminationStatement)) {
continue 2;
}
$branchScopeWithInitialScopeRemoved = $branchScopeWithInitialScopeRemoved->removeSpecified($initialScope);
break;
}
}
if (!$lookForAssignsSettings->shouldIntersectVariables($earlyTerminationStatement)) {
continue;
}
if ($intersectedScope === null) {
$intersectedScope = $initialScope->createIntersectedScope($branchScopeWithInitialScopeRemoved);
} else {
$intersectedScope = $intersectedScope->intersectVariables($branchScopeWithInitialScopeRemoved);
}
if (!$statementList->shouldFilterByTruthyValue()) {
continue;
}
/** @var \PhpParser\Node\Expr $statement */
foreach ($statements as $statement) {
$intersectedScope = $intersectedScope->filterByTruthyValue($statement);
}
}
if ($intersectedScope !== null) {
$scope = $initialScope->mergeWithIntersectedScope($intersectedScope);
if ($counter === 0 && $lookForAssignsSettings->skipDeadBranches()) {
$newStatementLists = [];
foreach ($statementsLists as $statementList) {
$newStatementLists[] = StatementList::fromList(
$scope,
$statementList
);
}
return $this->lookForAssignsInBranches(
$scope,
$newStatementLists,
$lookForAssignsSettings,
$counter + 1
);
}
return $scope;
}
return $initialScope;
}
/**
* @param \PhpParser\Node[] $statements
* @param \PHPStan\Analyser\Scope $scope
* @return \PhpParser\Node|null
*/
private function findEarlyTermination(array $statements, Scope $scope): ?\PhpParser\Node
{
foreach ($statements as $statement) {
$statement = $this->findStatementEarlyTermination($statement, $scope);
if ($statement !== null) {
return $statement;
}
}
return null;
}
private function findStatementEarlyTermination(Node $statement, Scope $scope): ?\PhpParser\Node
{
if ($statement instanceof Node\Stmt\Expression) {
$statement = $statement->expr;
}
if (
$statement instanceof Throw_
|| $statement instanceof Return_
|| $statement instanceof Continue_
|| $statement instanceof Break_
|| $statement instanceof Exit_
) {
return $statement;
} elseif (($statement instanceof MethodCall || $statement instanceof Expr\StaticCall) && count($this->earlyTerminatingMethodCalls) > 0) {
if ($statement->name instanceof Expr) {
return null;
}
if ($statement instanceof MethodCall) {
$methodCalledOnType = $scope->getType($statement->var);
} else {
if ($statement->class instanceof Name) {
$methodCalledOnType = $scope->getFunctionType($statement->class, false, false);
} else {
$methodCalledOnType = $scope->getType($statement->class);
}
}
$directClassNames = TypeUtils::getDirectClassNames($methodCalledOnType);
foreach ($directClassNames as $referencedClass) {
if (!$this->broker->hasClass($referencedClass)) {
continue;
}
$classReflection = $this->broker->getClass($referencedClass);
foreach (array_merge([$referencedClass], $classReflection->getParentClassesNames()) as $className) {
if (!isset($this->earlyTerminatingMethodCalls[$className])) {
continue;
}
if (in_array((string) $statement->name, $this->earlyTerminatingMethodCalls[$className], true)) {
return $statement;
}
}
}
return null;
} elseif ($statement instanceof If_) {
if ($statement->else === null) {
return null;
}
if ($this->findEarlyTermination($statement->stmts, $scope) === null) {
return null;
}
foreach ($statement->elseifs as $elseIfStatement) {
if ($this->findEarlyTermination($elseIfStatement->stmts, $scope) === null) {
return null;
}
}
if ($this->findEarlyTermination($statement->else->stmts, $scope) === null) {
return null;
}
return $statement;
}
return null;
}
private function findParametersAcceptorInFunctionCall(Expr $functionCall, Scope $scope): ?\PHPStan\Reflection\ParametersAcceptor
{
if ($functionCall instanceof FuncCall && $functionCall->name instanceof Name) {
if ($this->broker->hasFunction($functionCall->name, $scope)) {
return ParametersAcceptorSelector::selectFromArgs(
$scope,
$functionCall->args,
$this->broker->getFunction($functionCall->name, $scope)->getVariants()
);
}
} elseif ($functionCall instanceof MethodCall && $functionCall->name instanceof Node\Identifier) {
$type = $scope->getType($functionCall->var);
$methodName = $functionCall->name->name;
if ($type->hasMethod($methodName)) {
return ParametersAcceptorSelector::selectFromArgs(
$scope,
$functionCall->args,
$type->getMethod($methodName, $scope)->getVariants()
);
}
} elseif (
$functionCall instanceof Expr\StaticCall
&& $functionCall->class instanceof Name
&& $functionCall->name instanceof Node\Identifier
) {
$className = $scope->resolveName($functionCall->class);
if ($this->broker->hasClass($className)) {
$classReflection = $this->broker->getClass($className);
if ($classReflection->hasMethod($functionCall->name->name)) {
return ParametersAcceptorSelector::selectFromArgs(
$scope,
$functionCall->args,
$classReflection->getMethod($functionCall->name->name, $scope)->getVariants()
);
}
}
}
return null;
}
private function processTraitUse(Node\Stmt\TraitUse $node, Scope $classScope, \Closure $nodeCallback): void
{
foreach ($node->traits as $trait) {
$traitName = (string) $trait;
if (!$this->broker->hasClass($traitName)) {
continue;
}
$traitReflection = $this->broker->getClass($traitName);
$traitFileName = $traitReflection->getFileName();
if ($traitFileName === false) {
throw new \PHPStan\ShouldNotHappenException();
}
$fileName = $this->fileHelper->normalizePath($traitFileName);
if (!isset($this->analysedFiles[$fileName])) {
return;
}
$parserNodes = $this->parser->parseFile($fileName);
$classScope = $classScope->enterTrait($traitReflection);
$this->processNodesForTraitUse($parserNodes, $traitName, $classScope, $nodeCallback);
}
}
/**
* @param \PhpParser\Node[]|\PhpParser\Node|scalar $node
* @param string $traitName
* @param \PHPStan\Analyser\Scope $classScope
* @param \Closure(\PhpParser\Node $node): void $nodeCallback
*/
private function processNodesForTraitUse($node, string $traitName, Scope $classScope, \Closure $nodeCallback): void
{
if ($node instanceof Node) {
if ($node instanceof Node\Stmt\Trait_ && $traitName === (string) $node->namespacedName) {
$this->processNodes($node->stmts, $classScope->enterFirstLevelStatements(), $nodeCallback);
return;
}
if ($node instanceof Node\Stmt\ClassLike) {
return;
}
foreach ($node->getSubNodeNames() as $subNodeName) {
$subNode = $node->{$subNodeName};
$this->processNodesForTraitUse($subNode, $traitName, $classScope, $nodeCallback);
}
} elseif (is_array($node)) {
foreach ($node as $subNode) {
$this->processNodesForTraitUse($subNode, $traitName, $classScope, $nodeCallback);
}
}
}
private function enterClassMethod(Scope $scope, Node\Stmt\ClassMethod $classMethod): Scope
{
[$phpDocParameterTypes, $phpDocReturnType, $phpDocThrowType, $isDeprecated, $isInternal, $isFinal] = $this->getPhpDocs($scope, $classMethod);
return $scope->enterClassMethod(
$classMethod,
$phpDocParameterTypes,
$phpDocReturnType,
$phpDocThrowType,
$isDeprecated,
$isInternal,
$isFinal
);
}
/**
* @param Scope $scope
* @param Node\FunctionLike $functionLike
* @return mixed[]
*/
private function getPhpDocs(Scope $scope, Node\FunctionLike $functionLike): array
{
$phpDocParameterTypes = [];
$phpDocReturnType = null;
$phpDocThrowType = null;
$isDeprecated = false;
$isInternal = false;
$isFinal = false;
if ($functionLike->getDocComment() !== null) {
$docComment = $functionLike->getDocComment()->getText();
$file = $scope->getFile();
$class = $scope->isInClass() ? $scope->getClassReflection()->getName() : null;
$trait = $scope->isInTrait() ? $scope->getTraitReflection()->getName() : null;
if ($functionLike instanceof Node\Stmt\ClassMethod) {
if (!$scope->isInClass()) {
throw new \PHPStan\ShouldNotHappenException();
}
$phpDocBlock = PhpDocBlock::resolvePhpDocBlockForMethod(
$this->broker,
$docComment,
$scope->getClassReflection()->getName(),
$functionLike->name->name,
$file
);
$docComment = $phpDocBlock->getDocComment();
$file = $phpDocBlock->getFile();
$class = $phpDocBlock->getClass();
}
$resolvedPhpDoc = $this->fileTypeMapper->getResolvedPhpDoc(
$file,
$class,
$trait,
$docComment
);
$phpDocParameterTypes = array_map(static function (ParamTag $tag): Type {
return $tag->getType();
}, $resolvedPhpDoc->getParamTags());
$phpDocReturnType = $resolvedPhpDoc->getReturnTag() !== null ? $resolvedPhpDoc->getReturnTag()->getType() : null;
$phpDocThrowType = $resolvedPhpDoc->getThrowsTag() !== null ? $resolvedPhpDoc->getThrowsTag()->getType() : null;
$isDeprecated = $resolvedPhpDoc->isDeprecated();
$isInternal = $resolvedPhpDoc->isInternal();
$isFinal = $resolvedPhpDoc->isFinal();
}
return [$phpDocParameterTypes, $phpDocReturnType, $phpDocThrowType, $isDeprecated, $isInternal, $isFinal];
}
private function enterFunction(Scope $scope, Node\Stmt\Function_ $function): Scope
{
[$phpDocParameterTypes, $phpDocReturnType, $phpDocThrowType, $isDeprecated, $isInternal, $isFinal] = $this->getPhpDocs($scope, $function);
return $scope->enterFunction(
$function,
$phpDocParameterTypes,
$phpDocReturnType,
$phpDocThrowType,
$isDeprecated,
$isInternal,
$isFinal
);
}
}
src/Analyser/Analyser.php 0000666 00000012265 13436755504 0011426 0 ustar 00 scopeFactory = $scopeFactory;
$this->parser = $parser;
$this->registry = $registry;
$this->nodeScopeResolver = $nodeScopeResolver;
$this->ignoreErrors = $ignoreErrors;
$this->reportUnmatchedIgnoredErrors = $reportUnmatchedIgnoredErrors;
$this->internalErrorsCountLimit = $internalErrorsCountLimit;
}
/**
* @param string[] $files
* @param bool $onlyFiles
* @param \Closure(string $file): void|null $preFileCallback
* @param \Closure(string $file): void|null $postFileCallback
* @param bool $debug
* @return string[]|\PHPStan\Analyser\Error[] errors
*/
public function analyse(
array $files,
bool $onlyFiles,
?\Closure $preFileCallback = null,
?\Closure $postFileCallback = null,
bool $debug = false
): array
{
$errors = [];
foreach ($this->ignoreErrors as $ignoreError) {
try {
\Nette\Utils\Strings::match('', $ignoreError);
} catch (\Nette\Utils\RegexpException $e) {
$errors[] = $e->getMessage();
}
}
if (count($errors) > 0) {
return $errors;
}
$this->nodeScopeResolver->setAnalysedFiles($files);
$internalErrorsCount = 0;
$reachedInternalErrorsCountLimit = false;
foreach ($files as $file) {
try {
$fileErrors = [];
if ($preFileCallback !== null) {
$preFileCallback($file);
}
if (is_file($file)) {
$this->nodeScopeResolver->processNodes(
$this->parser->parseFile($file),
$this->scopeFactory->create(ScopeContext::create($file)),
function (\PhpParser\Node $node, Scope $scope) use (&$fileErrors): void {
foreach ($this->registry->getRules(get_class($node)) as $rule) {
foreach ($rule->processNode($node, $scope) as $message) {
$fileErrors[] = new Error($message, $scope->getFileDescription(), $node->getLine());
}
}
}
);
} elseif (is_dir($file)) {
$fileErrors[] = new Error(sprintf('File %s is a directory.', $file), $file, null, false);
} else {
$fileErrors[] = new Error(sprintf('File %s does not exist.', $file), $file, null, false);
}
if ($postFileCallback !== null) {
$postFileCallback($file);
}
$errors = array_merge($errors, $fileErrors);
} catch (\PhpParser\Error $e) {
$errors[] = new Error($e->getMessage(), $file, $e->getStartLine() !== -1 ? $e->getStartLine() : null, false);
} catch (\PHPStan\AnalysedCodeException $e) {
$errors[] = new Error($e->getMessage(), $file, null, false);
} catch (\Throwable $t) {
if ($debug) {
throw $t;
}
$internalErrorsCount++;
$internalErrorMessage = sprintf('Internal error: %s', $t->getMessage());
$internalErrorMessage .= sprintf(
'%sRun PHPStan with --debug option and post the stack trace to:%s%s',
"\n",
"\n",
'https://github.com/phpstan/phpstan/issues/new'
);
$errors[] = new Error($internalErrorMessage, $file);
if ($internalErrorsCount >= $this->internalErrorsCountLimit) {
$reachedInternalErrorsCountLimit = true;
break;
}
}
}
$unmatchedIgnoredErrors = $this->ignoreErrors;
$addErrors = [];
$errors = array_values(array_filter($errors, function (Error $error) use (&$unmatchedIgnoredErrors, &$addErrors): bool {
foreach ($this->ignoreErrors as $i => $ignore) {
if (\Nette\Utils\Strings::match($error->getMessage(), $ignore) !== null) {
unset($unmatchedIgnoredErrors[$i]);
if (!$error->canBeIgnored()) {
$addErrors[] = sprintf(
'Error message "%s" cannot be ignored, use excludes_analyse instead.',
$error->getMessage()
);
return true;
}
return false;
}
}
return true;
}));
$errors = array_merge($errors, $addErrors);
if (!$onlyFiles && $this->reportUnmatchedIgnoredErrors && !$reachedInternalErrorsCountLimit) {
foreach ($unmatchedIgnoredErrors as $unmatchedIgnoredError) {
$errors[] = sprintf(
'Ignored error pattern %s was not matched in reported errors.',
$unmatchedIgnoredError
);
}
}
if ($reachedInternalErrorsCountLimit) {
$errors[] = sprintf('Reached internal errors count limit of %d, exiting...', $this->internalErrorsCountLimit);
}
return $errors;
}
}
src/Analyser/Error.php 0000666 00000001341 13436755504 0010732 0 ustar 00 message = $message;
$this->file = $file;
$this->line = $line;
$this->canBeIgnored = $canBeIgnored;
}
public function getMessage(): string
{
return $this->message;
}
public function getFile(): string
{
return $this->file;
}
public function getLine(): ?int
{
return $this->line;
}
public function canBeIgnored(): bool
{
return $this->canBeIgnored;
}
}
src/Analyser/OutOfClassScope.php 0000666 00000001535 13436755504 0012662 0 ustar 00 isPublic();
}
public function canCallMethod(MethodReflection $methodReflection): bool
{
return $methodReflection->isPublic();
}
public function canAccessConstant(ConstantReflection $constantReflection): bool
{
return $constantReflection->isPublic();
}
}
src/Analyser/StatementList.php 0000666 00000002542 13436755504 0012445 0 ustar 00 scope = $scope;
$this->statements = $statements;
$this->filterByTruthyValue = $filterByTruthyValue;
$this->processScope = $processScope;
}
public static function fromList(Scope $scope, self $list): self
{
return new self(
$scope,
$list->statements,
$list->filterByTruthyValue,
$list->processScope
);
}
public function getScope(): Scope
{
$scope = $this->scope;
if ($this->processScope !== null) {
$callback = $this->processScope;
$scope = $callback($scope);
}
return $scope;
}
/**
* @return \PhpParser\Node[]
*/
public function getStatements(): array
{
return $this->statements;
}
public function shouldFilterByTruthyValue(): bool
{
return $this->filterByTruthyValue;
}
}
src/Analyser/ScopeContext.php 0000666 00000003174 13436755504 0012265 0 ustar 00 file = $file;
$this->classReflection = $classReflection;
$this->traitReflection = $traitReflection;
}
public static function create(string $file): self
{
return new self($file, null, null);
}
public function beginFile(): self
{
return new self($this->file, null, null);
}
public function enterClass(ClassReflection $classReflection): self
{
if ($this->classReflection !== null && !$classReflection->isAnonymous()) {
throw new \PHPStan\ShouldNotHappenException();
}
if ($classReflection->isTrait()) {
throw new \PHPStan\ShouldNotHappenException();
}
return new self($this->file, $classReflection, null);
}
public function enterTrait(ClassReflection $traitReflection): self
{
if ($this->classReflection === null) {
throw new \PHPStan\ShouldNotHappenException();
}
if (!$traitReflection->isTrait()) {
throw new \PHPStan\ShouldNotHappenException();
}
return new self($this->file, $this->classReflection, $traitReflection);
}
public function getFile(): string
{
return $this->file;
}
public function getClassReflection(): ?ClassReflection
{
return $this->classReflection;
}
public function getTraitReflection(): ?ClassReflection
{
return $this->traitReflection;
}
}
src/Analyser/VariableTypeHolder.php 0000666 00000002031 13436755504 0013363 0 ustar 00 no()) {
throw new \PHPStan\ShouldNotHappenException();
}
$this->type = $type;
$this->certainty = $certainty;
}
public static function createYes(Type $type): self
{
return new self($type, TrinaryLogic::createYes());
}
public static function createMaybe(Type $type): self
{
return new self($type, TrinaryLogic::createMaybe());
}
public function and(self $other): self
{
return new self(
TypeCombinator::union($this->getType(), $other->getType()),
$this->getCertainty()->and($other->getCertainty())
);
}
public function getType(): Type
{
return $this->type;
}
public function getCertainty(): TrinaryLogic
{
return $this->certainty;
}
}
src/Analyser/TypeSpecifierFactory.php 0000666 00000004055 13436755504 0013751 0 ustar 00 container = $container;
}
public function create(): TypeSpecifier
{
$tagToService = function (array $tags) {
return array_map(function (string $serviceName) {
return $this->container->getService($serviceName);
}, array_keys($tags));
};
$typeSpecifier = new TypeSpecifier(
$this->container->getByType(Standard::class),
$this->container->getByType(Broker::class),
$tagToService($this->container->findByTag(self::FUNCTION_TYPE_SPECIFYING_EXTENSION_TAG)),
$tagToService($this->container->findByTag(self::METHOD_TYPE_SPECIFYING_EXTENSION_TAG)),
$tagToService($this->container->findByTag(self::STATIC_METHOD_TYPE_SPECIFYING_EXTENSION_TAG))
);
foreach (array_merge(
$tagToService($this->container->findByTag(BrokerFactory::PROPERTIES_CLASS_REFLECTION_EXTENSION_TAG)),
$tagToService($this->container->findByTag(BrokerFactory::METHODS_CLASS_REFLECTION_EXTENSION_TAG)),
$tagToService($this->container->findByTag(BrokerFactory::DYNAMIC_METHOD_RETURN_TYPE_EXTENSION_TAG)),
$tagToService($this->container->findByTag(BrokerFactory::DYNAMIC_STATIC_METHOD_RETURN_TYPE_EXTENSION_TAG)),
$tagToService($this->container->findByTag(BrokerFactory::DYNAMIC_FUNCTION_RETURN_TYPE_EXTENSION_TAG))
) as $extension) {
if (!($extension instanceof TypeSpecifierAwareExtension)) {
continue;
}
$extension->setTypeSpecifier($typeSpecifier);
}
return $typeSpecifier;
}
}
src/Analyser/LookForAssignsSettings.php 0000666 00000006307 13436755504 0014274 0 ustar 00 respectEarlyTermination = $respectEarlyTermination;
}
public static function default(): self
{
return self::create(self::EARLY_TERMINATION_ALL);
}
public static function insideLoop(): self
{
return self::create(self::EARLY_TERMINATION_STOP + self::EARLY_TERMINATION_BREAK + self::SKIP_DEAD_BRANCHES);
}
public static function afterLoop(): self
{
return self::create(self::EARLY_TERMINATION_STOP + self::SKIP_DEAD_BRANCHES);
}
public static function afterSwitch(): self
{
return self::create(self::EARLY_TERMINATION_STOP);
}
public static function insideFinally(): self
{
return self::create(0);
}
public static function insideClosure(): self
{
return self::create(self::EARLY_TERMINATION_CLOSURE);
}
private static function create(int $value): self
{
self::$registry[$value] = self::$registry[$value] ?? new self($value);
return self::$registry[$value];
}
public function skipDeadBranches(): bool
{
return ($this->respectEarlyTermination & self::SKIP_DEAD_BRANCHES) === self::SKIP_DEAD_BRANCHES;
}
public function shouldSkipBranch(\PhpParser\Node $earlyTerminationStatement): bool
{
return $this->isRespected($earlyTerminationStatement);
}
private function isRespected(\PhpParser\Node $earlyTerminationStatement): bool
{
if (
$earlyTerminationStatement instanceof Break_
) {
return ($this->respectEarlyTermination & self::EARLY_TERMINATION_BREAK) === self::EARLY_TERMINATION_BREAK;
}
if (
$earlyTerminationStatement instanceof Continue_
) {
return ($this->respectEarlyTermination & self::EARLY_TERMINATION_CONTINUE) === self::EARLY_TERMINATION_CONTINUE;
}
return ($this->respectEarlyTermination & self::EARLY_TERMINATION_STOP) === self::EARLY_TERMINATION_STOP;
}
public function shouldIntersectVariables(?\PhpParser\Node $earlyTerminationStatement): bool
{
if ($earlyTerminationStatement === null) {
return true;
}
if ($this->shouldSkipBranch($earlyTerminationStatement)) {
throw new \PHPStan\ShouldNotHappenException();
}
return $earlyTerminationStatement instanceof Break_
|| $earlyTerminationStatement instanceof Continue_
|| ($this->respectEarlyTermination & self::EARLY_TERMINATION_STOP) === 0;
}
public function shouldGeneralizeConstantTypesOfNonIdempotentOperations(): bool
{
return (
($this->respectEarlyTermination & self::EARLY_TERMINATION_STOP) === self::EARLY_TERMINATION_STOP
&& $this->respectEarlyTermination !== self::EARLY_TERMINATION_ALL
) || $this->respectEarlyTermination === self::EARLY_TERMINATION_CLOSURE;
}
}
src/Analyser/TypeSpecifierAwareExtension.php 0000666 00000000262 13436755504 0015272 0 ustar 00 fullName(string) */
private $uses;
/** @var string|null */
private $className;
/**
* @param string|null $namespace
* @param string[] $uses alias(string) => fullName(string)
* @param string|null $className
*/
public function __construct(?string $namespace, array $uses, ?string $className = null)
{
$this->namespace = $namespace;
$this->uses = $uses;
$this->className = $className;
}
public function getClassName(): ?string
{
return $this->className;
}
public function resolveStringName(string $name): string
{
if (strpos($name, '\\') === 0) {
return ltrim($name, '\\');
}
$nameParts = explode('\\', $name);
$firstNamePart = strtolower($nameParts[0]);
if (isset($this->uses[$firstNamePart])) {
if (count($nameParts) === 1) {
return $this->uses[$firstNamePart];
}
array_shift($nameParts);
return sprintf('%s\\%s', $this->uses[$firstNamePart], implode('\\', $nameParts));
}
if ($this->namespace !== null) {
return sprintf('%s\\%s', $this->namespace, $name);
}
return $name;
}
}
src/Analyser/TypeSpecifier.php 0000666 00000042362 13436755504 0012424 0 ustar 00 printer = $printer;
$this->broker = $broker;
foreach (array_merge($functionTypeSpecifyingExtensions, $methodTypeSpecifyingExtensions, $staticMethodTypeSpecifyingExtensions) as $extension) {
if (!($extension instanceof TypeSpecifierAwareExtension)) {
continue;
}
$extension->setTypeSpecifier($this);
}
$this->functionTypeSpecifyingExtensions = $functionTypeSpecifyingExtensions;
$this->methodTypeSpecifyingExtensions = $methodTypeSpecifyingExtensions;
$this->staticMethodTypeSpecifyingExtensions = $staticMethodTypeSpecifyingExtensions;
}
public function specifyTypesInCondition(
Scope $scope,
Expr $expr,
TypeSpecifierContext $context,
bool $defaultHandleFunctions = false
): SpecifiedTypes
{
if ($expr instanceof Instanceof_) {
if ($expr->class instanceof Name) {
$className = (string) $expr->class;
$lowercasedClassName = strtolower($className);
if ($lowercasedClassName === 'self' && $scope->isInClass()) {
$type = new ObjectType($scope->getClassReflection()->getName());
} elseif ($lowercasedClassName === 'static' && $scope->isInClass()) {
$type = new StaticType($scope->getClassReflection()->getName());
} elseif ($lowercasedClassName === 'parent') {
if (
$scope->isInClass()
&& $scope->getClassReflection()->getParentClass() !== false
) {
$type = new ObjectType($scope->getClassReflection()->getParentClass()->getName());
} else {
$type = new NonexistentParentClassType();
}
} else {
$type = new ObjectType($className);
}
return $this->create($expr->expr, $type, $context);
}
if ($context->true()) {
return $this->create($expr->expr, new ObjectWithoutClassType(), $context);
}
} elseif ($expr instanceof Node\Expr\BinaryOp\Identical) {
$expressions = $this->findTypeExpressionsFromBinaryOperation($scope, $expr);
if ($expressions !== null) {
/** @var Expr $exprNode */
$exprNode = $expressions[0];
/** @var \PHPStan\Type\ConstantScalarType $constantType */
$constantType = $expressions[1];
if ($constantType->getValue() === false) {
$types = $this->create($exprNode, $constantType, $context);
return $types->unionWith($this->specifyTypesInCondition(
$scope,
$exprNode,
$context->true() ? TypeSpecifierContext::createFalse() : TypeSpecifierContext::createFalse()->negate()
));
}
if ($constantType->getValue() === true) {
$types = $this->create($exprNode, $constantType, $context);
return $types->unionWith($this->specifyTypesInCondition(
$scope,
$exprNode,
$context->true() ? TypeSpecifierContext::createTrue() : TypeSpecifierContext::createTrue()->negate()
));
}
if ($constantType->getValue() === null) {
return $this->create($exprNode, $constantType, $context);
}
}
if ($context->true()) {
$type = TypeCombinator::intersect($scope->getType($expr->right), $scope->getType($expr->left));
$leftTypes = $this->create($expr->left, $type, $context);
$rightTypes = $this->create($expr->right, $type, $context);
return $leftTypes->unionWith($rightTypes);
} elseif ($context->false()) {
$identicalType = $scope->getType($expr);
if ($identicalType instanceof ConstantBooleanType) {
$never = new NeverType();
$contextForTypes = $identicalType->getValue() ? $context->negate() : $context;
$leftTypes = $this->create($expr->left, $never, $contextForTypes);
$rightTypes = $this->create($expr->right, $never, $contextForTypes);
return $leftTypes->unionWith($rightTypes);
}
if ($expr->left instanceof Node\Scalar && !$expr->right instanceof Node\Scalar) {
return $this->create(
$expr->right,
$scope->getType($expr->left),
$context
);
}
if ($expr->right instanceof Node\Scalar && !$expr->left instanceof Node\Scalar) {
return $this->create(
$expr->left,
$scope->getType($expr->right),
$context
);
}
}
} elseif ($expr instanceof Node\Expr\BinaryOp\NotIdentical) {
return $this->specifyTypesInCondition(
$scope,
new Node\Expr\BooleanNot(new Node\Expr\BinaryOp\Identical($expr->left, $expr->right)),
$context
);
} elseif ($expr instanceof Node\Expr\BinaryOp\Equal) {
$expressions = $this->findTypeExpressionsFromBinaryOperation($scope, $expr);
if ($expressions !== null) {
/** @var Expr $exprNode */
$exprNode = $expressions[0];
/** @var \PHPStan\Type\ConstantScalarType $constantType */
$constantType = $expressions[1];
if ($constantType->getValue() === false || $constantType->getValue() === null) {
return $this->specifyTypesInCondition(
$scope,
$exprNode,
$context->true() ? TypeSpecifierContext::createFalsey() : TypeSpecifierContext::createFalsey()->negate()
);
}
if ($constantType->getValue() === true) {
return $this->specifyTypesInCondition(
$scope,
$exprNode,
$context->true() ? TypeSpecifierContext::createTruthy() : TypeSpecifierContext::createTruthy()->negate()
);
}
}
} elseif ($expr instanceof Node\Expr\BinaryOp\NotEqual) {
return $this->specifyTypesInCondition(
$scope,
new Node\Expr\BooleanNot(new Node\Expr\BinaryOp\Equal($expr->left, $expr->right)),
$context
);
} elseif ($expr instanceof FuncCall && $expr->name instanceof Name) {
if ($this->broker->hasFunction($expr->name, $scope)) {
$functionReflection = $this->broker->getFunction($expr->name, $scope);
foreach ($this->getFunctionTypeSpecifyingExtensions() as $extension) {
if (!$extension->isFunctionSupported($functionReflection, $expr, $context)) {
continue;
}
return $extension->specifyTypes($functionReflection, $expr, $scope, $context);
}
}
if ($defaultHandleFunctions) {
return $this->handleDefaultTruthyOrFalseyContext($context, $expr);
}
} elseif ($expr instanceof MethodCall && $expr->name instanceof Node\Identifier) {
$methodCalledOnType = $scope->getType($expr->var);
$referencedClasses = TypeUtils::getDirectClassNames($methodCalledOnType);
if (
count($referencedClasses) === 1
&& $this->broker->hasClass($referencedClasses[0])
) {
$methodClassReflection = $this->broker->getClass($referencedClasses[0]);
if ($methodClassReflection->hasMethod($expr->name->name)) {
$methodReflection = $methodClassReflection->getMethod($expr->name->name, $scope);
foreach ($this->getMethodTypeSpecifyingExtensionsForClass($methodClassReflection->getName()) as $extension) {
if (!$extension->isMethodSupported($methodReflection, $expr, $context)) {
continue;
}
return $extension->specifyTypes($methodReflection, $expr, $scope, $context);
}
}
}
if ($defaultHandleFunctions) {
return $this->handleDefaultTruthyOrFalseyContext($context, $expr);
}
} elseif ($expr instanceof StaticCall && $expr->name instanceof Node\Identifier) {
if ($expr->class instanceof Name) {
$calleeType = new ObjectType($scope->resolveName($expr->class));
} else {
$calleeType = $scope->getType($expr->class);
}
if ($calleeType->hasMethod($expr->name->name)) {
$staticMethodReflection = $calleeType->getMethod($expr->name->name, $scope);
$referencedClasses = TypeUtils::getDirectClassNames($calleeType);
if (
count($referencedClasses) === 1
&& $this->broker->hasClass($referencedClasses[0])
) {
$staticMethodClassReflection = $this->broker->getClass($referencedClasses[0]);
foreach ($this->getStaticMethodTypeSpecifyingExtensionsForClass($staticMethodClassReflection->getName()) as $extension) {
if (!$extension->isStaticMethodSupported($staticMethodReflection, $expr, $context)) {
continue;
}
return $extension->specifyTypes($staticMethodReflection, $expr, $scope, $context);
}
}
}
if ($defaultHandleFunctions) {
return $this->handleDefaultTruthyOrFalseyContext($context, $expr);
}
} elseif ($expr instanceof BooleanAnd || $expr instanceof LogicalAnd) {
$leftTypes = $this->specifyTypesInCondition($scope, $expr->left, $context);
$rightTypes = $this->specifyTypesInCondition($scope, $expr->right, $context);
return $context->true() ? $leftTypes->unionWith($rightTypes) : $leftTypes->intersectWith($rightTypes);
} elseif ($expr instanceof BooleanOr || $expr instanceof LogicalOr) {
$leftTypes = $this->specifyTypesInCondition($scope, $expr->left, $context);
$rightTypes = $this->specifyTypesInCondition($scope, $expr->right, $context);
return $context->true() ? $leftTypes->intersectWith($rightTypes) : $leftTypes->unionWith($rightTypes);
} elseif ($expr instanceof Node\Expr\BooleanNot && !$context->null()) {
return $this->specifyTypesInCondition($scope, $expr->expr, $context->negate());
} elseif ($expr instanceof Node\Expr\Assign) {
if ($context->null()) {
return $this->specifyTypesInCondition($scope, $expr->expr, $context);
}
return $this->specifyTypesInCondition($scope, $expr->var, $context);
} elseif (
(
$expr instanceof Expr\Isset_
&& count($expr->vars) > 0
&& $context->truthy()
)
|| ($expr instanceof Expr\Empty_ && $context->falsey())
) {
$vars = [];
if ($expr instanceof Expr\Isset_) {
$varsToIterate = $expr->vars;
} else {
$varsToIterate = [$expr->expr];
}
foreach ($varsToIterate as $var) {
$vars[] = $var;
while (
$var instanceof ArrayDimFetch
|| $var instanceof PropertyFetch
|| (
$var instanceof StaticPropertyFetch
&& $var->class instanceof Expr
)
) {
if ($var instanceof StaticPropertyFetch) {
/** @var Expr $var */
$var = $var->class;
} else {
$var = $var->var;
}
$vars[] = $var;
}
}
$types = null;
foreach ($vars as $var) {
if ($expr instanceof Expr\Isset_) {
if (
$var instanceof ArrayDimFetch
&& $var->dim !== null
&& !$scope->getType($var->var) instanceof MixedType
) {
$type = $this->create(
$var->var,
new HasOffsetType($scope->getType($var->dim)),
$context
)->unionWith(
$this->create($var, new NullType(), TypeSpecifierContext::createFalse())
);
} else {
$type = $this->create($var, new NullType(), TypeSpecifierContext::createFalse());
}
} else {
$type = $this->create(
$var,
new UnionType([
new NullType(),
new ConstantBooleanType(false),
]),
TypeSpecifierContext::createFalse()
);
}
if ($types === null) {
$types = $type;
} else {
$types = $types->unionWith($type);
}
}
/** @var SpecifiedTypes $types */
$types = $types;
return $types;
} elseif (!$context->null()) {
return $this->handleDefaultTruthyOrFalseyContext($context, $expr);
}
return new SpecifiedTypes();
}
private function handleDefaultTruthyOrFalseyContext(TypeSpecifierContext $context, Expr $expr): SpecifiedTypes
{
if (!$context->truthy()) {
$type = new ObjectWithoutClassType();
return $this->create($expr, $type, TypeSpecifierContext::createFalse());
} elseif (!$context->falsey()) {
$type = new UnionType([
new NullType(),
new ConstantBooleanType(false),
new ConstantIntegerType(0),
new ConstantFloatType(0.0),
new ConstantStringType(''),
new ConstantArrayType([], []),
]);
return $this->create($expr, $type, TypeSpecifierContext::createFalse());
}
return new SpecifiedTypes();
}
/**
* @param \PHPStan\Analyser\Scope $scope
* @param \PhpParser\Node\Expr\BinaryOp $binaryOperation
* @return (Expr|\PHPStan\Type\ConstantScalarType)[]|null
*/
private function findTypeExpressionsFromBinaryOperation(Scope $scope, Node\Expr\BinaryOp $binaryOperation): ?array
{
$leftType = $scope->getType($binaryOperation->left);
$rightType = $scope->getType($binaryOperation->right);
if (
$leftType instanceof \PHPStan\Type\ConstantScalarType
&& !$binaryOperation->right instanceof ConstFetch
&& !$binaryOperation->right instanceof Expr\ClassConstFetch
) {
return [$binaryOperation->right, $leftType];
} elseif (
$rightType instanceof \PHPStan\Type\ConstantScalarType
&& !$binaryOperation->left instanceof ConstFetch
&& !$binaryOperation->left instanceof Expr\ClassConstFetch
) {
return [$binaryOperation->left, $rightType];
}
return null;
}
public function create(Expr $expr, Type $type, TypeSpecifierContext $context): SpecifiedTypes
{
if ($expr instanceof New_) {
return new SpecifiedTypes();
}
$sureTypes = [];
$sureNotTypes = [];
$exprString = $this->printer->prettyPrintExpr($expr);
if ($context->false()) {
$sureNotTypes[$exprString] = [$expr, $type];
} elseif ($context->true()) {
$sureTypes[$exprString] = [$expr, $type];
}
return new SpecifiedTypes($sureTypes, $sureNotTypes);
}
/**
* @return \PHPStan\Type\FunctionTypeSpecifyingExtension[]
*/
public function getFunctionTypeSpecifyingExtensions(): array
{
return $this->functionTypeSpecifyingExtensions;
}
/**
* @param string $className
* @return \PHPStan\Type\MethodTypeSpecifyingExtension[]
*/
public function getMethodTypeSpecifyingExtensionsForClass(string $className): array
{
if ($this->methodTypeSpecifyingExtensionsByClass === null) {
$byClass = [];
foreach ($this->methodTypeSpecifyingExtensions as $extension) {
$byClass[$extension->getClass()][] = $extension;
}
$this->methodTypeSpecifyingExtensionsByClass = $byClass;
}
return $this->getTypeSpecifyingExtensionsForType($this->methodTypeSpecifyingExtensionsByClass, $className);
}
/**
* @param string $className
* @return \PHPStan\Type\StaticMethodTypeSpecifyingExtension[]
*/
public function getStaticMethodTypeSpecifyingExtensionsForClass(string $className): array
{
if ($this->staticMethodTypeSpecifyingExtensionsByClass === null) {
$byClass = [];
foreach ($this->staticMethodTypeSpecifyingExtensions as $extension) {
$byClass[$extension->getClass()][] = $extension;
}
$this->staticMethodTypeSpecifyingExtensionsByClass = $byClass;
}
return $this->getTypeSpecifyingExtensionsForType($this->staticMethodTypeSpecifyingExtensionsByClass, $className);
}
/**
* @param \PHPStan\Type\MethodTypeSpecifyingExtension[][]|\PHPStan\Type\StaticMethodTypeSpecifyingExtension[][] $extensions
* @param string $className
* @return mixed[]
*/
private function getTypeSpecifyingExtensionsForType(array $extensions, string $className): array
{
$extensionsForClass = [];
$class = $this->broker->getClass($className);
foreach (array_merge([$className], $class->getParentClassesNames(), $class->getNativeReflection()->getInterfaceNames()) as $extensionClassName) {
if (!isset($extensions[$extensionClassName])) {
continue;
}
$extensionsForClass = array_merge($extensionsForClass, $extensions[$extensionClassName]);
}
return $extensionsForClass;
}
}
src/Analyser/Scope.php 0000666 00000233202 13436755504 0010715 0 ustar 00 scopeFactory = $scopeFactory;
$this->broker = $broker;
$this->printer = $printer;
$this->typeSpecifier = $typeSpecifier;
$this->context = $context;
$this->declareStrictTypes = $declareStrictTypes;
$this->function = $function;
$this->namespace = $namespace;
$this->variableTypes = $variablesTypes;
$this->moreSpecificTypes = $moreSpecificTypes;
$this->inClosureBindScopeClass = $inClosureBindScopeClass;
$this->inAnonymousFunctionReturnType = $inAnonymousFunctionReturnType;
$this->inFunctionCall = $inFunctionCall;
$this->negated = $negated;
$this->inFirstLevelStatement = $inFirstLevelStatement;
$this->currentlyAssignedExpressions = $currentlyAssignedExpressions;
$this->dynamicConstantNames = $dynamicConstantNames;
}
public function getFile(): string
{
return $this->context->getFile();
}
public function getFileDescription(): string
{
if ($this->context->getTraitReflection() === null) {
return $this->getFile();
}
/** @var ClassReflection $classReflection */
$classReflection = $this->context->getClassReflection();
$className = sprintf('class %s', $classReflection->getDisplayName());
if ($classReflection->isAnonymous()) {
$className = 'anonymous class';
}
$traitReflection = $this->context->getTraitReflection();
if ($traitReflection->getFileName() === false) {
throw new \PHPStan\ShouldNotHappenException();
}
return sprintf(
'%s (in context of %s)',
$traitReflection->getFileName(),
$className
);
}
public function isDeclareStrictTypes(): bool
{
return $this->declareStrictTypes;
}
public function enterDeclareStrictTypes(): self
{
return $this->scopeFactory->create(
$this->context,
true
);
}
public function isInClass(): bool
{
return $this->context->getClassReflection() !== null;
}
public function isInTrait(): bool
{
return $this->context->getTraitReflection() !== null;
}
public function getClassReflection(): ?ClassReflection
{
return $this->context->getClassReflection();
}
public function getTraitReflection(): ?ClassReflection
{
return $this->context->getTraitReflection();
}
/**
* @return \PHPStan\Reflection\FunctionReflection|\PHPStan\Reflection\MethodReflection|null
*/
public function getFunction()
{
return $this->function;
}
public function getFunctionName(): ?string
{
return $this->function !== null ? $this->function->getName() : null;
}
public function getNamespace(): ?string
{
return $this->namespace;
}
/**
* @return array
*/
private function getVariableTypes(): array
{
return $this->variableTypes;
}
public function hasVariableType(string $variableName): TrinaryLogic
{
if ($this->isGlobalVariable($variableName)) {
return TrinaryLogic::createYes();
}
if (!isset($this->variableTypes[$variableName])) {
return TrinaryLogic::createNo();
}
return $this->variableTypes[$variableName]->getCertainty();
}
public function getVariableType(string $variableName): Type
{
if ($this->isGlobalVariable($variableName)) {
return new ArrayType(new StringType(), new MixedType());
}
if ($this->hasVariableType($variableName)->no()) {
throw new \PHPStan\Analyser\UndefinedVariableException($this, $variableName);
}
return $this->variableTypes[$variableName]->getType();
}
private function isGlobalVariable(string $variableName): bool
{
return in_array($variableName, [
'GLOBALS',
'_SERVER',
'_GET',
'_POST',
'_FILES',
'_COOKIE',
'_SESSION',
'_REQUEST',
'_ENV',
], true);
}
public function hasConstant(Name $name): bool
{
$node = new ConstFetch(new Name\FullyQualified($name->toString()));
if ($this->isSpecified($node)) {
return true;
}
return $this->broker->hasConstant($name, $this);
}
public function isInAnonymousFunction(): bool
{
return $this->inAnonymousFunctionReturnType !== null;
}
public function getAnonymousFunctionReturnType(): ?\PHPStan\Type\Type
{
return $this->inAnonymousFunctionReturnType;
}
/**
* @return \PhpParser\Node\Expr\FuncCall|\PhpParser\Node\Expr\MethodCall|\PhpParser\Node\Expr\StaticCall|null
*/
public function getInFunctionCall()
{
return $this->inFunctionCall;
}
public function getType(Expr $node): Type
{
$key = $this->printer->prettyPrintExpr($node);
if (!array_key_exists($key, $this->resolvedTypes)) {
$this->resolvedTypes[$key] = $this->resolveType($node);
}
return $this->resolvedTypes[$key];
}
private function resolveType(Expr $node): Type
{
if (
$node instanceof Expr\BinaryOp\Greater
|| $node instanceof Expr\BinaryOp\GreaterOrEqual
|| $node instanceof Expr\BinaryOp\Smaller
|| $node instanceof Expr\BinaryOp\SmallerOrEqual
|| $node instanceof Expr\BinaryOp\Equal
|| $node instanceof Expr\BinaryOp\NotEqual
|| $node instanceof Expr\Empty_
) {
return new BooleanType();
}
if ($node instanceof Expr\Isset_) {
foreach ($node->vars as $var) {
if ($var instanceof Expr\ArrayDimFetch && $var->dim !== null) {
$hasOffset = $this->getType($var->var)->hasOffsetValueType(
$this->getType($var->dim)
)->toBooleanType();
if ($hasOffset instanceof ConstantBooleanType) {
if (!$hasOffset->getValue()) {
return $hasOffset;
}
continue;
}
return $hasOffset;
}
return new BooleanType();
}
return new ConstantBooleanType(true);
}
if ($node instanceof \PhpParser\Node\Expr\BooleanNot) {
$exprBooleanType = $this->getType($node->expr)->toBoolean();
if ($exprBooleanType instanceof ConstantBooleanType) {
return new ConstantBooleanType(!$exprBooleanType->getValue());
}
return new BooleanType();
}
if (
$node instanceof \PhpParser\Node\Expr\BinaryOp\BooleanAnd
|| $node instanceof \PhpParser\Node\Expr\BinaryOp\LogicalAnd
) {
$leftBooleanType = $this->getType($node->left)->toBoolean();
if (
$leftBooleanType instanceof ConstantBooleanType
&& !$leftBooleanType->getValue()
) {
return new ConstantBooleanType(false);
}
$rightBooleanType = $this->filterByTruthyValue($node->left)->getType($node->right)->toBoolean();
if (
$rightBooleanType instanceof ConstantBooleanType
&& !$rightBooleanType->getValue()
) {
return new ConstantBooleanType(false);
}
if (
$leftBooleanType instanceof ConstantBooleanType
&& $leftBooleanType->getValue()
&& $rightBooleanType instanceof ConstantBooleanType
&& $rightBooleanType->getValue()
) {
return new ConstantBooleanType(true);
}
return new BooleanType();
}
if (
$node instanceof \PhpParser\Node\Expr\BinaryOp\BooleanOr
|| $node instanceof \PhpParser\Node\Expr\BinaryOp\LogicalOr
) {
$leftBooleanType = $this->getType($node->left)->toBoolean();
if (
$leftBooleanType instanceof ConstantBooleanType
&& $leftBooleanType->getValue()
) {
return new ConstantBooleanType(true);
}
$rightBooleanType = $this->filterByFalseyValue($node->left)->getType($node->right)->toBoolean();
if (
$rightBooleanType instanceof ConstantBooleanType
&& $rightBooleanType->getValue()
) {
return new ConstantBooleanType(true);
}
if (
$leftBooleanType instanceof ConstantBooleanType
&& !$leftBooleanType->getValue()
&& $rightBooleanType instanceof ConstantBooleanType
&& !$rightBooleanType->getValue()
) {
return new ConstantBooleanType(false);
}
return new BooleanType();
}
if ($node instanceof \PhpParser\Node\Expr\BinaryOp\LogicalXor) {
$leftBooleanType = $this->getType($node->left)->toBoolean();
$rightBooleanType = $this->filterByFalseyValue($node->left)->getType($node->right)->toBoolean();
if (
$leftBooleanType instanceof ConstantBooleanType
&& $rightBooleanType instanceof ConstantBooleanType
) {
return new ConstantBooleanType(
$leftBooleanType->getValue() xor $rightBooleanType->getValue()
);
}
return new BooleanType();
}
if ($node instanceof Expr\BinaryOp\Identical) {
$leftType = $this->getType($node->left);
$rightType = $this->getType($node->right);
if (
(
$node->left instanceof Node\Expr\PropertyFetch
|| $node->left instanceof Node\Expr\StaticPropertyFetch
)
&& $rightType instanceof NullType
) {
return new BooleanType();
}
if (
(
$node->right instanceof Node\Expr\PropertyFetch
|| $node->right instanceof Node\Expr\StaticPropertyFetch
)
&& $leftType instanceof NullType
) {
return new BooleanType();
}
$isSuperset = $leftType->isSuperTypeOf($rightType);
if ($isSuperset->no()) {
return new ConstantBooleanType(false);
} elseif (
$isSuperset->yes()
&& $leftType instanceof ConstantScalarType
&& $rightType instanceof ConstantScalarType
&& $leftType->getValue() === $rightType->getValue()
) {
return new ConstantBooleanType(true);
}
return new BooleanType();
}
if ($node instanceof Expr\BinaryOp\NotIdentical) {
$leftType = $this->getType($node->left);
$rightType = $this->getType($node->right);
if (
(
$node->left instanceof Node\Expr\PropertyFetch
|| $node->left instanceof Node\Expr\StaticPropertyFetch
)
&& $rightType instanceof NullType
) {
return new BooleanType();
}
if (
(
$node->right instanceof Node\Expr\PropertyFetch
|| $node->right instanceof Node\Expr\StaticPropertyFetch
)
&& $leftType instanceof NullType
) {
return new BooleanType();
}
$isSuperset = $leftType->isSuperTypeOf($rightType);
if ($isSuperset->no()) {
return new ConstantBooleanType(true);
} elseif (
$isSuperset->yes()
&& $leftType instanceof ConstantScalarType
&& $rightType instanceof ConstantScalarType
&& $leftType->getValue() === $rightType->getValue()
) {
return new ConstantBooleanType(false);
}
return new BooleanType();
}
if ($node instanceof Expr\Instanceof_) {
if ($node->class instanceof Node\Name) {
$className = $this->resolveName($node->class);
$type = new ObjectType($className);
} else {
$type = $this->getType($node->class);
}
$expressionType = $this->getType($node->expr);
if (
$this->isInTrait()
&& TypeUtils::findThisType($expressionType) !== null
) {
return new BooleanType();
}
if ($expressionType instanceof NeverType) {
return new ConstantBooleanType(false);
}
$isExpressionObject = (new ObjectWithoutClassType())->isSuperTypeOf($expressionType);
if (!$isExpressionObject->no() && !(new StringType())->isSuperTypeOf($type)->no()) {
return new BooleanType();
}
$isSuperType = $type->isSuperTypeOf($expressionType)
->and($isExpressionObject);
if ($isSuperType->no()) {
return new ConstantBooleanType(false);
} elseif ($isSuperType->yes()) {
return new ConstantBooleanType(true);
}
return new BooleanType();
}
if ($node instanceof Node\Expr\UnaryPlus) {
return $this->getType($node->expr)->toNumber();
}
if ($node instanceof Expr\ErrorSuppress
|| $node instanceof Expr\Assign
) {
return $this->getType($node->expr);
}
if ($node instanceof Node\Expr\UnaryMinus) {
$type = $this->getType($node->expr)->toNumber();
$scalarValues = TypeUtils::getConstantScalars($type);
if (count($scalarValues) > 0) {
$newTypes = [];
foreach ($scalarValues as $scalarValue) {
if ($scalarValue instanceof ConstantIntegerType) {
$newTypes[] = new ConstantIntegerType(-$scalarValue->getValue());
} elseif ($scalarValue instanceof ConstantFloatType) {
$newTypes[] = new ConstantFloatType(-$scalarValue->getValue());
}
}
return TypeCombinator::union(...$newTypes);
}
return $type;
}
if ($node instanceof Expr\BinaryOp\Concat || $node instanceof Expr\AssignOp\Concat) {
if ($node instanceof Node\Expr\AssignOp) {
$left = $node->var;
$right = $node->expr;
} else {
$left = $node->left;
$right = $node->right;
}
$leftStringType = $this->getType($left)->toString();
$rightStringType = $this->getType($right)->toString();
if (TypeCombinator::union(
$leftStringType,
$rightStringType
) instanceof ErrorType) {
return new ErrorType();
}
if ($leftStringType instanceof ConstantStringType && $rightStringType instanceof ConstantStringType) {
return $leftStringType->append($rightStringType);
}
return new StringType();
}
if (
$node instanceof Node\Expr\BinaryOp\Div
|| $node instanceof Node\Expr\AssignOp\Div
|| $node instanceof Node\Expr\BinaryOp\Mod
|| $node instanceof Node\Expr\AssignOp\Mod
) {
if ($node instanceof Node\Expr\AssignOp) {
$right = $node->expr;
} else {
$right = $node->right;
}
$rightTypes = TypeUtils::getConstantScalars($this->getType($right)->toNumber());
foreach ($rightTypes as $rightType) {
if (
$rightType->getValue() === 0
|| $rightType->getValue() === 0.0
) {
return new ErrorType();
}
}
}
if (
(
$node instanceof Node\Expr\BinaryOp
|| $node instanceof Node\Expr\AssignOp
) && !$node instanceof Expr\BinaryOp\Coalesce
) {
if ($node instanceof Node\Expr\AssignOp) {
$left = $node->var;
$right = $node->expr;
} else {
$left = $node->left;
$right = $node->right;
}
$leftTypes = TypeUtils::getConstantScalars($this->getType($left));
$rightTypes = TypeUtils::getConstantScalars($this->getType($right));
if (count($leftTypes) > 0 && count($rightTypes) > 0) {
$resultTypes = [];
foreach ($leftTypes as $leftType) {
foreach ($rightTypes as $rightType) {
$resultTypes[] = $this->calculateFromScalars($node, $leftType, $rightType);
}
}
return TypeCombinator::union(...$resultTypes);
}
}
if ($node instanceof Node\Expr\BinaryOp\Mod || $node instanceof Expr\AssignOp\Mod) {
return new IntegerType();
}
if ($node instanceof Expr\BinaryOp\Spaceship) {
return new IntegerType();
}
if ($node instanceof Expr\BinaryOp\Coalesce) {
if ($node->left instanceof Expr\ArrayDimFetch && $node->left->dim !== null) {
$dimType = $this->getType($node->left->dim);
$varType = $this->getType($node->left->var);
$hasOffset = $varType->hasOffsetValueType($dimType);
$leftType = $this->getType($node->left);
$rightType = $this->getType($node->right);
if ($hasOffset->no()) {
return $rightType;
} elseif ($hasOffset->yes()) {
$offsetValueType = $varType->getOffsetValueType($dimType);
if ($offsetValueType->isSuperTypeOf(new NullType())->no()) {
return TypeCombinator::removeNull($leftType);
}
}
return TypeCombinator::union(
TypeCombinator::removeNull($leftType),
$rightType
);
}
$leftType = $this->getType($node->left);
$rightType = $this->getType($node->right);
if ($leftType instanceof ErrorType || $leftType instanceof NullType) {
return $rightType;
}
if (TypeCombinator::containsNull($leftType) || $node->left instanceof PropertyFetch) {
return TypeCombinator::union(
TypeCombinator::removeNull($leftType),
$rightType
);
}
return TypeCombinator::removeNull($leftType);
}
if ($node instanceof Expr\Clone_) {
return $this->getType($node->expr);
}
if (
$node instanceof Expr\AssignOp\ShiftLeft
|| $node instanceof Expr\BinaryOp\ShiftLeft
|| $node instanceof Expr\AssignOp\ShiftRight
|| $node instanceof Expr\BinaryOp\ShiftRight
|| $node instanceof Expr\AssignOp\BitwiseAnd
|| $node instanceof Expr\BinaryOp\BitwiseAnd
|| $node instanceof Expr\AssignOp\BitwiseOr
|| $node instanceof Expr\BinaryOp\BitwiseOr
|| $node instanceof Expr\AssignOp\BitwiseXor
|| $node instanceof Expr\BinaryOp\BitwiseXor
) {
if ($node instanceof Node\Expr\AssignOp) {
$left = $node->var;
$right = $node->expr;
} else {
$left = $node->left;
$right = $node->right;
}
if (TypeCombinator::union(
$this->getType($left)->toNumber(),
$this->getType($right)->toNumber()
) instanceof ErrorType) {
return new ErrorType();
}
return new IntegerType();
}
if (
$node instanceof Node\Expr\BinaryOp\Plus
|| $node instanceof Node\Expr\BinaryOp\Minus
|| $node instanceof Node\Expr\BinaryOp\Mul
|| $node instanceof Node\Expr\BinaryOp\Pow
|| $node instanceof Node\Expr\BinaryOp\Div
|| $node instanceof Node\Expr\AssignOp\Plus
|| $node instanceof Node\Expr\AssignOp\Minus
|| $node instanceof Node\Expr\AssignOp\Mul
|| $node instanceof Node\Expr\AssignOp\Pow
|| $node instanceof Node\Expr\AssignOp\Div
) {
if ($node instanceof Node\Expr\AssignOp) {
$left = $node->var;
$right = $node->expr;
} else {
$left = $node->left;
$right = $node->right;
}
$leftType = $this->getType($left);
$rightType = $this->getType($right);
if ($node instanceof Expr\AssignOp\Plus || $node instanceof Expr\BinaryOp\Plus) {
$leftConstantArrays = TypeUtils::getConstantArrays($leftType);
$rightConstantArrays = TypeUtils::getConstantArrays($rightType);
if (count($leftConstantArrays) > 0 && count($rightConstantArrays) > 0) {
$resultTypes = [];
foreach ($rightConstantArrays as $rightConstantArray) {
foreach ($leftConstantArrays as $leftConstantArray) {
$newArrayBuilder = ConstantArrayTypeBuilder::createFromConstantArray($rightConstantArray);
foreach ($leftConstantArray->getKeyTypes() as $leftKeyType) {
$newArrayBuilder->setOffsetValueType(
$leftKeyType,
$leftConstantArray->getOffsetValueType($leftKeyType)
);
}
$resultTypes[] = $newArrayBuilder->getArray();
}
}
return TypeCombinator::union(...$resultTypes);
}
$leftArrays = TypeUtils::getArrays($leftType);
$rightArrays = TypeUtils::getArrays($rightType);
if (count($leftArrays) > 0 && count($rightArrays) > 0) {
$resultTypes = [];
foreach ($rightArrays as $rightArray) {
foreach ($leftArrays as $leftArray) {
$resultTypes[] = new ArrayType(
TypeCombinator::union($leftArray->getKeyType(), $rightArray->getKeyType()),
TypeCombinator::union($leftArray->getItemType(), $rightArray->getItemType())
);
}
}
return TypeCombinator::union(...$resultTypes);
}
if ($leftType instanceof MixedType && $rightType instanceof MixedType) {
return new BenevolentUnionType([
new FloatType(),
new IntegerType(),
new ArrayType(new MixedType(), new MixedType()),
]);
}
}
$types = TypeCombinator::union($leftType, $rightType);
if (
$leftType instanceof ArrayType
|| $rightType instanceof ArrayType
|| $types instanceof ArrayType
) {
return new ErrorType();
}
$leftNumberType = $leftType->toNumber();
$rightNumberType = $rightType->toNumber();
if (
(new FloatType())->isSuperTypeOf($leftNumberType)->yes()
|| (new FloatType())->isSuperTypeOf($rightNumberType)->yes()
) {
return new FloatType();
}
if ($node instanceof Expr\AssignOp\Pow || $node instanceof Expr\BinaryOp\Pow) {
return new BenevolentUnionType([
new FloatType(),
new IntegerType(),
]);
}
$resultType = TypeCombinator::union($leftNumberType, $rightNumberType);
if ($node instanceof Expr\AssignOp\Div || $node instanceof Expr\BinaryOp\Div) {
if ($types instanceof MixedType || $resultType instanceof IntegerType) {
return new BenevolentUnionType([new IntegerType(), new FloatType()]);
}
return new UnionType([new IntegerType(), new FloatType()]);
}
if ($types instanceof MixedType) {
return TypeUtils::toBenevolentUnion($resultType);
}
return $resultType;
}
if ($node instanceof LNumber) {
return new ConstantIntegerType($node->value);
} elseif ($node instanceof String_) {
return new ConstantStringType($node->value);
} elseif ($node instanceof Node\Scalar\Encapsed) {
$constantString = new ConstantStringType('');
foreach ($node->parts as $part) {
if ($part instanceof EncapsedStringPart) {
$partStringType = new ConstantStringType($part->value);
} else {
$partStringType = $this->getType($part)->toString();
if ($partStringType instanceof ErrorType) {
return new ErrorType();
}
if (!$partStringType instanceof ConstantStringType) {
return new StringType();
}
}
$constantString = $constantString->append($partStringType);
}
return $constantString;
} elseif ($node instanceof DNumber) {
return new ConstantFloatType($node->value);
} elseif ($node instanceof Expr\Closure) {
$parameters = [];
$isVariadic = false;
$firstOptionalParameterIndex = null;
foreach ($node->params as $i => $param) {
$isOptionalCandidate = $param->default !== null || $param->variadic;
if ($isOptionalCandidate) {
if ($firstOptionalParameterIndex === null) {
$firstOptionalParameterIndex = $i;
}
} else {
$firstOptionalParameterIndex = null;
}
}
foreach ($node->params as $i => $param) {
if ($param->variadic) {
$isVariadic = true;
}
if (!$param->var instanceof Variable || !is_string($param->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
$parameters[] = new NativeParameterReflection(
$param->var->name,
$firstOptionalParameterIndex !== null && $i >= $firstOptionalParameterIndex,
$this->getFunctionType($param->type, $param->type === null, false),
$param->byRef
? PassedByReference::createCreatesNewVariable()
: PassedByReference::createNo(),
$param->variadic
);
}
return new ClosureType(
$parameters,
$this->getFunctionType($node->returnType, $node->returnType === null, false),
$isVariadic
);
} elseif ($node instanceof New_) {
if ($node->class instanceof Name) {
if (
count($node->class->parts) === 1
) {
$lowercasedClassName = strtolower($node->class->parts[0]);
if (in_array($lowercasedClassName, [
'self',
'static',
'parent',
], true)) {
if (!$this->isInClass()) {
throw new \PHPStan\ShouldNotHappenException();
}
if ($lowercasedClassName === 'static') {
return new StaticType($this->getClassReflection()->getName());
}
if ($lowercasedClassName === 'self') {
return new ObjectType($this->getClassReflection()->getName());
}
if ($this->getClassReflection()->getParentClass() !== false) {
return new ObjectType($this->getClassReflection()->getParentClass()->getName());
}
return new NonexistentParentClassType();
}
}
return new ObjectType((string) $node->class);
}
if ($node->class instanceof Node\Stmt\Class_) {
$anonymousClassReflection = $this->broker->getAnonymousClassReflection($node, $this);
return new ObjectType($anonymousClassReflection->getName());
}
} elseif ($node instanceof Array_) {
$arrayBuilder = ConstantArrayTypeBuilder::createEmpty();
foreach ($node->items as $arrayItem) {
$arrayBuilder->setOffsetValueType(
$arrayItem->key !== null ? $this->getType($arrayItem->key) : null,
$this->getType($arrayItem->value)
);
}
return $arrayBuilder->getArray();
} elseif ($node instanceof Int_) {
return $this->getType($node->expr)->toInteger();
} elseif ($node instanceof Bool_) {
return $this->getType($node->expr)->toBoolean();
} elseif ($node instanceof Double) {
return $this->getType($node->expr)->toFloat();
} elseif ($node instanceof \PhpParser\Node\Expr\Cast\String_) {
return $this->getType($node->expr)->toString();
} elseif ($node instanceof \PhpParser\Node\Expr\Cast\Array_) {
return $this->getType($node->expr)->toArray();
} elseif ($node instanceof Node\Scalar\MagicConst\Line) {
return new ConstantIntegerType($node->getLine());
} elseif ($node instanceof Node\Scalar\MagicConst\Class_) {
if (!$this->isInClass()) {
return new ConstantStringType('');
}
return new ConstantStringType($this->getClassReflection()->getName());
} elseif ($node instanceof Node\Scalar\MagicConst\Dir) {
return new ConstantStringType(dirname($this->getFile()));
} elseif ($node instanceof Node\Scalar\MagicConst\File) {
return new ConstantStringType($this->getFile());
} elseif ($node instanceof Node\Scalar\MagicConst\Namespace_) {
if (!$this->isInClass()) {
return new ConstantStringType('');
}
$className = $this->getClassReflection()->getName();
$parts = explode('\\', $className);
if (count($parts) <= 1) {
return new ConstantStringType('');
}
return new ConstantStringType($parts[0]);
} elseif ($node instanceof Node\Scalar\MagicConst\Method) {
if ($this->isInAnonymousFunction()) {
return new ConstantStringType('{closure}');
}
$function = $this->getFunction();
if ($function === null) {
return new ConstantStringType('');
}
if ($function instanceof MethodReflection) {
return new ConstantStringType(
sprintf('%s::%s', $function->getDeclaringClass()->getName(), $function->getName())
);
}
return new ConstantStringType($function->getName());
} elseif ($node instanceof Node\Scalar\MagicConst\Function_) {
if ($this->isInAnonymousFunction()) {
return new ConstantStringType('{closure}');
}
$function = $this->getFunction();
if ($function === null) {
return new ConstantStringType('');
}
return new ConstantStringType($function->getName());
} elseif ($node instanceof Node\Scalar\MagicConst\Trait_) {
if (!$this->isInTrait()) {
return new ConstantStringType('');
}
return new ConstantStringType($this->getTraitReflection()->getName());
} elseif ($node instanceof Object_) {
$castToObject = static function (Type $type): Type {
if ((new ObjectWithoutClassType())->isSuperTypeOf($type)->yes()) {
return $type;
}
return new ObjectType('stdClass');
};
$exprType = $this->getType($node->expr);
if ($exprType instanceof UnionType) {
return TypeCombinator::union(...array_map($castToObject, $exprType->getTypes()));
}
return $castToObject($exprType);
} elseif ($node instanceof Unset_) {
return new NullType();
} elseif ($node instanceof Expr\PostInc || $node instanceof Expr\PostDec) {
return $this->getType($node->var);
} elseif ($node instanceof Expr\PreInc || $node instanceof Expr\PreDec) {
$varType = $this->getType($node->var);
if ($varType instanceof ConstantScalarType) {
$varValue = $varType->getValue();
if ($node instanceof Expr\PreInc) {
++$varValue;
} else {
--$varValue;
}
return $this->getTypeFromValue($varValue);
}
$stringType = new StringType();
if ($stringType->isSuperTypeOf($varType)->yes()) {
return $stringType;
}
return $varType->toNumber();
}
$exprString = $this->printer->prettyPrintExpr($node);
if (isset($this->moreSpecificTypes[$exprString])) {
return $this->moreSpecificTypes[$exprString]->getType();
}
if ($node instanceof ConstFetch) {
$constName = strtolower((string) $node->name);
if ($constName === 'true') {
return new \PHPStan\Type\Constant\ConstantBooleanType(true);
} elseif ($constName === 'false') {
return new \PHPStan\Type\Constant\ConstantBooleanType(false);
} elseif ($constName === 'null') {
return new NullType();
}
if ($this->broker->hasConstant($node->name, $this)) {
/** @var string $resolvedConstantName */
$resolvedConstantName = $this->broker->resolveConstantName($node->name, $this);
if ($resolvedConstantName === 'DIRECTORY_SEPARATOR') {
return new UnionType([
new ConstantStringType('/'),
new ConstantStringType('\\'),
]);
}
if ($resolvedConstantName === 'PATH_SEPARATOR') {
return new UnionType([
new ConstantStringType(':'),
new ConstantStringType(';'),
]);
}
if ($resolvedConstantName === 'PHP_EOL') {
return new UnionType([
new ConstantStringType("\n"),
new ConstantStringType("\r\n"),
]);
}
$constantType = $this->getTypeFromValue(constant($resolvedConstantName));
if ($constantType instanceof ConstantType && in_array($resolvedConstantName, $this->dynamicConstantNames, true)) {
return $constantType->generalize();
}
return $constantType;
}
return new ErrorType();
} elseif ($node instanceof Node\Expr\ClassConstFetch && $node->name instanceof Node\Identifier) {
$constantName = $node->name->name;
if ($node->class instanceof Name) {
$constantClass = (string) $node->class;
$constantClassType = new ObjectType($constantClass);
$namesToResolve = [
'self',
'parent',
];
if ($this->isInClass()) {
if ($this->getClassReflection()->isFinal()) {
$namesToResolve[] = 'static';
} elseif (strtolower($constantClass) === 'static') {
if (strtolower($constantName) === 'class') {
return new StringType();
}
return new MixedType();
}
}
if (in_array(strtolower($constantClass), $namesToResolve, true)) {
$resolvedName = $this->resolveName($node->class);
if ($resolvedName === 'parent' && strtolower($constantName) === 'class') {
return new StringType();
}
$constantClassType = new ObjectType($resolvedName);
}
} else {
$constantClassType = $this->getType($node->class);
}
if (strtolower($constantName) === 'class' && $constantClassType instanceof TypeWithClassName) {
return new ConstantStringType($constantClassType->getClassName());
}
if ($constantClassType->hasConstant($constantName)) {
$constant = $constantClassType->getConstant($constantName);
$constantType = $this->getTypeFromValue($constant->getValue());
$directClassNames = TypeUtils::getDirectClassNames($constantClassType);
if (
$constantType instanceof ConstantType &&
count($directClassNames) === 1 &&
in_array(sprintf('%s::%s', $this->broker->getClass($directClassNames[0])->getName(), $constantName), $this->dynamicConstantNames, true)
) {
return $constantType->generalize();
}
return $constantType;
}
return new ErrorType();
}
if ($node instanceof Expr\Ternary) {
if ($node->if === null) {
$conditionType = $this->filterByTruthyValue($node->cond, true)->getType($node->cond);
$booleanConditionType = $conditionType->toBoolean();
if ($booleanConditionType instanceof ConstantBooleanType) {
if ($booleanConditionType->getValue()) {
return $conditionType;
}
return $this->filterByFalseyValue($node->cond, true)->getType($node->else);
}
return TypeCombinator::union(
$conditionType,
$this->filterByFalseyValue($node->cond, true)->getType($node->else)
);
}
$booleanConditionType = $this->getType($node->cond)->toBoolean();
if ($booleanConditionType instanceof ConstantBooleanType) {
if ($booleanConditionType->getValue()) {
return $this->filterByTruthyValue($node->cond)->getType($node->if);
}
return $this->filterByFalseyValue($node->cond)->getType($node->else);
}
return TypeCombinator::union(
$this->filterByTruthyValue($node->cond)->getType($node->if),
$this->filterByFalseyValue($node->cond)->getType($node->else)
);
}
if ($node instanceof Variable && is_string($node->name)) {
if ($this->hasVariableType($node->name)->no()) {
return new ErrorType();
}
return $this->getVariableType($node->name);
}
if ($node instanceof Expr\ArrayDimFetch && $node->dim !== null) {
return $this->getTypeFromArrayDimFetch(
$node,
$this->getType($node->dim),
$this->getType($node->var)
);
}
if ($node instanceof MethodCall && $node->name instanceof Node\Identifier) {
$methodCalledOnType = $this->getType($node->var);
$referencedClasses = TypeUtils::getDirectClassNames($methodCalledOnType);
$resolvedTypes = [];
foreach ($referencedClasses as $referencedClass) {
if (!$this->broker->hasClass($referencedClass)) {
continue;
}
$methodClassReflection = $this->broker->getClass($referencedClass);
if (!$methodClassReflection->hasMethod($node->name->name)) {
if ($methodCalledOnType instanceof IntersectionType) {
continue;
}
return new ErrorType();
}
$methodReflection = $methodClassReflection->getMethod($node->name->name, $this);
foreach ($this->broker->getDynamicMethodReturnTypeExtensionsForClass($methodClassReflection->getName()) as $dynamicMethodReturnTypeExtension) {
if (!$dynamicMethodReturnTypeExtension->isMethodSupported($methodReflection)) {
continue;
}
$resolvedTypes[] = $dynamicMethodReturnTypeExtension->getTypeFromMethodCall($methodReflection, $node, $this);
}
}
if (count($resolvedTypes) > 0) {
return TypeCombinator::union(...$resolvedTypes);
}
if (!$methodCalledOnType->hasMethod($node->name->name)) {
return new ErrorType();
}
$methodReflection = $methodCalledOnType->getMethod($node->name->name, $this);
$methodReturnType = ParametersAcceptorSelector::selectFromArgs(
$this,
$node->args,
$methodReflection->getVariants()
)->getReturnType();
if ($methodReturnType instanceof StaticResolvableType) {
$calledOnThis = $this->getType($node->var) instanceof ThisType;
if ($calledOnThis) {
if ($this->isInClass()) {
return $methodReturnType->changeBaseClass($this->getClassReflection()->getName());
}
} elseif (count($referencedClasses) === 1) {
return $methodReturnType->resolveStatic($referencedClasses[0]);
}
}
return $methodReturnType;
}
if ($node instanceof Expr\StaticCall && $node->name instanceof Node\Identifier) {
if ($node->class instanceof Name) {
$calleeType = new ObjectType($this->resolveName($node->class));
} else {
$calleeType = $this->getType($node->class);
}
if (!$calleeType->hasMethod($node->name->name)) {
return new ErrorType();
}
$staticMethodReflection = $calleeType->getMethod($node->name->name, $this);
$referencedClasses = TypeUtils::getDirectClassNames($calleeType);
$resolvedTypes = [];
foreach ($referencedClasses as $referencedClass) {
if (!$this->broker->hasClass($referencedClass)) {
continue;
}
$staticMethodClassReflection = $this->broker->getClass($referencedClass);
foreach ($this->broker->getDynamicStaticMethodReturnTypeExtensionsForClass($staticMethodClassReflection->getName()) as $dynamicStaticMethodReturnTypeExtension) {
if (!$dynamicStaticMethodReturnTypeExtension->isStaticMethodSupported($staticMethodReflection)) {
continue;
}
$resolvedTypes[] = $dynamicStaticMethodReturnTypeExtension->getTypeFromStaticMethodCall($staticMethodReflection, $node, $this);
}
}
if (count($resolvedTypes) > 0) {
return TypeCombinator::union(...$resolvedTypes);
}
$staticMethodReturnType = ParametersAcceptorSelector::selectFromArgs(
$this,
$node->args,
$staticMethodReflection->getVariants()
)->getReturnType();
if ($staticMethodReturnType instanceof StaticResolvableType) {
if ($node->class instanceof Name) {
$nodeClassString = strtolower((string) $node->class);
if (in_array($nodeClassString, [
'self',
'static',
'parent',
], true) && $this->isInClass()) {
return $staticMethodReturnType->changeBaseClass($this->getClassReflection()->getName());
}
}
if (count($referencedClasses) === 1) {
return $staticMethodReturnType->resolveStatic($referencedClasses[0]);
}
}
return $staticMethodReturnType;
}
if ($node instanceof PropertyFetch && $node->name instanceof Node\Identifier) {
$propertyFetchedOnType = $this->getType($node->var);
if (!$propertyFetchedOnType->hasProperty($node->name->name)) {
return new ErrorType();
}
return $propertyFetchedOnType->getProperty($node->name->name, $this)->getType();
}
if ($node instanceof Expr\StaticPropertyFetch && $node->name instanceof Node\VarLikeIdentifier && $node->class instanceof Name) {
$staticPropertyHolderClass = $this->resolveName($node->class);
if ($this->broker->hasClass($staticPropertyHolderClass)) {
$staticPropertyClassReflection = $this->broker->getClass(
$staticPropertyHolderClass
);
if (!$staticPropertyClassReflection->hasProperty($node->name->name)) {
return new ErrorType();
}
return $staticPropertyClassReflection->getProperty($node->name->name, $this)->getType();
}
}
if ($node instanceof FuncCall) {
if ($node->name instanceof Expr) {
$calledOnType = $this->getType($node->name);
if ($calledOnType->isCallable()->no()) {
return new ErrorType();
}
return ParametersAcceptorSelector::selectFromArgs(
$this,
$node->args,
$calledOnType->getCallableParametersAcceptors($this)
)->getReturnType();
}
if (!$this->broker->hasFunction($node->name, $this)) {
return new ErrorType();
}
$functionReflection = $this->broker->getFunction($node->name, $this);
foreach ($this->broker->getDynamicFunctionReturnTypeExtensions() as $dynamicFunctionReturnTypeExtension) {
if (!$dynamicFunctionReturnTypeExtension->isFunctionSupported($functionReflection)) {
continue;
}
return $dynamicFunctionReturnTypeExtension->getTypeFromFunctionCall($functionReflection, $node, $this);
}
return ParametersAcceptorSelector::selectFromArgs(
$this,
$node->args,
$functionReflection->getVariants()
)->getReturnType();
}
return new MixedType();
}
protected function getTypeFromArrayDimFetch(
Expr\ArrayDimFetch $arrayDimFetch,
Type $offsetType,
Type $offsetAccessibleType
): Type
{
if ($arrayDimFetch->dim === null) {
throw new \PHPStan\ShouldNotHappenException();
}
if ((new ObjectType(\ArrayAccess::class))->isSuperTypeOf($offsetAccessibleType)->yes()) {
return $this->getType(
new MethodCall(
$arrayDimFetch->var,
new Node\Identifier('offsetGet'),
[
new Node\Arg($arrayDimFetch->dim),
]
)
);
}
return $offsetAccessibleType->getOffsetValueType($offsetType);
}
private function calculateFromScalars(Expr $node, ConstantScalarType $leftType, ConstantScalarType $rightType): Type
{
$leftValue = $leftType->getValue();
$rightValue = $rightType->getValue();
if ($node instanceof Node\Expr\BinaryOp\Spaceship) {
return $this->getTypeFromValue($leftValue <=> $rightValue);
}
$leftNumberType = $leftType->toNumber();
$rightNumberType = $rightType->toNumber();
if (TypeCombinator::union($leftNumberType, $rightNumberType) instanceof ErrorType) {
return new ErrorType();
}
if (!$leftNumberType instanceof ConstantScalarType || !$rightNumberType instanceof ConstantScalarType) {
throw new \PHPStan\ShouldNotHappenException();
}
/** @var float|int $leftNumberValue */
$leftNumberValue = $leftNumberType->getValue();
/** @var float|int $rightNumberValue */
$rightNumberValue = $rightNumberType->getValue();
if ($node instanceof Node\Expr\BinaryOp\Plus || $node instanceof Node\Expr\AssignOp\Plus) {
return $this->getTypeFromValue($leftNumberValue + $rightNumberValue);
}
if ($node instanceof Node\Expr\BinaryOp\Minus || $node instanceof Node\Expr\AssignOp\Minus) {
return $this->getTypeFromValue($leftNumberValue - $rightNumberValue);
}
if ($node instanceof Node\Expr\BinaryOp\Mul || $node instanceof Node\Expr\AssignOp\Mul) {
return $this->getTypeFromValue($leftNumberValue * $rightNumberValue);
}
if ($node instanceof Node\Expr\BinaryOp\Pow || $node instanceof Node\Expr\AssignOp\Pow) {
return $this->getTypeFromValue($leftNumberValue ** $rightNumberValue);
}
if ($node instanceof Node\Expr\BinaryOp\Div || $node instanceof Node\Expr\AssignOp\Div) {
return $this->getTypeFromValue($leftNumberValue / $rightNumberValue);
}
if ($node instanceof Node\Expr\BinaryOp\Mod || $node instanceof Node\Expr\AssignOp\Mod) {
return $this->getTypeFromValue($leftNumberValue % $rightNumberValue);
}
if ($node instanceof Expr\BinaryOp\ShiftLeft || $node instanceof Expr\AssignOp\ShiftLeft) {
return $this->getTypeFromValue($leftNumberValue << $rightNumberValue);
}
if ($node instanceof Expr\BinaryOp\ShiftRight || $node instanceof Expr\AssignOp\ShiftRight) {
return $this->getTypeFromValue($leftNumberValue >> $rightNumberValue);
}
if ($node instanceof Expr\BinaryOp\BitwiseAnd || $node instanceof Expr\AssignOp\BitwiseAnd) {
return $this->getTypeFromValue($leftNumberValue & $rightNumberValue);
}
if ($node instanceof Expr\BinaryOp\BitwiseOr || $node instanceof Expr\AssignOp\BitwiseOr) {
return $this->getTypeFromValue($leftNumberValue | $rightNumberValue);
}
if ($node instanceof Expr\BinaryOp\BitwiseXor || $node instanceof Expr\AssignOp\BitwiseXor) {
return $this->getTypeFromValue($leftNumberValue ^ $rightNumberValue);
}
return new MixedType();
}
public function resolveName(Name $name): string
{
$originalClass = (string) $name;
if ($this->isInClass()) {
if (in_array(strtolower($originalClass), [
'self',
'static',
], true)) {
return $this->getClassReflection()->getName();
} elseif ($originalClass === 'parent') {
$currentClassReflection = $this->getClassReflection();
if ($currentClassReflection->getParentClass() !== false) {
return $currentClassReflection->getParentClass()->getName();
}
}
}
return $originalClass;
}
/**
* @param mixed $value
*/
public function getTypeFromValue($value): Type
{
if (is_int($value)) {
return new ConstantIntegerType($value);
} elseif (is_float($value)) {
return new ConstantFloatType($value);
} elseif (is_bool($value)) {
return new ConstantBooleanType($value);
} elseif ($value === null) {
return new NullType();
} elseif (is_string($value)) {
return new ConstantStringType($value);
} elseif (is_array($value)) {
$arrayBuilder = ConstantArrayTypeBuilder::createEmpty();
foreach ($value as $k => $v) {
$arrayBuilder->setOffsetValueType($this->getTypeFromValue($k), $this->getTypeFromValue($v));
}
return $arrayBuilder->getArray();
}
return new MixedType();
}
public function isSpecified(Expr $node): bool
{
$exprString = $this->printer->prettyPrintExpr($node);
return isset($this->moreSpecificTypes[$exprString]);
}
public function enterClass(ClassReflection $classReflection): self
{
return $this->scopeFactory->create(
$this->context->enterClass($classReflection),
$this->isDeclareStrictTypes(),
null,
$this->getNamespace(),
[
'this' => VariableTypeHolder::createYes(new ThisType($classReflection->getName())),
]
);
}
public function enterTrait(ClassReflection $traitReflection): self
{
return $this->scopeFactory->create(
$this->context->enterTrait($traitReflection),
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$this->getVariableTypes(),
$this->moreSpecificTypes,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated()
);
}
/**
* @param Node\Stmt\ClassMethod $classMethod
* @param Type[] $phpDocParameterTypes
* @param Type|null $phpDocReturnType
* @param Type|null $throwType
* @param bool $isDeprecated
* @param bool $isInternal
* @param bool $isFinal
* @return self
*/
public function enterClassMethod(
Node\Stmt\ClassMethod $classMethod,
array $phpDocParameterTypes,
?Type $phpDocReturnType,
?Type $throwType,
bool $isDeprecated,
bool $isInternal,
bool $isFinal
): self
{
if (!$this->isInClass()) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->enterFunctionLike(
new PhpMethodFromParserNodeReflection(
$this->getClassReflection(),
$classMethod,
$this->getRealParameterTypes($classMethod),
$phpDocParameterTypes,
$classMethod->returnType !== null,
$this->getFunctionType($classMethod->returnType, $classMethod->returnType === null, false),
$phpDocReturnType,
$throwType,
$isDeprecated,
$isInternal,
$isFinal
)
);
}
/**
* @param Node\FunctionLike $functionLike
* @return Type[]
*/
private function getRealParameterTypes(Node\FunctionLike $functionLike): array
{
$realParameterTypes = [];
foreach ($functionLike->getParams() as $parameter) {
if (!$parameter->var instanceof Variable || !is_string($parameter->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
$realParameterTypes[$parameter->var->name] = $this->getFunctionType(
$parameter->type,
$this->isParameterValueNullable($parameter),
$parameter->variadic
);
}
return $realParameterTypes;
}
/**
* @param Node\Stmt\Function_ $function
* @param Type[] $phpDocParameterTypes
* @param Type|null $phpDocReturnType
* @param Type|null $throwType
* @param bool $isDeprecated
* @param bool $isInternal
* @param bool $isFinal
* @return self
*/
public function enterFunction(
Node\Stmt\Function_ $function,
array $phpDocParameterTypes,
?Type $phpDocReturnType,
?Type $throwType,
bool $isDeprecated,
bool $isInternal,
bool $isFinal
): self
{
return $this->enterFunctionLike(
new PhpFunctionFromParserNodeReflection(
$function,
$this->getRealParameterTypes($function),
$phpDocParameterTypes,
$function->returnType !== null,
$this->getFunctionType($function->returnType, $function->returnType === null, false),
$phpDocReturnType,
$throwType,
$isDeprecated,
$isInternal,
$isFinal
)
);
}
private function enterFunctionLike(
PhpFunctionFromParserNodeReflection $functionReflection
): self
{
$variableTypes = $this->getVariableTypes();
foreach (ParametersAcceptorSelector::selectSingle($functionReflection->getVariants())->getParameters() as $parameter) {
$variableTypes[$parameter->getName()] = VariableTypeHolder::createYes($parameter->getType());
}
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$functionReflection,
$this->getNamespace(),
$variableTypes,
[],
null,
null
);
}
public function enterNamespace(string $namespaceName): self
{
return $this->scopeFactory->create(
$this->context->beginFile(),
$this->isDeclareStrictTypes(),
null,
$namespaceName
);
}
public function enterClosureBind(?Type $thisType, string $scopeClass): self
{
$variableTypes = $this->getVariableTypes();
if ($thisType !== null) {
$variableTypes['this'] = VariableTypeHolder::createYes($thisType);
} else {
unset($variableTypes['this']);
}
if ($scopeClass === 'static' && $this->isInClass()) {
$scopeClass = $this->getClassReflection()->getName();
}
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$variableTypes,
$this->moreSpecificTypes,
$scopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated()
);
}
public function enterClosureCall(Type $thisType): self
{
$variableTypes = $this->getVariableTypes();
$variableTypes['this'] = VariableTypeHolder::createYes($thisType);
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$variableTypes,
$this->moreSpecificTypes,
$thisType instanceof TypeWithClassName ? $thisType->getClassName() : null,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated()
);
}
public function isInClosureBind(): bool
{
return $this->inClosureBindScopeClass !== null;
}
public function enterAnonymousClass(ClassReflection $anonymousClass): self
{
return $this->enterClass($anonymousClass);
}
public function enterAnonymousFunction(
Expr\Closure $closure
): self
{
$variableTypes = [];
foreach ($closure->params as $parameter) {
$isNullable = $this->isParameterValueNullable($parameter);
if (!$parameter->var instanceof Variable || !is_string($parameter->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
$variableTypes[$parameter->var->name] = VariableTypeHolder::createYes(
$this->getFunctionType($parameter->type, $isNullable, $parameter->variadic)
);
}
foreach ($closure->uses as $use) {
if (!is_string($use->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
if ($this->hasVariableType($use->var->name)->no()) {
if ($use->byRef) {
if ($this->isInExpressionAssign(new Variable($use->var->name))) {
$variableTypes[$use->var->name] = VariableTypeHolder::createYes(
$this->getType($closure)
);
continue;
}
$variableTypes[$use->var->name] = VariableTypeHolder::createYes(new NullType());
}
continue;
}
$variableTypes[$use->var->name] = VariableTypeHolder::createYes($this->getVariableType($use->var->name));
}
if ($this->hasVariableType('this')->yes()) {
$variableTypes['this'] = VariableTypeHolder::createYes($this->getVariableType('this'));
}
$returnType = $this->getFunctionType($closure->returnType, $closure->returnType === null, false);
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$variableTypes,
[],
$this->inClosureBindScopeClass,
$returnType,
$this->getInFunctionCall()
);
}
public function isParameterValueNullable(Node\Param $parameter): bool
{
if ($parameter->default instanceof ConstFetch) {
return strtolower((string) $parameter->default->name) === 'null';
}
return false;
}
/**
* @param \PhpParser\Node\Name|\PhpParser\Node\Identifier|\PhpParser\Node\NullableType|null $type
* @param bool $isNullable
* @param bool $isVariadic
* @return Type
*/
public function getFunctionType($type, bool $isNullable, bool $isVariadic): Type
{
if ($isNullable) {
return TypeCombinator::addNull(
$this->getFunctionType($type, false, $isVariadic)
);
}
if ($isVariadic) {
return new ArrayType(new IntegerType(), $this->getFunctionType(
$type,
false,
false
));
}
if ($type === null) {
return new MixedType();
} elseif ($type instanceof Name) {
$className = (string) $type;
$lowercasedClassName = strtolower($className);
if ($this->isInClass() && in_array($lowercasedClassName, ['self', 'static'], true)) {
$className = $this->getClassReflection()->getName();
} elseif (
$lowercasedClassName === 'parent'
) {
if ($this->isInClass() && $this->getClassReflection()->getParentClass() !== false) {
return new ObjectType($this->getClassReflection()->getParentClass()->getName());
}
return new NonexistentParentClassType();
}
return new ObjectType($className);
} elseif ($type instanceof Node\NullableType) {
return $this->getFunctionType($type->type, true, $isVariadic);
}
$type = $type->name;
if ($type === 'string') {
return new StringType();
} elseif ($type === 'int') {
return new IntegerType();
} elseif ($type === 'bool') {
return new BooleanType();
} elseif ($type === 'float') {
return new FloatType();
} elseif ($type === 'callable') {
return new CallableType();
} elseif ($type === 'array') {
return new ArrayType(new MixedType(), new MixedType());
} elseif ($type === 'iterable') {
return new IterableType(new MixedType(), new MixedType());
} elseif ($type === 'void') {
return new VoidType();
} elseif ($type === 'object') {
return new ObjectWithoutClassType();
}
return new MixedType();
}
public function enterForeach(Expr $iteratee, string $valueName, ?string $keyName): self
{
$iterateeType = $this->getType($iteratee);
$scope = $this->assignVariable($valueName, $iterateeType->getIterableValueType(), TrinaryLogic::createYes());
if ($keyName !== null) {
$scope = $scope->assignVariable($keyName, $iterateeType->getIterableKeyType(), TrinaryLogic::createYes());
}
return $scope;
}
/**
* @param \PhpParser\Node\Name[] $classes
* @param string $variableName
* @return Scope
*/
public function enterCatch(array $classes, string $variableName): self
{
$type = TypeCombinator::union(...array_map(static function (string $class): ObjectType {
return new ObjectType($class);
}, $classes));
return $this->assignVariable(
$variableName,
TypeCombinator::intersect($type, new ObjectType(\Throwable::class)),
TrinaryLogic::createYes()
);
}
/**
* @param \PhpParser\Node\Expr\FuncCall|\PhpParser\Node\Expr\MethodCall|\PhpParser\Node\Expr\StaticCall $functionCall
* @return self
*/
public function enterFunctionCall($functionCall): self
{
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$this->getVariableTypes(),
$this->moreSpecificTypes,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$functionCall,
$this->isNegated(),
$this->inFirstLevelStatement
);
}
public function enterExpressionAssign(Expr $expr): self
{
$currentlyAssignedExpressions = $this->currentlyAssignedExpressions;
$currentlyAssignedExpressions[] = $this->printer->prettyPrintExpr($expr);
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$this->getVariableTypes(),
$this->moreSpecificTypes,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated(),
$this->isInFirstLevelStatement(),
$currentlyAssignedExpressions
);
}
public function isInExpressionAssign(Expr $expr): bool
{
$exprString = $this->printer->prettyPrintExpr($expr);
return in_array($exprString, $this->currentlyAssignedExpressions, true);
}
public function assignVariable(
string $variableName,
Type $type,
TrinaryLogic $certainty
): self
{
if ($certainty->no()) {
throw new \PHPStan\ShouldNotHappenException();
}
$existingCertainty = $this->hasVariableType($variableName);
if (!$existingCertainty->no()) {
$certainty = $certainty->or($existingCertainty);
}
$variableTypes = $this->getVariableTypes();
$variableTypes[$variableName] = new VariableTypeHolder($type, $certainty);
$variableString = $this->printer->prettyPrintExpr(new Variable($variableName));
$moreSpecificTypeHolders = $this->moreSpecificTypes;
foreach (array_keys($moreSpecificTypeHolders) as $key) {
$matches = \Nette\Utils\Strings::match((string) $key, '#(\$[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*)#');
if ($matches === null) {
continue;
}
if ($matches[1] !== $variableString) {
continue;
}
unset($moreSpecificTypeHolders[$key]);
}
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$variableTypes,
$moreSpecificTypeHolders,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated(),
$this->inFirstLevelStatement,
$this->currentlyAssignedExpressions
);
}
public function unsetExpression(Expr $expr): self
{
if ($expr instanceof Variable && is_string($expr->name)) {
if ($this->hasVariableType($expr->name)->no()) {
return $this;
}
$variableTypes = $this->getVariableTypes();
unset($variableTypes[$expr->name]);
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$variableTypes,
$this->moreSpecificTypes,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated(),
$this->inFirstLevelStatement
);
} elseif ($expr instanceof Expr\ArrayDimFetch && $expr->dim !== null) {
$constantArrays = TypeUtils::getConstantArrays($this->getType($expr->var));
if (count($constantArrays) > 0) {
$unsetArrays = [];
$dimType = $this->getType($expr->dim);
foreach ($constantArrays as $constantArray) {
$unsetArrays[] = $constantArray->unsetOffset($dimType);
}
return $this->specifyExpressionType(
$expr->var,
TypeCombinator::union(...$unsetArrays)
);
}
}
return $this;
}
public function intersectVariables(Scope $otherScope): self
{
$ourVariableTypeHolders = $this->getVariableTypes();
$theirVariableTypeHolders = $otherScope->getVariableTypes();
$intersectedVariableTypeHolders = [];
foreach ($theirVariableTypeHolders as $name => $variableTypeHolder) {
if (isset($ourVariableTypeHolders[$name])) {
$intersectedVariableTypeHolders[$name] = $ourVariableTypeHolders[$name]->and($variableTypeHolder);
} else {
$intersectedVariableTypeHolders[$name] = VariableTypeHolder::createMaybe($variableTypeHolder->getType());
}
}
foreach ($ourVariableTypeHolders as $name => $variableTypeHolder) {
$variableNode = new Variable($name);
if ($otherScope->isSpecified($variableNode)) {
$intersectedVariableTypeHolders[$name] = VariableTypeHolder::createYes(
TypeCombinator::union(
$otherScope->getType($variableNode),
$variableTypeHolder->getType()
)
);
continue;
}
if (isset($theirVariableTypeHolders[$name])) {
continue;
}
$intersectedVariableTypeHolders[$name] = VariableTypeHolder::createMaybe($variableTypeHolder->getType());
}
$ourSpecifiedTypeHolders = $this->moreSpecificTypes;
$theirSpecifiedTypeHolders = $otherScope->moreSpecificTypes;
$intersectedSpecifiedTypes = [];
foreach ($theirSpecifiedTypeHolders as $exprString => $theirSpecifiedTypeHolder) {
$matches = \Nette\Utils\Strings::match((string) $exprString, '#^\$([a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*)$#');
if ($matches !== null) {
continue;
}
if (isset($ourSpecifiedTypeHolders[$exprString])) {
$intersectedSpecifiedTypes[$exprString] = $ourSpecifiedTypeHolders[$exprString]->and($theirSpecifiedTypeHolder);
} else {
$intersectedSpecifiedTypes[$exprString] = VariableTypeHolder::createMaybe($theirSpecifiedTypeHolder->getType());
}
}
foreach ($this->moreSpecificTypes as $exprString => $specificTypeHolder) {
$matches = \Nette\Utils\Strings::match((string) $exprString, '#^\$([a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*)$#');
if ($matches !== null) {
continue;
}
if (isset($otherScope->moreSpecificTypes[$exprString])) {
$intersectedSpecifiedTypes[$exprString] = VariableTypeHolder::createYes(
TypeCombinator::union(
$otherScope->moreSpecificTypes[$exprString]->getType(),
$specificTypeHolder->getType()
)
);
continue;
}
if (isset($theirVariableTypeHolders[$exprString])) {
continue;
}
$intersectedSpecifiedTypes[$exprString] = VariableTypeHolder::createMaybe($specificTypeHolder->getType());
}
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$intersectedVariableTypeHolders,
$intersectedSpecifiedTypes,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated(),
$this->inFirstLevelStatement
);
}
public function createIntersectedScope(self $otherScope): self
{
$variableTypes = [];
foreach ($otherScope->getVariableTypes() as $name => $variableTypeHolder) {
$variableTypes[$name] = $variableTypeHolder;
}
$specifiedTypes = [];
foreach ($otherScope->moreSpecificTypes as $exprString => $specificTypeHolder) {
$matches = \Nette\Utils\Strings::match((string) $exprString, '#^\$([a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*)$#');
if ($matches !== null) {
$variableTypes[$matches[1]] = $specificTypeHolder;
continue;
}
$specifiedTypes[$exprString] = $specificTypeHolder;
}
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$variableTypes,
$specifiedTypes,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated(),
$this->inFirstLevelStatement
);
}
public function mergeWithIntersectedScope(self $intersectedScope): self
{
$variableTypeHolders = $this->variableTypes;
$specifiedTypeHolders = $this->moreSpecificTypes;
foreach ($intersectedScope->getVariableTypes() as $name => $theirVariableTypeHolder) {
if (isset($variableTypeHolders[$name])) {
$type = $theirVariableTypeHolder->getType();
if ($theirVariableTypeHolder->getCertainty()->maybe()) {
$type = TypeCombinator::union($type, $variableTypeHolders[$name]->getType());
}
$theirVariableTypeHolder = new VariableTypeHolder(
$type,
$theirVariableTypeHolder->getCertainty()->or($variableTypeHolders[$name]->getCertainty())
);
}
$variableTypeHolders[$name] = $theirVariableTypeHolder;
$exprString = $this->printer->prettyPrintExpr(new Variable($name));
unset($specifiedTypeHolders[$exprString]);
}
foreach ($intersectedScope->moreSpecificTypes as $exprString => $theirTypeHolder) {
if (isset($specifiedTypeHolders[$exprString])) {
$type = $theirTypeHolder->getType();
if ($theirTypeHolder->getCertainty()->maybe()) {
$type = TypeCombinator::union($type, $specifiedTypeHolders[$exprString]->getType());
}
$theirTypeHolder = new VariableTypeHolder(
$type,
$theirTypeHolder->getCertainty()->or($specifiedTypeHolders[$exprString]->getCertainty())
);
}
if (!$theirTypeHolder->getCertainty()->yes()) {
continue;
}
$specifiedTypeHolders[$exprString] = $theirTypeHolder;
}
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$variableTypeHolders,
$specifiedTypeHolders,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated(),
$this->inFirstLevelStatement
);
}
public function removeSpecified(self $initialScope): self
{
$variableTypeHolders = $this->variableTypes;
foreach ($variableTypeHolders as $name => $holder) {
if (!$holder->getCertainty()->yes()) {
continue;
}
$node = new Variable($name);
if ($this->isSpecified($node) && !$initialScope->hasVariableType($name)->no()) {
$variableTypeHolders[$name] = VariableTypeHolder::createYes(TypeCombinator::remove($initialScope->getVariableType($name), $this->getType($node)));
continue;
}
}
$moreSpecificTypeHolders = $this->moreSpecificTypes;
foreach (array_keys($moreSpecificTypeHolders) as $exprString) {
if (isset($initialScope->moreSpecificTypes[$exprString])) {
continue;
}
unset($moreSpecificTypeHolders[$exprString]);
}
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$variableTypeHolders,
$moreSpecificTypeHolders,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated(),
$this->inFirstLevelStatement
);
}
public function removeVariables(self $otherScope, bool $all): self
{
$ourVariableTypeHolders = $this->getVariableTypes();
foreach ($otherScope->getVariableTypes() as $name => $theirVariableTypeHolder) {
if ($all) {
if (
isset($ourVariableTypeHolders[$name])
&& $ourVariableTypeHolders[$name]->getCertainty()->equals($theirVariableTypeHolder->getCertainty())
) {
unset($ourVariableTypeHolders[$name]);
}
} else {
if (
isset($ourVariableTypeHolders[$name])
&& $theirVariableTypeHolder->getType()->equals($ourVariableTypeHolders[$name]->getType())
&& $ourVariableTypeHolders[$name]->getCertainty()->equals($theirVariableTypeHolder->getCertainty())
) {
unset($ourVariableTypeHolders[$name]);
}
}
}
$ourTypeHolders = $this->moreSpecificTypes;
foreach ($otherScope->moreSpecificTypes as $exprString => $theirTypeHolder) {
if ($all) {
if (
isset($ourTypeHolders[$exprString])
&& $ourTypeHolders[$exprString]->getCertainty()->equals($theirTypeHolder->getCertainty())
) {
unset($ourVariableTypeHolders[$exprString]);
}
} else {
if (
isset($ourTypeHolders[$exprString])
&& $theirTypeHolder->getType()->equals($ourTypeHolders[$exprString]->getType())
&& $ourTypeHolders[$exprString]->getCertainty()->equals($theirTypeHolder->getCertainty())
) {
unset($ourVariableTypeHolders[$exprString]);
}
}
}
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$ourVariableTypeHolders,
$ourTypeHolders,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated(),
$this->inFirstLevelStatement
);
}
public function specifyExpressionType(Expr $expr, Type $type): self
{
if ($expr instanceof Node\Scalar || $expr instanceof Array_) {
return $this;
}
$exprString = $this->printer->prettyPrintExpr($expr);
$scope = $this;
if ($expr instanceof Variable && is_string($expr->name)) {
$variableName = $expr->name;
$variableTypes = $this->getVariableTypes();
$variableTypes[$variableName] = VariableTypeHolder::createYes($type);
$moreSpecificTypes = $this->moreSpecificTypes;
$moreSpecificTypes[$exprString] = $variableTypes[$variableName];
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$variableTypes,
$moreSpecificTypes,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated(),
$this->inFirstLevelStatement
);
} elseif ($expr instanceof Expr\ArrayDimFetch && $expr->dim !== null) {
$constantArrays = TypeUtils::getConstantArrays($this->getType($expr->var));
if (count($constantArrays) > 0) {
$setArrays = [];
$dimType = $this->getType($expr->dim);
foreach ($constantArrays as $constantArray) {
$setArrays[] = $constantArray->setOffsetValueType($dimType, $type);
}
$scope = $this->specifyExpressionType(
$expr->var,
TypeCombinator::union(...$setArrays)
);
}
}
return $scope->addMoreSpecificTypes([
$exprString => $type,
]);
}
public function unspecifyExpressionType(Expr $expr): self
{
$exprString = $this->printer->prettyPrintExpr($expr);
$moreSpecificTypeHolders = $this->moreSpecificTypes;
if (isset($moreSpecificTypeHolders[$exprString]) && !$moreSpecificTypeHolders[$exprString]->getType() instanceof MixedType) {
unset($moreSpecificTypeHolders[$exprString]);
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$this->getVariableTypes(),
$moreSpecificTypeHolders,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated(),
$this->inFirstLevelStatement
);
}
return $this;
}
public function removeTypeFromExpression(Expr $expr, Type $type): self
{
return $this->specifyExpressionType(
$expr,
TypeCombinator::remove($this->getType($expr), $type)
);
}
public function filterByTruthyValue(Expr $expr, bool $defaultHandleFunctions = false): self
{
$specifiedTypes = $this->typeSpecifier->specifyTypesInCondition($this, $expr, TypeSpecifierContext::createTruthy(), $defaultHandleFunctions);
return $this->filterBySpecifiedTypes($specifiedTypes);
}
public function filterByFalseyValue(Expr $expr, bool $defaultHandleFunctions = false): self
{
$specifiedTypes = $this->typeSpecifier->specifyTypesInCondition($this, $expr, TypeSpecifierContext::createFalsey(), $defaultHandleFunctions);
return $this->filterBySpecifiedTypes($specifiedTypes);
}
public function filterBySpecifiedTypes(SpecifiedTypes $specifiedTypes): self
{
$typeSpecifications = [];
foreach ($specifiedTypes->getSureTypes() as $exprString => [$expr, $type]) {
$typeSpecifications[] = [
'sure' => true,
'exprString' => $exprString,
'expr' => $expr,
'type' => $type,
];
}
foreach ($specifiedTypes->getSureNotTypes() as $exprString => [$expr, $type]) {
$typeSpecifications[] = [
'sure' => false,
'exprString' => $exprString,
'expr' => $expr,
'type' => $type,
];
}
usort($typeSpecifications, static function (array $a, array $b): int {
$length = strlen((string) $a['exprString']) - strlen((string) $b['exprString']);
if ($length !== 0) {
return $length;
}
return $b['sure'] - $a['sure'];
});
$scope = $this;
foreach ($typeSpecifications as $typeSpecification) {
$expr = $typeSpecification['expr'];
$type = $typeSpecification['type'];
if ($typeSpecification['sure']) {
$type = TypeCombinator::intersect($type, $this->getType($expr));
$scope = $scope->specifyExpressionType($expr, $type);
} else {
$scope = $scope->removeTypeFromExpression($expr, $type);
}
}
return $scope;
}
public function specifyFetchedStaticPropertyFromIsset(Expr\StaticPropertyFetch $expr): self
{
$exprString = $this->printer->prettyPrintExpr($expr);
return $this->addMoreSpecificTypes([
$exprString => new MixedType(),
]);
}
public function enterNegation(): self
{
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$this->getVariableTypes(),
$this->moreSpecificTypes,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
!$this->isNegated(),
$this->inFirstLevelStatement
);
}
public function enterFirstLevelStatements(): self
{
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$this->getVariableTypes(),
$this->moreSpecificTypes,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated(),
true,
$this->currentlyAssignedExpressions
);
}
public function exitFirstLevelStatements(): self
{
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$this->getVariableTypes(),
$this->moreSpecificTypes,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated(),
false,
$this->currentlyAssignedExpressions
);
}
public function isInFirstLevelStatement(): bool
{
return $this->inFirstLevelStatement;
}
public function isNegated(): bool
{
return $this->negated;
}
/**
* @param Type[] $types
* @return self
*/
private function addMoreSpecificTypes(array $types): self
{
$moreSpecificTypeHolders = $this->moreSpecificTypes;
foreach ($types as $exprString => $type) {
$moreSpecificTypeHolders[$exprString] = VariableTypeHolder::createYes($type);
}
return $this->scopeFactory->create(
$this->context,
$this->isDeclareStrictTypes(),
$this->getFunction(),
$this->getNamespace(),
$this->getVariableTypes(),
$moreSpecificTypeHolders,
$this->inClosureBindScopeClass,
$this->getAnonymousFunctionReturnType(),
$this->getInFunctionCall(),
$this->isNegated(),
$this->inFirstLevelStatement
);
}
public function canAccessProperty(PropertyReflection $propertyReflection): bool
{
return $this->canAccessClassMember($propertyReflection);
}
public function canCallMethod(MethodReflection $methodReflection): bool
{
if ($this->canAccessClassMember($methodReflection)) {
return true;
}
return $this->canAccessClassMember($methodReflection->getPrototype());
}
public function canAccessConstant(ConstantReflection $constantReflection): bool
{
return $this->canAccessClassMember($constantReflection);
}
private function canAccessClassMember(ClassMemberReflection $classMemberReflection): bool
{
if ($classMemberReflection->isPublic()) {
return true;
}
if ($this->inClosureBindScopeClass !== null && $this->broker->hasClass($this->inClosureBindScopeClass)) {
$currentClassReflection = $this->broker->getClass($this->inClosureBindScopeClass);
} elseif ($this->isInClass()) {
$currentClassReflection = $this->getClassReflection();
} else {
return false;
}
$classReflectionName = $classMemberReflection->getDeclaringClass()->getName();
if ($classMemberReflection->isPrivate()) {
return $currentClassReflection->getName() === $classReflectionName;
}
// protected
if (
$currentClassReflection->getName() === $classReflectionName
|| $currentClassReflection->isSubclassOf($classReflectionName)
) {
return true;
}
return $classMemberReflection->getDeclaringClass()->isSubclassOf($currentClassReflection->getName());
}
/**
* @return string[]
*/
public function debug(): array
{
$descriptions = [];
foreach ($this->getVariableTypes() as $name => $variableTypeHolder) {
$key = sprintf('$%s (%s)', $name, $variableTypeHolder->getCertainty()->describe());
$descriptions[$key] = $variableTypeHolder->getType()->describe(VerbosityLevel::value());
}
foreach ($this->moreSpecificTypes as $exprString => $typeHolder) {
$key = sprintf(
'%s-specified (%s)',
$exprString,
$typeHolder->getCertainty()->describe()
);
$descriptions[$key] = $typeHolder->getType()->describe(VerbosityLevel::value());
}
return $descriptions;
}
}
src/Analyser/TypeSpecifierContext.php 0000666 00000003626 13436755504 0013771 0 ustar 00 value = $value;
}
private static function create(?int $value): self
{
self::$registry[$value] = self::$registry[$value] ?? new self($value);
return self::$registry[$value];
}
public static function createTrue(): self
{
return self::create(self::CONTEXT_TRUE);
}
public static function createTruthy(): self
{
return self::create(self::CONTEXT_TRUTHY);
}
public static function createFalse(): self
{
return self::create(self::CONTEXT_FALSE);
}
public static function createFalsey(): self
{
return self::create(self::CONTEXT_FALSEY);
}
public static function createNull(): self
{
return self::create(null);
}
public function negate(): self
{
if ($this->value === null) {
throw new \PHPStan\ShouldNotHappenException();
}
return self::create(~$this->value);
}
public function true(): bool
{
return $this->value !== null && (bool) ($this->value & self::CONTEXT_TRUE);
}
public function truthy(): bool
{
return $this->value !== null && (bool) ($this->value & self::CONTEXT_TRUTHY);
}
public function false(): bool
{
return $this->value !== null && (bool) ($this->value & self::CONTEXT_FALSE);
}
public function falsey(): bool
{
return $this->value !== null && (bool) ($this->value & self::CONTEXT_FALSEY);
}
public function null(): bool
{
return $this->value === null;
}
}
src/Analyser/SpecifiedTypes.php 0000666 00000004167 13436755504 0012572 0 ustar 00 sureTypes = $sureTypes;
$this->sureNotTypes = $sureNotTypes;
}
/**
* @return mixed[]
*/
public function getSureTypes(): array
{
return $this->sureTypes;
}
/**
* @return mixed[]
*/
public function getSureNotTypes(): array
{
return $this->sureNotTypes;
}
public function intersectWith(SpecifiedTypes $other): self
{
$sureTypeUnion = [];
$sureNotTypeUnion = [];
foreach ($this->sureTypes as $exprString => [$exprNode, $type]) {
if (!isset($other->sureTypes[$exprString])) {
continue;
}
$sureTypeUnion[$exprString] = [
$exprNode,
TypeCombinator::union($type, $other->sureTypes[$exprString][1]),
];
}
foreach ($this->sureNotTypes as $exprString => [$exprNode, $type]) {
if (!isset($other->sureNotTypes[$exprString])) {
continue;
}
$sureNotTypeUnion[$exprString] = [
$exprNode,
TypeCombinator::intersect($type, $other->sureNotTypes[$exprString][1]),
];
}
return new self($sureTypeUnion, $sureNotTypeUnion);
}
public function unionWith(SpecifiedTypes $other): self
{
$sureTypeUnion = $this->sureTypes + $other->sureTypes;
$sureNotTypeUnion = $this->sureNotTypes + $other->sureNotTypes;
foreach ($this->sureTypes as $exprString => [$exprNode, $type]) {
if (!isset($other->sureTypes[$exprString])) {
continue;
}
$sureTypeUnion[$exprString] = [
$exprNode,
TypeCombinator::intersect($type, $other->sureTypes[$exprString][1]),
];
}
foreach ($this->sureNotTypes as $exprString => [$exprNode, $type]) {
if (!isset($other->sureNotTypes[$exprString])) {
continue;
}
$sureNotTypeUnion[$exprString] = [
$exprNode,
TypeCombinator::union($type, $other->sureNotTypes[$exprString][1]),
];
}
return new self($sureTypeUnion, $sureNotTypeUnion);
}
}
src/Analyser/ScopeFactory.php 0000666 00000005347 13436755504 0012254 0 ustar 00 scopeClass = $scopeClass;
$this->broker = $broker;
$this->printer = $printer;
$this->typeSpecifier = $typeSpecifier;
$this->dynamicConstantNames = $dynamicConstantNames;
}
/**
* @param \PHPStan\Analyser\ScopeContext $context
* @param bool $declareStrictTypes
* @param \PHPStan\Reflection\FunctionReflection|\PHPStan\Reflection\MethodReflection|null $function
* @param string|null $namespace
* @param \PHPStan\Analyser\VariableTypeHolder[] $variablesTypes
* @param \PHPStan\Analyser\VariableTypeHolder[] $moreSpecificTypes
* @param string|null $inClosureBindScopeClass
* @param \PHPStan\Type\Type|null $inAnonymousFunctionReturnType
* @param \PhpParser\Node\Expr\FuncCall|\PhpParser\Node\Expr\MethodCall|\PhpParser\Node\Expr\StaticCall|null $inFunctionCall
* @param bool $negated
* @param bool $inFirstLevelStatement
* @param string[] $currentlyAssignedExpressions
*
* @return Scope
*/
public function create(
ScopeContext $context,
bool $declareStrictTypes = false,
$function = null,
?string $namespace = null,
array $variablesTypes = [],
array $moreSpecificTypes = [],
?string $inClosureBindScopeClass = null,
?Type $inAnonymousFunctionReturnType = null,
?Expr $inFunctionCall = null,
bool $negated = false,
bool $inFirstLevelStatement = true,
array $currentlyAssignedExpressions = []
): Scope
{
$scopeClass = $this->scopeClass;
if (!is_a($scopeClass, Scope::class, true)) {
throw new \PHPStan\ShouldNotHappenException();
}
return new $scopeClass(
$this,
$this->broker,
$this->printer,
$this->typeSpecifier,
$context,
$declareStrictTypes,
$function,
$namespace,
$variablesTypes,
$moreSpecificTypes,
$inClosureBindScopeClass,
$inAnonymousFunctionReturnType,
$inFunctionCall,
$negated,
$inFirstLevelStatement,
$currentlyAssignedExpressions,
$this->dynamicConstantNames
);
}
}
src/Analyser/UndefinedVariableException.php 0000666 00000001123 13436755504 0015065 0 ustar 00 scope = $scope;
$this->variableName = $variableName;
}
public function getScope(): Scope
{
return $this->scope;
}
public function getVariableName(): string
{
return $this->variableName;
}
}
src/ShouldNotHappenException.php 0000666 00000000335 13436755504 0013017 0 ustar 00 value = $value;
}
public static function createYes(): self
{
return self::create(self::YES);
}
public static function createNo(): self
{
return self::create(self::NO);
}
public static function createMaybe(): self
{
return self::create(self::MAYBE);
}
public static function createFromBoolean(bool $value): self
{
return self::create($value ? self::YES : self::NO);
}
private static function create(int $value): self
{
self::$registry[$value] = self::$registry[$value] ?? new self($value);
return self::$registry[$value];
}
public function yes(): bool
{
return $this->value === self::YES;
}
public function maybe(): bool
{
return $this->value === self::MAYBE;
}
public function no(): bool
{
return $this->value === self::NO;
}
public function toBooleanType(): BooleanType
{
if ($this->value === self::MAYBE) {
return new BooleanType();
}
return new ConstantBooleanType($this->value === self::YES);
}
public function and(self ...$operands): self
{
$operandValues = array_column($operands, 'value');
$operandValues[] = $this->value;
return self::create(min($operandValues));
}
public function or(self ...$operands): self
{
$operandValues = array_column($operands, 'value');
$operandValues[] = $this->value;
return self::create(max($operandValues));
}
public static function extremeIdentity(self ...$operands): self
{
$operandValues = array_column($operands, 'value');
$min = min($operandValues);
$max = max($operandValues);
return self::create($min === $max ? $min : self::MAYBE);
}
public static function maxMin(self ...$operands): self
{
$operandValues = array_column($operands, 'value');
return self::create(max($operandValues) > 0 ? max($operandValues) : min($operandValues));
}
public function negate(): self
{
return self::create(-$this->value);
}
public function equals(self $other): bool
{
return $this === $other;
}
public function compareTo(self $other): ?self
{
if ($this->value > $other->value) {
return $this;
} elseif ($other->value > $this->value) {
return $other;
}
return null;
}
public function describe(): string
{
static $labels = [
self::NO => 'No',
self::MAYBE => 'Maybe',
self::YES => 'Yes',
];
return $labels[$this->value];
}
/**
* @param mixed[] $properties
* @return self
*/
public static function __set_state(array $properties): self
{
return self::create($properties['value']);
}
}
src/Broker/FunctionNotFoundException.php 0000666 00000000775 13436755504 0014442 0 ustar 00 functionName = $functionName;
}
public function getFunctionName(): string
{
return $this->functionName;
}
}
src/Broker/AnonymousClassNameHelper.php 0000666 00000001622 13436755504 0014230 0 ustar 00 fileHelper = $fileHelper;
$this->relativePathHelper = $relativePathHelper;
}
public function getAnonymousClassName(
\PhpParser\Node\Expr\New_ $node,
string $filename
): string
{
if (!$node->class instanceof \PhpParser\Node\Stmt\Class_) {
throw new \PHPStan\ShouldNotHappenException();
}
$filename = $this->relativePathHelper->getRelativePath(
$this->fileHelper->normalizePath($filename)
);
return sprintf(
'AnonymousClass%s',
md5(sprintf('%s:%s', $filename, $node->class->getLine()))
);
}
}
src/Broker/Broker.php 0000666 00000046427 13436755504 0010551 0 ustar 00 propertiesClassReflectionExtensions = $propertiesClassReflectionExtensions;
$this->methodsClassReflectionExtensions = $methodsClassReflectionExtensions;
foreach (array_merge($propertiesClassReflectionExtensions, $methodsClassReflectionExtensions, $dynamicMethodReturnTypeExtensions, $dynamicStaticMethodReturnTypeExtensions, $dynamicFunctionReturnTypeExtensions) as $extension) {
if (!($extension instanceof BrokerAwareExtension)) {
continue;
}
$extension->setBroker($this);
}
$this->dynamicMethodReturnTypeExtensions = $dynamicMethodReturnTypeExtensions;
$this->dynamicStaticMethodReturnTypeExtensions = $dynamicStaticMethodReturnTypeExtensions;
foreach ($dynamicFunctionReturnTypeExtensions as $functionReturnTypeExtension) {
$this->dynamicFunctionReturnTypeExtensions[] = $functionReturnTypeExtension;
}
$this->functionReflectionFactory = $functionReflectionFactory;
$this->fileTypeMapper = $fileTypeMapper;
$this->signatureMapProvider = $signatureMapProvider;
$this->printer = $printer;
$this->anonymousClassNameHelper = $anonymousClassNameHelper;
$this->parser = $parser;
$this->relativePathHelper = $relativePathHelper;
$this->universalObjectCratesClasses = $universalObjectCratesClasses;
}
public static function registerInstance(Broker $broker): void
{
self::$instance = $broker;
}
public static function getInstance(): self
{
if (self::$instance === null) {
throw new \PHPStan\ShouldNotHappenException();
}
return self::$instance;
}
/**
* @return string[]
*/
public function getUniversalObjectCratesClasses(): array
{
return $this->universalObjectCratesClasses;
}
/**
* @param string $className
* @return \PHPStan\Type\DynamicMethodReturnTypeExtension[]
*/
public function getDynamicMethodReturnTypeExtensionsForClass(string $className): array
{
if ($this->dynamicMethodReturnTypeExtensionsByClass === null) {
$byClass = [];
foreach ($this->dynamicMethodReturnTypeExtensions as $extension) {
$byClass[$extension->getClass()][] = $extension;
}
$this->dynamicMethodReturnTypeExtensionsByClass = $byClass;
}
return $this->getDynamicExtensionsForType($this->dynamicMethodReturnTypeExtensionsByClass, $className);
}
/**
* @param string $className
* @return \PHPStan\Type\DynamicStaticMethodReturnTypeExtension[]
*/
public function getDynamicStaticMethodReturnTypeExtensionsForClass(string $className): array
{
if ($this->dynamicStaticMethodReturnTypeExtensionsByClass === null) {
$byClass = [];
foreach ($this->dynamicStaticMethodReturnTypeExtensions as $extension) {
$byClass[$extension->getClass()][] = $extension;
}
$this->dynamicStaticMethodReturnTypeExtensionsByClass = $byClass;
}
return $this->getDynamicExtensionsForType($this->dynamicStaticMethodReturnTypeExtensionsByClass, $className);
}
/**
* @return \PHPStan\Type\DynamicFunctionReturnTypeExtension[]
*/
public function getDynamicFunctionReturnTypeExtensions(): array
{
return $this->dynamicFunctionReturnTypeExtensions;
}
/**
* @param \PHPStan\Type\DynamicMethodReturnTypeExtension[][]|\PHPStan\Type\DynamicStaticMethodReturnTypeExtension[][] $extensions
* @param string $className
* @return mixed[]
*/
private function getDynamicExtensionsForType(array $extensions, string $className): array
{
$extensionsForClass = [];
$class = $this->getClass($className);
foreach (array_merge([$className], $class->getParentClassesNames(), $class->getNativeReflection()->getInterfaceNames()) as $extensionClassName) {
if (!isset($extensions[$extensionClassName])) {
continue;
}
$extensionsForClass = array_merge($extensionsForClass, $extensions[$extensionClassName]);
}
return $extensionsForClass;
}
public function getClass(string $className): \PHPStan\Reflection\ClassReflection
{
if (!$this->hasClass($className)) {
throw new \PHPStan\Broker\ClassNotFoundException($className);
}
if (isset(self::$anonymousClasses[$className])) {
return self::$anonymousClasses[$className];
}
if (!isset($this->classReflections[$className])) {
$reflectionClass = new ReflectionClass($className);
$filename = null;
if ($reflectionClass->getFileName() !== false) {
$filename = $reflectionClass->getFileName();
}
$classReflection = $this->getClassFromReflection(
$reflectionClass,
$reflectionClass->getName(),
$reflectionClass->isAnonymous() ? $filename : null
);
$this->classReflections[$className] = $classReflection;
if ($className !== $reflectionClass->getName()) {
// class alias optimization
$this->classReflections[$reflectionClass->getName()] = $classReflection;
}
}
return $this->classReflections[$className];
}
public function getAnonymousClassReflection(
\PhpParser\Node\Expr\New_ $node,
Scope $scope
): ClassReflection
{
if (!$node->class instanceof \PhpParser\Node\Stmt\Class_) {
throw new \PHPStan\ShouldNotHappenException();
}
if (!$scope->isInTrait()) {
$scopeFile = $scope->getFile();
} else {
$scopeFile = $scope->getTraitReflection()->getFileName();
if ($scopeFile === false) {
$scopeFile = $scope->getFile();
}
}
$filename = $this->relativePathHelper->getRelativePath($scopeFile);
$className = $this->anonymousClassNameHelper->getAnonymousClassName(
$node,
$filename
);
if (isset(self::$anonymousClasses[$className])) {
return self::$anonymousClasses[$className];
}
$classNode = $node->class;
$classNode->name = new \PhpParser\Node\Identifier($className);
eval($this->printer->prettyPrint([$classNode]));
unset($classNode);
self::$anonymousClasses[$className] = $this->getClassFromReflection(
new \ReflectionClass('\\' . $className),
sprintf('class@anonymous/%s:%s', $filename, $node->getLine()),
$scopeFile
);
$this->classReflections[$className] = self::$anonymousClasses[$className];
return self::$anonymousClasses[$className];
}
public function getClassFromReflection(\ReflectionClass $reflectionClass, string $displayName, ?string $anonymousFilename): ClassReflection
{
$className = $reflectionClass->getName();
if (!isset($this->classReflections[$className])) {
$classReflection = new ClassReflection(
$this,
$this->fileTypeMapper,
$this->propertiesClassReflectionExtensions,
$this->methodsClassReflectionExtensions,
$displayName,
$reflectionClass,
$anonymousFilename
);
$this->classReflections[$className] = $classReflection;
}
return $this->classReflections[$className];
}
public function hasClass(string $className): bool
{
if (isset($this->hasClassCache[$className])) {
return $this->hasClassCache[$className];
}
spl_autoload_register($autoloader = function (string $autoloadedClassName) use ($className): void {
if ($autoloadedClassName !== $className && !$this->isExistsCheckCall()) {
throw new \PHPStan\Broker\ClassAutoloadingException($autoloadedClassName);
}
});
try {
return $this->hasClassCache[$className] = class_exists($className) || interface_exists($className) || trait_exists($className);
} catch (\PHPStan\Broker\ClassAutoloadingException $e) {
throw $e;
} catch (\Throwable $t) {
throw new \PHPStan\Broker\ClassAutoloadingException(
$className,
$t
);
} finally {
spl_autoload_unregister($autoloader);
}
}
public function getFunction(\PhpParser\Node\Name $nameNode, ?Scope $scope): \PHPStan\Reflection\FunctionReflection
{
$functionName = $this->resolveFunctionName($nameNode, $scope);
if ($functionName === null) {
throw new \PHPStan\Broker\FunctionNotFoundException((string) $nameNode);
}
$lowerCasedFunctionName = strtolower($functionName);
if (!isset($this->functionReflections[$lowerCasedFunctionName])) {
if (isset(self::$functionMap[$lowerCasedFunctionName])) {
return $this->functionReflections[$lowerCasedFunctionName] = self::$functionMap[$lowerCasedFunctionName];
}
if ($this->signatureMapProvider->hasFunctionSignature($lowerCasedFunctionName)) {
$variantName = $lowerCasedFunctionName;
$variants = [];
$i = 0;
while ($this->signatureMapProvider->hasFunctionSignature($variantName)) {
$functionSignature = $this->signatureMapProvider->getFunctionSignature($variantName, null);
$returnType = $functionSignature->getReturnType();
if ($lowerCasedFunctionName === 'pow') {
$returnType = TypeUtils::toBenevolentUnion($returnType);
}
$variants[] = new FunctionVariant(
array_map(static function (ParameterSignature $parameterSignature) use ($lowerCasedFunctionName): NativeParameterReflection {
$type = $parameterSignature->getType();
if (
$parameterSignature->getName() === 'args'
&& (
$lowerCasedFunctionName === 'printf'
|| $lowerCasedFunctionName === 'sprintf'
)
) {
$type = new UnionType([
new StringAlwaysAcceptingObjectWithToStringType(),
new IntegerType(),
new FloatType(),
new NullType(),
new BooleanType(),
]);
}
return new NativeParameterReflection(
$parameterSignature->getName(),
$parameterSignature->isOptional(),
$type,
$parameterSignature->passedByReference(),
$parameterSignature->isVariadic()
);
}, $functionSignature->getParameters()),
$functionSignature->isVariadic(),
$returnType
);
$i++;
$variantName = sprintf($lowerCasedFunctionName . '\'' . $i);
}
$functionReflection = new NativeFunctionReflection(
$lowerCasedFunctionName,
$variants,
null
);
self::$functionMap[$lowerCasedFunctionName] = $functionReflection;
$this->functionReflections[$lowerCasedFunctionName] = $functionReflection;
} else {
$this->functionReflections[$lowerCasedFunctionName] = $this->getCustomFunction($nameNode, $scope);
}
}
return $this->functionReflections[$lowerCasedFunctionName];
}
public function hasFunction(\PhpParser\Node\Name $nameNode, ?Scope $scope): bool
{
return $this->resolveFunctionName($nameNode, $scope) !== null;
}
public function hasCustomFunction(\PhpParser\Node\Name $nameNode, ?Scope $scope): bool
{
$functionName = $this->resolveFunctionName($nameNode, $scope);
if ($functionName === null) {
return false;
}
$lowerCasedFunctionName = strtolower($functionName);
return !$this->signatureMapProvider->hasFunctionSignature($lowerCasedFunctionName);
}
public function getCustomFunction(\PhpParser\Node\Name $nameNode, ?Scope $scope): \PHPStan\Reflection\Php\PhpFunctionReflection
{
if (!$this->hasCustomFunction($nameNode, $scope)) {
throw new \PHPStan\Broker\FunctionNotFoundException((string) $nameNode);
}
/** @var string $functionName */
$functionName = $this->resolveFunctionName($nameNode, $scope);
if (!function_exists($functionName)) {
throw new \PHPStan\Broker\FunctionNotFoundException($functionName);
}
$lowerCasedFunctionName = strtolower($functionName);
if (isset($this->customFunctionReflections[$lowerCasedFunctionName])) {
return $this->customFunctionReflections[$lowerCasedFunctionName];
}
$reflectionFunction = new \ReflectionFunction($functionName);
$phpDocParameterTags = [];
$phpDocReturnTag = null;
$phpDocThrowsTag = null;
$isDeprecated = false;
$isInternal = false;
$isFinal = false;
if ($reflectionFunction->getFileName() !== false && $reflectionFunction->getDocComment() !== false) {
$fileName = $reflectionFunction->getFileName();
$docComment = $reflectionFunction->getDocComment();
$resolvedPhpDoc = $this->fileTypeMapper->getResolvedPhpDoc($fileName, null, null, $docComment);
$phpDocParameterTags = $resolvedPhpDoc->getParamTags();
$phpDocReturnTag = $resolvedPhpDoc->getReturnTag();
$phpDocThrowsTag = $resolvedPhpDoc->getThrowsTag();
$isDeprecated = $resolvedPhpDoc->isDeprecated();
$isInternal = $resolvedPhpDoc->isInternal();
$isFinal = $resolvedPhpDoc->isFinal();
}
$functionReflection = $this->functionReflectionFactory->create(
$reflectionFunction,
array_map(static function (ParamTag $paramTag): Type {
return $paramTag->getType();
}, $phpDocParameterTags),
$phpDocReturnTag !== null ? $phpDocReturnTag->getType() : null,
$phpDocThrowsTag !== null ? $phpDocThrowsTag->getType() : null,
$isDeprecated,
$isInternal,
$isFinal,
$reflectionFunction->getFileName()
);
$this->customFunctionReflections[$lowerCasedFunctionName] = $functionReflection;
return $functionReflection;
}
public function resolveFunctionName(\PhpParser\Node\Name $nameNode, ?Scope $scope): ?string
{
return $this->resolveName($nameNode, static function (string $name): bool {
$exists = function_exists($name);
if ($exists) {
return true;
}
$lowercased = strtolower($name);
if ($lowercased === 'getallheaders') {
return true;
}
if (\Nette\Utils\Strings::startsWith($lowercased, 'apache_')) {
return true;
}
if (\Nette\Utils\Strings::startsWith($lowercased, 'fastcgi_')) {
return true;
}
if (\Nette\Utils\Strings::startsWith($lowercased, 'xdebug_')) {
return true;
}
return false;
}, $scope);
}
public function hasConstant(\PhpParser\Node\Name $nameNode, ?Scope $scope): bool
{
return $this->resolveConstantName($nameNode, $scope) !== null;
}
public function resolveConstantName(\PhpParser\Node\Name $nameNode, ?Scope $scope): ?string
{
return $this->resolveName($nameNode, function (string $name) use ($scope): bool {
$isCompilerHaltOffset = $name === '__COMPILER_HALT_OFFSET__';
if ($isCompilerHaltOffset && $scope !== null && $this->fileHasCompilerHaltStatementCalls($scope->getFile())) {
return true;
}
return defined($name);
}, $scope);
}
private function fileHasCompilerHaltStatementCalls(string $pathToFile): bool
{
$nodes = $this->parser->parseFile($pathToFile);
foreach ($nodes as $node) {
if ($node instanceof Node\Stmt\HaltCompiler) {
return true;
}
}
return false;
}
/**
* @param Node\Name $nameNode
* @param \Closure(string $name): bool $existsCallback
* @param Scope|null $scope
* @return string|null
*/
private function resolveName(
\PhpParser\Node\Name $nameNode,
\Closure $existsCallback,
?Scope $scope
): ?string
{
$name = (string) $nameNode;
if ($scope !== null && $scope->getNamespace() !== null && !$nameNode->isFullyQualified()) {
$namespacedName = sprintf('%s\\%s', $scope->getNamespace(), $name);
if ($existsCallback($namespacedName)) {
return $namespacedName;
}
}
if ($existsCallback($name)) {
return $name;
}
return null;
}
private function isExistsCheckCall(): bool
{
$debugBacktrace = debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS);
$existsCallTypes = [
'class_exists' => true,
'interface_exists' => true,
'trait_exists' => true,
];
foreach ($debugBacktrace as $traceStep) {
if (
isset($traceStep['function'])
&& isset($existsCallTypes[$traceStep['function']])
// We must ignore the self::hasClass calls
&& (!isset($traceStep['file']) || $traceStep['file'] !== __FILE__)
) {
return true;
}
}
return false;
}
}
src/Broker/ClassAutoloadingException.php 0000666 00000001317 13436755504 0014425 0 ustar 00 getMessage(),
$functionName
), 0, $previous);
} else {
parent::__construct(sprintf(
'Class %s not found and could not be autoloaded.',
$functionName
), 0);
}
$this->className = $functionName;
}
public function getClassName(): string
{
return $this->className;
}
}
src/Broker/ClassNotFoundException.php 0000666 00000000757 13436755504 0013722 0 ustar 00 className = $functionName;
}
public function getClassName(): string
{
return $this->className;
}
}
src/Broker/BrokerFactory.php 0000666 00000006350 13436755504 0012070 0 ustar 00 container = $container;
}
public function create(): Broker
{
$tagToService = function (array $tags) {
return array_map(function (string $serviceName) {
return $this->container->getService($serviceName);
}, array_keys($tags));
};
$phpClassReflectionExtension = $this->container->getByType(PhpClassReflectionExtension::class);
$annotationsMethodsClassReflectionExtension = $this->container->getByType(AnnotationsMethodsClassReflectionExtension::class);
$annotationsPropertiesClassReflectionExtension = $this->container->getByType(AnnotationsPropertiesClassReflectionExtension::class);
$phpDefectClassReflectionExtension = $this->container->getByType(PhpDefectClassReflectionExtension::class);
/** @var RelativePathHelper $relativePathHelper */
$relativePathHelper = $this->container->getService('relativePathHelper');
return new Broker(
array_merge([$phpClassReflectionExtension, $phpDefectClassReflectionExtension], $tagToService($this->container->findByTag(self::PROPERTIES_CLASS_REFLECTION_EXTENSION_TAG)), [$annotationsPropertiesClassReflectionExtension]),
array_merge([$phpClassReflectionExtension], $tagToService($this->container->findByTag(self::METHODS_CLASS_REFLECTION_EXTENSION_TAG)), [$annotationsMethodsClassReflectionExtension]),
$tagToService($this->container->findByTag(self::DYNAMIC_METHOD_RETURN_TYPE_EXTENSION_TAG)),
$tagToService($this->container->findByTag(self::DYNAMIC_STATIC_METHOD_RETURN_TYPE_EXTENSION_TAG)),
$tagToService($this->container->findByTag(self::DYNAMIC_FUNCTION_RETURN_TYPE_EXTENSION_TAG)),
$this->container->getByType(FunctionReflectionFactory::class),
$this->container->getByType(FileTypeMapper::class),
$this->container->getByType(SignatureMapProvider::class),
$this->container->getByType(\PhpParser\PrettyPrinter\Standard::class),
$this->container->getByType(AnonymousClassNameHelper::class),
$this->container->getByType(Parser::class),
$relativePathHelper,
$this->container->parameters['universalObjectCratesClasses']
);
}
}
src/Reflection/TrivialParametersAcceptor.php 0000666 00000000700 13436755504 0015272 0 ustar 00
*/
public function getParameters(): array
{
return [];
}
public function isVariadic(): bool
{
return true;
}
public function getReturnType(): Type
{
return new MixedType();
}
}
src/Reflection/FunctionReflectionFactory.php 0000666 00000001366 13436755504 0015314 0 ustar 00 methodReflectionFactory = $methodReflectionFactory;
$this->fileTypeMapper = $fileTypeMapper;
$this->annotationsMethodsClassReflectionExtension = $annotationsMethodsClassReflectionExtension;
$this->annotationsPropertiesClassReflectionExtension = $annotationsPropertiesClassReflectionExtension;
$this->signatureMapProvider = $signatureMapProvider;
}
public function setBroker(Broker $broker): void
{
$this->broker = $broker;
}
public function hasProperty(ClassReflection $classReflection, string $propertyName): bool
{
return $classReflection->getNativeReflection()->hasProperty($propertyName);
}
public function getProperty(ClassReflection $classReflection, string $propertyName): PropertyReflection
{
if (!isset($this->propertiesIncludingAnnotations[$classReflection->getName()][$propertyName])) {
$this->propertiesIncludingAnnotations[$classReflection->getName()][$propertyName] = $this->createProperty($classReflection, $propertyName, true);
}
return $this->propertiesIncludingAnnotations[$classReflection->getName()][$propertyName];
}
public function getNativeProperty(ClassReflection $classReflection, string $propertyName): PhpPropertyReflection
{
if (!isset($this->nativeProperties[$classReflection->getName()][$propertyName])) {
/** @var \PHPStan\Reflection\Php\PhpPropertyReflection $property */
$property = $this->createProperty($classReflection, $propertyName, false);
$this->nativeProperties[$classReflection->getName()][$propertyName] = $property;
}
return $this->nativeProperties[$classReflection->getName()][$propertyName];
}
private function createProperty(
ClassReflection $classReflection,
string $propertyName,
bool $includingAnnotations
): PropertyReflection
{
$propertyReflection = $classReflection->getNativeReflection()->getProperty($propertyName);
$propertyName = $propertyReflection->getName();
$declaringClassReflection = $this->broker->getClass($propertyReflection->getDeclaringClass()->getName());
$isDeprecated = false;
$isInternal = false;
if ($includingAnnotations && $this->annotationsPropertiesClassReflectionExtension->hasProperty($classReflection, $propertyName)) {
$hierarchyDistances = $classReflection->getClassHierarchyDistances();
$annotationProperty = $this->annotationsPropertiesClassReflectionExtension->getProperty($classReflection, $propertyName);
if (!isset($hierarchyDistances[$annotationProperty->getDeclaringClass()->getName()])) {
throw new \PHPStan\ShouldNotHappenException();
}
if (!isset($hierarchyDistances[$propertyReflection->getDeclaringClass()->getName()])) {
throw new \PHPStan\ShouldNotHappenException();
}
if ($hierarchyDistances[$annotationProperty->getDeclaringClass()->getName()] < $hierarchyDistances[$propertyReflection->getDeclaringClass()->getName()]) {
return $annotationProperty;
}
}
if ($propertyReflection->getDocComment() === false) {
$type = new MixedType();
} elseif ($declaringClassReflection->getFileName() !== false) {
$phpDocBlock = PhpDocBlock::resolvePhpDocBlockForProperty(
$this->broker,
$propertyReflection->getDocComment(),
$declaringClassReflection->getName(),
$propertyName,
$declaringClassReflection->getFileName()
);
$resolvedPhpDoc = $this->fileTypeMapper->getResolvedPhpDoc(
$phpDocBlock->getFile(),
$phpDocBlock->getClass(),
$this->findPropertyTrait($phpDocBlock, $propertyReflection),
$phpDocBlock->getDocComment()
);
$varTags = $resolvedPhpDoc->getVarTags();
if (isset($varTags[0]) && count($varTags) === 1) {
$type = $varTags[0]->getType();
} elseif (isset($varTags[$propertyName])) {
$type = $varTags[$propertyName]->getType();
} else {
$type = new MixedType();
}
$isDeprecated = $resolvedPhpDoc->isDeprecated();
$isInternal = $resolvedPhpDoc->isInternal();
} else {
$type = new MixedType();
}
return new PhpPropertyReflection(
$declaringClassReflection,
$type,
$propertyReflection,
$isDeprecated,
$isInternal
);
}
public function hasMethod(ClassReflection $classReflection, string $methodName): bool
{
if (
$classReflection->getName() === \ReflectionType::class
) {
$classReflection = $this->broker->getClass(\ReflectionNamedType::class);
}
return $classReflection->getNativeReflection()->hasMethod($methodName);
}
public function getMethod(ClassReflection $classReflection, string $methodName): MethodReflection
{
if (
$classReflection->getName() === \ReflectionType::class
) {
$classReflection = $this->broker->getClass(\ReflectionNamedType::class);
}
if (isset($this->methodsIncludingAnnotations[$classReflection->getName()][$methodName])) {
return $this->methodsIncludingAnnotations[$classReflection->getName()][$methodName];
}
$nativeMethodReflection = new NativeBuiltinMethodReflection($classReflection->getNativeReflection()->getMethod($methodName));
if (!isset($this->methodsIncludingAnnotations[$classReflection->getName()][$nativeMethodReflection->getName()])) {
$method = $this->createMethod($classReflection, $nativeMethodReflection, true);
$this->methodsIncludingAnnotations[$classReflection->getName()][$nativeMethodReflection->getName()] = $method;
if ($nativeMethodReflection->getName() !== $methodName) {
$this->methodsIncludingAnnotations[$classReflection->getName()][$methodName] = $method;
}
}
return $this->methodsIncludingAnnotations[$classReflection->getName()][$nativeMethodReflection->getName()];
}
public function hasNativeMethod(ClassReflection $classReflection, string $methodName): bool
{
$hasMethod = $this->hasMethod($classReflection, $methodName);
if ($hasMethod) {
return true;
}
if ($methodName === '__get' && UniversalObjectCratesClassReflectionExtension::isUniversalObjectCrate(
$this->broker,
$this->broker->getUniversalObjectCratesClasses(),
$classReflection
)) {
return true;
}
return false;
}
public function getNativeMethod(ClassReflection $classReflection, string $methodName): MethodReflection
{
if (isset($this->nativeMethods[$classReflection->getName()][$methodName])) {
return $this->nativeMethods[$classReflection->getName()][$methodName];
}
if ($classReflection->getNativeReflection()->hasMethod($methodName)) {
$nativeMethodReflection = new NativeBuiltinMethodReflection(
$classReflection->getNativeReflection()->getMethod($methodName)
);
} else {
if (
$methodName !== '__get'
|| !UniversalObjectCratesClassReflectionExtension::isUniversalObjectCrate(
$this->broker,
$this->broker->getUniversalObjectCratesClasses(),
$classReflection
)) {
throw new \PHPStan\ShouldNotHappenException();
}
$nativeMethodReflection = new FakeBuiltinMethodReflection(
$methodName,
$classReflection->getNativeReflection()
);
}
if (!isset($this->nativeMethods[$classReflection->getName()][$nativeMethodReflection->getName()])) {
$method = $this->createMethod($classReflection, $nativeMethodReflection, false);
$this->nativeMethods[$classReflection->getName()][$nativeMethodReflection->getName()] = $method;
}
return $this->nativeMethods[$classReflection->getName()][$nativeMethodReflection->getName()];
}
private function createMethod(
ClassReflection $classReflection,
BuiltinMethodReflection $methodReflection,
bool $includingAnnotations
): MethodReflection
{
if ($includingAnnotations && $this->annotationsMethodsClassReflectionExtension->hasMethod($classReflection, $methodReflection->getName())) {
$hierarchyDistances = $classReflection->getClassHierarchyDistances();
$annotationMethod = $this->annotationsMethodsClassReflectionExtension->getMethod($classReflection, $methodReflection->getName());
if (!isset($hierarchyDistances[$annotationMethod->getDeclaringClass()->getName()])) {
throw new \PHPStan\ShouldNotHappenException();
}
if (!isset($hierarchyDistances[$methodReflection->getDeclaringClass()->getName()])) {
throw new \PHPStan\ShouldNotHappenException();
}
if ($hierarchyDistances[$annotationMethod->getDeclaringClass()->getName()] < $hierarchyDistances[$methodReflection->getDeclaringClass()->getName()]) {
return $annotationMethod;
}
}
$declaringClassName = $methodReflection->getDeclaringClass()->getName();
$signatureMapMethodName = sprintf('%s::%s', $declaringClassName, $methodReflection->getName());
$declaringClass = $this->broker->getClass($declaringClassName);
if ($this->signatureMapProvider->hasFunctionSignature($signatureMapMethodName)) {
$variantName = $signatureMapMethodName;
$variants = [];
$i = 0;
while ($this->signatureMapProvider->hasFunctionSignature($variantName)) {
$methodSignature = $this->signatureMapProvider->getFunctionSignature($variantName, $declaringClassName);
$variants[] = new FunctionVariant(
array_map(static function (ParameterSignature $parameterSignature): NativeParameterReflection {
return new NativeParameterReflection(
$parameterSignature->getName(),
$parameterSignature->isOptional(),
$parameterSignature->getType(),
$parameterSignature->passedByReference(),
$parameterSignature->isVariadic()
);
}, $methodSignature->getParameters()),
$methodSignature->isVariadic(),
$methodSignature->getReturnType()
);
$i++;
$variantName = sprintf($signatureMapMethodName . '\'' . $i);
}
return new NativeMethodReflection(
$this->broker,
$declaringClass,
$methodReflection,
$variants
);
}
$phpDocParameterTypes = [];
$phpDocReturnType = null;
$phpDocThrowType = null;
$isDeprecated = false;
$isInternal = false;
$isFinal = false;
$declaringTraitName = $this->findMethodTrait($methodReflection);
if ($declaringClass->getFileName() !== false) {
if ($methodReflection->getDocComment() !== false) {
$phpDocBlock = PhpDocBlock::resolvePhpDocBlockForMethod(
$this->broker,
$methodReflection->getDocComment(),
$declaringClass->getName(),
$methodReflection->getName(),
$declaringClass->getFileName()
);
$resolvedPhpDoc = $this->fileTypeMapper->getResolvedPhpDoc(
$phpDocBlock->getFile(),
$phpDocBlock->getClass(),
$declaringTraitName,
$phpDocBlock->getDocComment()
);
$phpDocParameterTypes = array_map(static function (ParamTag $tag): Type {
return $tag->getType();
}, $resolvedPhpDoc->getParamTags());
$phpDocReturnType = $resolvedPhpDoc->getReturnTag() !== null ? $resolvedPhpDoc->getReturnTag()->getType() : null;
$phpDocThrowType = $resolvedPhpDoc->getThrowsTag() !== null ? $resolvedPhpDoc->getThrowsTag()->getType() : null;
$isDeprecated = $resolvedPhpDoc->isDeprecated();
$isInternal = $resolvedPhpDoc->isInternal();
$isFinal = $resolvedPhpDoc->isFinal();
}
}
$declaringTrait = null;
if (
$declaringTraitName !== null && $this->broker->hasClass($declaringTraitName)
) {
$declaringTrait = $this->broker->getClass($declaringTraitName);
}
return $this->methodReflectionFactory->create(
$declaringClass,
$declaringTrait,
$methodReflection,
$phpDocParameterTypes,
$phpDocReturnType,
$phpDocThrowType,
$isDeprecated,
$isInternal,
$isFinal
);
}
private function findPropertyTrait(
PhpDocBlock $phpDocBlock,
\ReflectionProperty $propertyReflection
): ?string
{
$resolvedPhpDoc = $this->fileTypeMapper->getResolvedPhpDoc(
$phpDocBlock->getFile(),
$phpDocBlock->getClass(),
null,
$phpDocBlock->getDocComment()
);
if (count($resolvedPhpDoc->getVarTags()) > 0) {
return null;
}
$declaringClass = $propertyReflection->getDeclaringClass();
$traits = $declaringClass->getTraits();
while (count($traits) > 0) {
/** @var \ReflectionClass $traitReflection */
$traitReflection = array_pop($traits);
$traits = array_merge($traits, $traitReflection->getTraits());
if (!$traitReflection->hasProperty($propertyReflection->getName())) {
continue;
}
$traitResolvedPhpDoc = $this->fileTypeMapper->getResolvedPhpDoc(
$phpDocBlock->getFile(),
$phpDocBlock->getClass(),
$traitReflection->getName(),
$phpDocBlock->getDocComment()
);
if (
count($traitResolvedPhpDoc->getVarTags()) > 0
) {
return $traitReflection->getName();
}
}
return null;
}
private function findMethodTrait(
BuiltinMethodReflection $methodReflection
): ?string
{
if (
$methodReflection->getFileName() === $methodReflection->getDeclaringClass()->getFileName()
) {
return null;
}
$declaringClass = $methodReflection->getDeclaringClass();
$traitAliases = $declaringClass->getTraitAliases();
if (array_key_exists($methodReflection->getName(), $traitAliases)) {
return explode('::', $traitAliases[$methodReflection->getName()])[0];
}
foreach ($declaringClass->getTraits() as $traitReflection) {
if (!$traitReflection->hasMethod($methodReflection->getName())) {
continue;
}
$traitMethodReflection = $traitReflection->getMethod($methodReflection->getName());
if (
$traitMethodReflection->getFileName() === $methodReflection->getFileName()
&& $traitMethodReflection->getStartLine() === $methodReflection->getStartLine()
) {
return $traitReflection->getName();
}
}
return null;
}
}
src/Reflection/Php/UniversalObjectCratesClassReflectionExtension.php 0000666 00000003526 13436755504 0022052 0 ustar 00 classes = $classes;
}
public function setBroker(Broker $broker): void
{
$this->broker = $broker;
}
public function hasProperty(ClassReflection $classReflection, string $propertyName): bool
{
return self::isUniversalObjectCrate(
$this->broker,
$this->classes,
$classReflection
);
}
/**
* @param \PHPStan\Broker\Broker $broker
* @param string[] $classes
* @param \PHPStan\Reflection\ClassReflection $classReflection
* @return bool
*/
public static function isUniversalObjectCrate(
Broker $broker,
array $classes,
ClassReflection $classReflection
): bool
{
foreach ($classes as $className) {
if (!$broker->hasClass($className)) {
continue;
}
if (
$classReflection->getName() === $className
|| $classReflection->isSubclassOf($className)
) {
return true;
}
}
return false;
}
public function getProperty(ClassReflection $classReflection, string $propertyName): PropertyReflection
{
if ($classReflection->hasNativeMethod('__get')) {
$type = ParametersAcceptorSelector::selectSingle($classReflection->getNativeMethod('__get')->getVariants())->getReturnType();
} else {
$type = new MixedType();
}
return new UniversalObjectCrateProperty($classReflection, $type);
}
}
src/Reflection/Php/DummyParameter.php 0000666 00000002334 13436755504 0013643 0 ustar 00 name = $name;
$this->type = $type;
$this->optional = $optional;
$this->passedByReference = $passedByReference !== null
? PassedByReference::createCreatesNewVariable()
: PassedByReference::createNo();
$this->variadic = $variadic;
}
public function getName(): string
{
return $this->name;
}
public function isOptional(): bool
{
return $this->optional;
}
public function getType(): Type
{
return $this->type;
}
public function passedByReference(): PassedByReference
{
return $this->passedByReference;
}
public function isVariadic(): bool
{
return $this->variadic;
}
}
src/Reflection/Php/PhpFunctionReflection.php 0000666 00000013403 13436755504 0015156 0 ustar 00 reflection = $reflection;
$this->parser = $parser;
$this->functionCallStatementFinder = $functionCallStatementFinder;
$this->cache = $cache;
$this->phpDocParameterTypes = $phpDocParameterTypes;
$this->phpDocReturnType = $phpDocReturnType;
$this->phpDocThrowType = $phpDocThrowType;
$this->isDeprecated = $isDeprecated;
$this->isInternal = $isInternal;
$this->isFinal = $isFinal;
$this->filename = $filename;
}
public function getName(): string
{
return $this->reflection->getName();
}
/**
* @return string|false
*/
public function getFileName()
{
return $this->filename;
}
/**
* @return ParametersAcceptorWithPhpDocs[]
*/
public function getVariants(): array
{
if ($this->variants === null) {
$this->variants = [
new FunctionVariantWithPhpDocs(
$this->getParameters(),
$this->isVariadic(),
$this->getReturnType(),
$this->getPhpDocReturnType(),
$this->getNativeReturnType()
),
];
}
return $this->variants;
}
/**
* @return \PHPStan\Reflection\Php\PhpParameterReflection[]
*/
private function getParameters(): array
{
return array_map(function (\ReflectionParameter $reflection) {
return new PhpParameterReflection(
$reflection,
$this->phpDocParameterTypes[$reflection->getName()] ?? null
);
}, $this->reflection->getParameters());
}
private function isVariadic(): bool
{
$isNativelyVariadic = $this->reflection->isVariadic();
if (!$isNativelyVariadic && $this->reflection->getFileName() !== false) {
$key = sprintf('variadic-function-%s-v0', $this->reflection->getName());
$cachedResult = $this->cache->load($key);
if ($cachedResult === null) {
$nodes = $this->parser->parseFile($this->reflection->getFileName());
$result = $this->callsFuncGetArgs($nodes);
$this->cache->save($key, $result);
return $result;
}
return $cachedResult;
}
return $isNativelyVariadic;
}
/**
* @param mixed $nodes
* @return bool
*/
private function callsFuncGetArgs($nodes): bool
{
foreach ($nodes as $node) {
if (is_array($node)) {
if ($this->callsFuncGetArgs($node)) {
return true;
}
}
if (!($node instanceof \PhpParser\Node)) {
continue;
}
if ($node instanceof Function_) {
$functionName = (string) $node->namespacedName;
if ($functionName === $this->reflection->getName()) {
return $this->functionCallStatementFinder->findFunctionCallInStatements(ParametersAcceptor::VARIADIC_FUNCTIONS, $node->getStmts()) !== null;
}
continue;
}
if ($this->callsFuncGetArgs($node)) {
return true;
}
}
return false;
}
private function getReturnType(): Type
{
if ($this->reflection->getName() === 'count') {
return new IntegerType();
}
$returnType = $this->reflection->getReturnType();
$phpDocReturnType = $this->phpDocReturnType;
if (
$returnType !== null
&& $phpDocReturnType !== null
&& $returnType->allowsNull() !== TypeCombinator::containsNull($phpDocReturnType)
) {
$phpDocReturnType = null;
}
return TypehintHelper::decideTypeFromReflection(
$returnType,
$phpDocReturnType
);
}
private function getPhpDocReturnType(): Type
{
if ($this->phpDocReturnType !== null) {
return $this->phpDocReturnType;
}
return new MixedType();
}
private function getNativeReturnType(): Type
{
return TypehintHelper::decideTypeFromReflection($this->reflection->getReturnType());
}
public function isDeprecated(): bool
{
return $this->isDeprecated || $this->reflection->isDeprecated();
}
public function isInternal(): bool
{
return $this->isInternal;
}
public function isFinal(): bool
{
return $this->isFinal;
}
public function getThrowType(): ?Type
{
return $this->phpDocThrowType;
}
}
src/Reflection/Php/NativeBuiltinMethodReflection.php 0000666 00000003125 13436755504 0016637 0 ustar 00 reflection = $reflection;
}
public function getName(): string
{
return $this->reflection->getName();
}
/**
* @return string|false
*/
public function getFileName()
{
return $this->reflection->getFileName();
}
public function getDeclaringClass(): \ReflectionClass
{
return $this->reflection->getDeclaringClass();
}
/**
* @return int|false
*/
public function getStartLine()
{
return $this->reflection->getStartLine();
}
/**
* @return string|false
*/
public function getDocComment()
{
return $this->reflection->getDocComment();
}
public function isStatic(): bool
{
return $this->reflection->isStatic();
}
public function isPrivate(): bool
{
return $this->reflection->isPrivate();
}
public function isPublic(): bool
{
return $this->reflection->isPublic();
}
public function getPrototype(): BuiltinMethodReflection
{
return new self($this->reflection->getPrototype());
}
public function isDeprecated(): bool
{
return $this->reflection->isDeprecated();
}
public function isVariadic(): bool
{
return $this->reflection->isVariadic();
}
public function getReturnType(): ?\ReflectionType
{
return $this->reflection->getReturnType();
}
/**
* @return \ReflectionParameter[]
*/
public function getParameters(): array
{
return $this->reflection->getParameters();
}
}
src/Reflection/Php/BuiltinMethodReflection.php 0000666 00000001405 13436755504 0015467 0 ustar 00 functionLike = $functionLike;
$this->realParameterTypes = $realParameterTypes;
$this->phpDocParameterTypes = $phpDocParameterTypes;
$this->realReturnTypePresent = $realReturnTypePresent;
$this->realReturnType = $realReturnType;
$this->phpDocReturnType = $phpDocReturnType;
$this->throwType = $throwType;
$this->isDeprecated = $isDeprecated;
$this->isInternal = $isInternal;
$this->isFinal = $isFinal;
}
protected function getFunctionLike(): FunctionLike
{
return $this->functionLike;
}
public function getName(): string
{
if ($this->functionLike instanceof ClassMethod) {
return $this->functionLike->name->name;
}
return (string) $this->functionLike->namespacedName;
}
/**
* @return \PHPStan\Reflection\ParametersAcceptor[]
*/
public function getVariants(): array
{
if ($this->variants === null) {
$this->variants = [
new FunctionVariant(
$this->getParameters(),
$this->isVariadic(),
$this->getReturnType()
),
];
}
return $this->variants;
}
/**
* @return \PHPStan\Reflection\ParameterReflection[]
*/
private function getParameters(): array
{
$parameters = [];
$isOptional = true;
/** @var \PhpParser\Node\Param $parameter */
foreach (array_reverse($this->functionLike->getParams()) as $parameter) {
if (!$isOptional || $parameter->default === null) {
$isOptional = false;
}
if (!$parameter->var instanceof Variable || !is_string($parameter->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
$parameters[] = new PhpParameterFromParserNodeReflection(
$parameter->var->name,
$isOptional,
$this->realParameterTypes[$parameter->var->name],
$this->phpDocParameterTypes[$parameter->var->name] ?? null,
$parameter->byRef
? PassedByReference::createCreatesNewVariable()
: PassedByReference::createNo(),
$parameter->default,
$parameter->variadic
);
}
return array_reverse($parameters);
}
private function isVariadic(): bool
{
foreach ($this->functionLike->getParams() as $parameter) {
if ($parameter->variadic) {
return true;
}
}
return false;
}
protected function getReturnType(): Type
{
$phpDocReturnType = $this->phpDocReturnType;
if (
$this->realReturnTypePresent
&& $phpDocReturnType !== null
&& TypeCombinator::containsNull($this->realReturnType) !== TypeCombinator::containsNull($phpDocReturnType)
) {
$phpDocReturnType = null;
}
return TypehintHelper::decideType($this->realReturnType, $phpDocReturnType);
}
public function isDeprecated(): bool
{
return $this->isDeprecated;
}
public function isInternal(): bool
{
return $this->isInternal;
}
public function isFinal(): bool
{
return $this->isFinal;
}
public function getThrowType(): ?Type
{
return $this->throwType;
}
}
src/Reflection/Php/PhpParameterFromParserNodeReflection.php 0000666 00000003662 13436755504 0020126 0 ustar 00 name = $name;
$this->optional = $optional;
$this->realType = $realType;
$this->phpDocType = $phpDocType;
$this->passedByReference = $passedByReference;
$this->defaultValue = $defaultValue;
$this->variadic = $variadic;
}
public function getName(): string
{
return $this->name;
}
public function isOptional(): bool
{
return $this->optional;
}
public function getType(): Type
{
if ($this->type === null) {
$phpDocType = $this->phpDocType;
if ($phpDocType !== null && $this->defaultValue !== null) {
if (
$this->defaultValue instanceof ConstFetch
&& strtolower((string) $this->defaultValue->name) === 'null'
) {
$phpDocType = \PHPStan\Type\TypeCombinator::addNull($phpDocType);
}
}
$this->type = TypehintHelper::decideType($this->realType, $phpDocType);
}
return $this->type;
}
public function passedByReference(): PassedByReference
{
return $this->passedByReference;
}
public function isVariadic(): bool
{
return $this->variadic;
}
}
src/Reflection/Php/PhpMethodReflection.php 0000666 00000024152 13436755504 0014614 0 ustar 00 declaringClass = $declaringClass;
$this->declaringTrait = $declaringTrait;
$this->reflection = $reflection;
$this->broker = $broker;
$this->parser = $parser;
$this->functionCallStatementFinder = $functionCallStatementFinder;
$this->cache = $cache;
$this->phpDocParameterTypes = $phpDocParameterTypes;
$this->phpDocReturnType = $phpDocReturnType;
$this->phpDocThrowType = $phpDocThrowType;
$this->isDeprecated = $isDeprecated;
$this->isInternal = $isInternal;
$this->isFinal = $isFinal;
}
public function getDeclaringClass(): ClassReflection
{
return $this->declaringClass;
}
/**
* @return string|false
*/
public function getDocComment()
{
return $this->reflection->getDocComment();
}
public function getPrototype(): ClassMemberReflection
{
try {
$prototypeMethod = $this->reflection->getPrototype();
$prototypeDeclaringClass = $this->broker->getClass($prototypeMethod->getDeclaringClass()->getName());
return new MethodPrototypeReflection(
$prototypeDeclaringClass,
$prototypeMethod->isStatic(),
$prototypeMethod->isPrivate(),
$prototypeMethod->isPublic()
);
} catch (\ReflectionException $e) {
return $this;
}
}
public function isStatic(): bool
{
return $this->reflection->isStatic();
}
public function getName(): string
{
$name = $this->reflection->getName();
$lowercaseName = strtolower($name);
if ($lowercaseName === $name) {
// fix for https://bugs.php.net/bug.php?id=74939
foreach ($this->getDeclaringClass()->getNativeReflection()->getTraitAliases() as $traitTarget) {
$correctName = $this->getMethodNameWithCorrectCase($name, $traitTarget);
if ($correctName !== null) {
$name = $correctName;
break;
}
}
}
return $name;
}
private function getMethodNameWithCorrectCase(string $lowercaseMethodName, string $traitTarget): ?string
{
$trait = explode('::', $traitTarget)[0];
$traitReflection = $this->broker->getClass($trait)->getNativeReflection();
foreach ($traitReflection->getTraitAliases() as $methodAlias => $traitTarget) {
if ($lowercaseMethodName === strtolower($methodAlias)) {
return $methodAlias;
}
$correctName = $this->getMethodNameWithCorrectCase($lowercaseMethodName, $traitTarget);
if ($correctName !== null) {
return $correctName;
}
}
return null;
}
/**
* @return ParametersAcceptorWithPhpDocs[]
*/
public function getVariants(): array
{
if ($this->variants === null) {
$this->variants = [
new FunctionVariantWithPhpDocs(
$this->getParameters(),
$this->isVariadic(),
$this->getReturnType(),
$this->getPhpDocReturnType(),
$this->getNativeReturnType()
),
];
}
return $this->variants;
}
/**
* @return \PHPStan\Reflection\Php\PhpParameterReflection[]
*/
private function getParameters(): array
{
if ($this->parameters === null) {
$this->parameters = array_map(function (\ReflectionParameter $reflection) {
return new PhpParameterReflection(
$reflection,
$this->phpDocParameterTypes[$reflection->getName()] ?? null
);
}, $this->reflection->getParameters());
}
return $this->parameters;
}
private function isVariadic(): bool
{
$isNativelyVariadic = $this->reflection->isVariadic();
$declaringClass = $this->declaringClass;
$filename = $this->declaringClass->getFileName();
if ($this->declaringTrait !== null) {
$declaringClass = $this->declaringTrait;
$filename = $this->declaringTrait->getFileName();
}
if (!$isNativelyVariadic && $filename !== false) {
$key = sprintf('variadic-method-%s-%s-v1', $declaringClass->getName(), $this->reflection->getName());
$cachedResult = $this->cache->load($key);
if ($cachedResult === null) {
$nodes = $this->parser->parseFile($filename);
$result = $this->callsFuncGetArgs($declaringClass, $nodes);
$this->cache->save($key, $result);
return $result;
}
return $cachedResult;
}
return $isNativelyVariadic;
}
/**
* @param ClassReflection $declaringClass
* @param mixed $nodes
* @return bool
*/
private function callsFuncGetArgs(ClassReflection $declaringClass, $nodes): bool
{
foreach ($nodes as $node) {
if (is_array($node)) {
if ($this->callsFuncGetArgs($declaringClass, $node)) {
return true;
}
}
if (!($node instanceof \PhpParser\Node)) {
continue;
}
if (
$node instanceof \PhpParser\Node\Stmt\ClassLike
&& isset($node->namespacedName)
&& $declaringClass->getName() !== (string) $node->namespacedName
) {
continue;
}
if ($node instanceof ClassMethod) {
if ($node->getStmts() === null) {
continue; // interface
}
$methodName = $node->name->name;
if ($methodName === $this->reflection->getName()) {
return $this->functionCallStatementFinder->findFunctionCallInStatements(ParametersAcceptor::VARIADIC_FUNCTIONS, $node->getStmts()) !== null;
}
continue;
}
if ($this->callsFuncGetArgs($declaringClass, $node)) {
return true;
}
}
return false;
}
public function isPrivate(): bool
{
return $this->reflection->isPrivate();
}
public function isPublic(): bool
{
return $this->reflection->isPublic();
}
private function getReturnType(): Type
{
if ($this->returnType === null) {
$name = strtolower($this->getName());
if (
$name === '__construct'
|| $name === '__destruct'
|| $name === '__unset'
|| $name === '__wakeup'
|| $name === '__clone'
) {
return $this->returnType = new VoidType();
}
if ($name === '__tostring') {
return $this->returnType = new StringType();
}
if ($name === '__isset') {
return $this->returnType = new BooleanType();
}
if ($name === '__sleep') {
return $this->returnType = new ArrayType(new IntegerType(), new StringType());
}
if ($name === '__set_state') {
return $this->returnType = new ObjectWithoutClassType();
}
$returnType = $this->reflection->getReturnType();
$phpDocReturnType = $this->phpDocReturnType;
if (
$returnType !== null
&& $phpDocReturnType !== null
&& $returnType->allowsNull() !== TypeCombinator::containsNull($phpDocReturnType)
) {
$phpDocReturnType = null;
}
$this->returnType = TypehintHelper::decideTypeFromReflection(
$returnType,
$phpDocReturnType,
$this->declaringClass->getName()
);
}
return $this->returnType;
}
private function getPhpDocReturnType(): Type
{
if ($this->phpDocReturnType !== null) {
return $this->phpDocReturnType;
}
return new MixedType();
}
private function getNativeReturnType(): Type
{
if ($this->nativeReturnType === null) {
$this->nativeReturnType = TypehintHelper::decideTypeFromReflection(
$this->reflection->getReturnType(),
null,
$this->declaringClass->getName()
);
}
return $this->nativeReturnType;
}
public function isDeprecated(): bool
{
return $this->isDeprecated;
}
public function isInternal(): bool
{
return $this->isInternal;
}
public function isFinal(): bool
{
return $this->isFinal;
}
public function getThrowType(): ?Type
{
return $this->phpDocThrowType;
}
}
src/Reflection/Php/PhpPropertyReflection.php 0000666 00000003344 13436755504 0015220 0 ustar 00 declaringClass = $declaringClass;
$this->type = $type;
$this->reflection = $reflection;
$this->isDeprecated = $isDeprecated;
$this->isInternal = $isInternal;
}
public function getDeclaringClass(): ClassReflection
{
return $this->declaringClass;
}
/**
* @return string|false
*/
public function getDocComment()
{
return $this->reflection->getDocComment();
}
public function isStatic(): bool
{
return $this->reflection->isStatic();
}
public function isPrivate(): bool
{
return $this->reflection->isPrivate();
}
public function isPublic(): bool
{
return $this->reflection->isPublic();
}
public function getType(): Type
{
return $this->type;
}
public function isReadable(): bool
{
return true;
}
public function isWritable(): bool
{
return true;
}
public function isDeprecated(): bool
{
return $this->isDeprecated;
}
public function isInternal(): bool
{
return $this->isInternal;
}
}
src/Reflection/Php/PhpMethodFromParserNodeReflection.php 0000666 00000005606 13436755504 0017426 0 ustar 00 declaringClass = $declaringClass;
}
public function getDeclaringClass(): ClassReflection
{
return $this->declaringClass;
}
public function getPrototype(): ClassMemberReflection
{
return $this->declaringClass->getNativeMethod($this->getClassMethod()->name->name)->getPrototype();
}
private function getClassMethod(): ClassMethod
{
/** @var \PhpParser\Node\Stmt\ClassMethod $functionLike */
$functionLike = $this->getFunctionLike();
return $functionLike;
}
public function isStatic(): bool
{
return $this->getClassMethod()->isStatic();
}
public function isPrivate(): bool
{
return $this->getClassMethod()->isPrivate();
}
public function isPublic(): bool
{
return $this->getClassMethod()->isPublic();
}
protected function getReturnType(): Type
{
$name = strtolower($this->getName());
if (
$name === '__construct'
|| $name === '__destruct'
|| $name === '__unset'
|| $name === '__wakeup'
|| $name === '__clone'
) {
return new VoidType();
}
if ($name === '__tostring') {
return new StringType();
}
if ($name === '__isset') {
return new BooleanType();
}
if ($name === '__sleep') {
return new ArrayType(new IntegerType(), new StringType());
}
if ($name === '__set_state') {
return new ObjectWithoutClassType();
}
return parent::getReturnType();
}
}
src/Reflection/Php/PhpParameterReflection.php 0000666 00000004311 13436755504 0015307 0 ustar 00 reflection = $reflection;
$this->phpDocType = $phpDocType;
}
public function isOptional(): bool
{
return $this->reflection->isOptional();
}
public function getName(): string
{
return $this->reflection->getName();
}
public function getType(): Type
{
if ($this->type === null) {
$phpDocType = $this->phpDocType;
if ($phpDocType !== null && $this->reflection->isDefaultValueAvailable() && $this->reflection->getDefaultValue() === null) {
$phpDocType = \PHPStan\Type\TypeCombinator::addNull($phpDocType);
}
$this->type = TypehintHelper::decideTypeFromReflection(
$this->reflection->getType(),
$phpDocType,
$this->reflection->getDeclaringClass() !== null ? $this->reflection->getDeclaringClass()->getName() : null,
$this->isVariadic()
);
}
return $this->type;
}
public function passedByReference(): PassedByReference
{
return $this->reflection->isPassedByReference()
? PassedByReference::createCreatesNewVariable()
: PassedByReference::createNo();
}
public function isVariadic(): bool
{
return $this->reflection->isVariadic();
}
public function getPhpDocType(): Type
{
if ($this->phpDocType !== null) {
return $this->phpDocType;
}
return new MixedType();
}
public function getNativeType(): Type
{
if ($this->nativeType === null) {
$this->nativeType = TypehintHelper::decideTypeFromReflection(
$this->reflection->getType(),
null,
$this->reflection->getDeclaringClass() !== null ? $this->reflection->getDeclaringClass()->getName() : null,
$this->isVariadic()
);
}
return $this->nativeType;
}
}
src/Reflection/Php/FakeBuiltinMethodReflection.php 0000666 00000002612 13436755504 0016257 0 ustar 00 methodName = $methodName;
$this->declaringClass = $declaringClass;
}
public function getName(): string
{
return $this->methodName;
}
/**
* @return string|false
*/
public function getFileName()
{
return false;
}
public function getDeclaringClass(): \ReflectionClass
{
return $this->declaringClass;
}
/**
* @return int|false
*/
public function getStartLine()
{
return false;
}
/**
* @return string|false
*/
public function getDocComment()
{
return false;
}
public function isStatic(): bool
{
return false;
}
public function isPrivate(): bool
{
return false;
}
public function isPublic(): bool
{
return true;
}
public function getPrototype(): BuiltinMethodReflection
{
throw new \ReflectionException();
}
public function isDeprecated(): bool
{
return false;
}
public function isVariadic(): bool
{
return false;
}
public function getReturnType(): ?\ReflectionType
{
return null;
}
/**
* @return \ReflectionParameter[]
*/
public function getParameters(): array
{
return [];
}
}
src/Reflection/Php/UniversalObjectCrateProperty.php 0000666 00000001660 13436755504 0016533 0 ustar 00 declaringClass = $declaringClass;
$this->type = $type;
}
public function getDeclaringClass(): ClassReflection
{
return $this->declaringClass;
}
public function isStatic(): bool
{
return false;
}
public function isPrivate(): bool
{
return false;
}
public function isPublic(): bool
{
return true;
}
public function getType(): Type
{
return $this->type;
}
public function isReadable(): bool
{
return true;
}
public function isWritable(): bool
{
return true;
}
}
src/Reflection/Php/PhpMethodReflectionFactory.php 0000666 00000001704 13436755504 0016142 0 ustar 00 name = $name;
$this->optional = $optional;
$this->type = $type;
$this->passedByReference = $passedByReference;
$this->variadic = $variadic;
}
public function getName(): string
{
return $this->name;
}
public function isOptional(): bool
{
return $this->optional;
}
public function getType(): Type
{
$type = $this->type;
if ($this->variadic) {
$type = new ArrayType(new IntegerType(), $type);
}
return $type;
}
public function passedByReference(): PassedByReference
{
return $this->passedByReference;
}
public function isVariadic(): bool
{
return $this->variadic;
}
/**
* @param mixed[] $properties
* @return self
*/
public static function __set_state(array $properties): self
{
return new self(
$properties['name'],
$properties['optional'],
$properties['type'],
$properties['passedByReference'],
$properties['variadic']
);
}
}
src/Reflection/Native/NativeMethodReflection.php 0000666 00000005052 13436755504 0016010 0 ustar 00 broker = $broker;
$this->declaringClass = $declaringClass;
$this->reflection = $reflection;
$this->variants = $variants;
}
public function getDeclaringClass(): ClassReflection
{
return $this->declaringClass;
}
public function isStatic(): bool
{
return $this->reflection->isStatic();
}
public function isPrivate(): bool
{
return $this->reflection->isPrivate();
}
public function isPublic(): bool
{
return $this->reflection->isPublic();
}
public function getPrototype(): ClassMemberReflection
{
try {
$prototypeMethod = $this->reflection->getPrototype();
$prototypeDeclaringClass = $this->broker->getClass($prototypeMethod->getDeclaringClass()->getName());
return new MethodPrototypeReflection(
$prototypeDeclaringClass,
$prototypeMethod->isStatic(),
$prototypeMethod->isPrivate(),
$prototypeMethod->isPublic()
);
} catch (\ReflectionException $e) {
return $this;
}
}
public function getName(): string
{
return $this->reflection->getName();
}
/**
* @return \PHPStan\Reflection\ParametersAcceptor[]
*/
public function getVariants(): array
{
return $this->variants;
}
public function isDeprecated(): bool
{
return $this->reflection->isDeprecated();
}
public function isInternal(): bool
{
return false;
}
public function isFinal(): bool
{
return false;
}
}
src/Reflection/Native/NativeFunctionReflection.php 0000666 00000002143 13436755504 0016353 0 ustar 00 name = $name;
$this->variants = $variants;
$this->throwType = $throwType;
}
public function getName(): string
{
return $this->name;
}
/**
* @return \PHPStan\Reflection\ParametersAcceptor[]
*/
public function getVariants(): array
{
return $this->variants;
}
public function getThrowType(): ?Type
{
return $this->throwType;
}
public function isDeprecated(): bool
{
return false;
}
public function isInternal(): bool
{
return false;
}
public function isFinal(): bool
{
return false;
}
}
src/Reflection/ReflectionWithFilename.php 0000666 00000000253 13436755504 0014545 0 ustar 00 $parameters
* @param bool $isVariadic
* @param Type $returnType
* @param Type $phpDocReturnType
* @param Type $nativeReturnType
*/
public function __construct(
array $parameters,
bool $isVariadic,
Type $returnType,
Type $phpDocReturnType,
Type $nativeReturnType
)
{
parent::__construct(
$parameters,
$isVariadic,
$returnType
);
$this->phpDocReturnType = $phpDocReturnType;
$this->nativeReturnType = $nativeReturnType;
}
/**
* @return array
*/
public function getParameters(): array
{
/** @var \PHPStan\Reflection\Php\PhpParameterReflection[] $parameters */
$parameters = parent::getParameters();
return $parameters;
}
public function getPhpDocReturnType(): Type
{
return $this->phpDocReturnType;
}
public function getNativeReturnType(): Type
{
return $this->nativeReturnType;
}
}
src/Reflection/ClassConstantReflection.php 0000666 00000002504 13436755504 0014751 0 ustar 00 declaringClass = $declaringClass;
$this->reflection = $reflection;
$this->isDeprecated = $isDeprecated;
$this->isInternal = $isInternal;
}
public function getName(): string
{
return $this->reflection->getName();
}
/**
* @return mixed
*/
public function getValue()
{
return $this->reflection->getValue();
}
public function getDeclaringClass(): ClassReflection
{
return $this->declaringClass;
}
public function isStatic(): bool
{
return true;
}
public function isPrivate(): bool
{
return $this->reflection->isPrivate();
}
public function isPublic(): bool
{
return $this->reflection->isPublic();
}
public function isDeprecated(): bool
{
return $this->isDeprecated;
}
public function isInternal(): bool
{
return $this->isInternal;
}
}
src/Reflection/MethodPrototypeReflection.php 0000666 00000001574 13436755504 0015346 0 ustar 00 declaringClass = $declaringClass;
$this->isStatic = $isStatic;
$this->isPrivate = $isPrivate;
$this->isPublic = $isPublic;
}
public function getDeclaringClass(): ClassReflection
{
return $this->declaringClass;
}
public function isStatic(): bool
{
return $this->isStatic;
}
public function isPrivate(): bool
{
return $this->isPrivate;
}
public function isPublic(): bool
{
return $this->isPublic;
}
}
src/Reflection/ThrowableReflection.php 0000666 00000000245 13436755504 0014121 0 ustar 00 name = $name;
}
public function getDeclaringClass(): ClassReflection
{
$broker = Broker::getInstance();
return $broker->getClass(\stdClass::class);
}
public function isStatic(): bool
{
return false;
}
public function isPrivate(): bool
{
return false;
}
public function isPublic(): bool
{
return true;
}
public function getName(): string
{
return $this->name;
}
public function getPrototype(): ClassMemberReflection
{
return $this;
}
/**
* @return \PHPStan\Reflection\ParametersAcceptor[]
*/
public function getVariants(): array
{
return [
new TrivialParametersAcceptor(),
];
}
}
src/Reflection/Dummy/DummyPropertyReflection.php 0000666 00000001432 13436755504 0016124 0 ustar 00 getClass(\stdClass::class);
}
public function isStatic(): bool
{
return false;
}
public function isPrivate(): bool
{
return false;
}
public function isPublic(): bool
{
return true;
}
public function getType(): Type
{
return new MixedType();
}
public function isReadable(): bool
{
return true;
}
public function isWritable(): bool
{
return true;
}
}
src/Reflection/Dummy/DummyConstantReflection.php 0000666 00000001554 13436755504 0016076 0 ustar 00 name = $name;
}
public function getDeclaringClass(): ClassReflection
{
$broker = Broker::getInstance();
return $broker->getClass(\stdClass::class);
}
public function isStatic(): bool
{
return true;
}
public function isPrivate(): bool
{
return false;
}
public function isPublic(): bool
{
return true;
}
public function getName(): string
{
return $this->name;
}
/**
* @return mixed
*/
public function getValue()
{
// so that Scope::getTypeFromValue() returns mixed
return new \stdClass();
}
}
src/Reflection/MethodReflection.php 0000666 00000000504 13436755504 0013410 0 ustar 00
*/
public function getParameters(): array;
public function getPhpDocReturnType(): Type;
public function getNativeReturnType(): Type;
}
src/Reflection/InaccessibleMethod.php 0000666 00000001303 13436755504 0013700 0 ustar 00 methodReflection = $methodReflection;
}
public function getMethod(): MethodReflection
{
return $this->methodReflection;
}
/**
* @return array
*/
public function getParameters(): array
{
return [];
}
public function isVariadic(): bool
{
return true;
}
public function getReturnType(): Type
{
return new MixedType();
}
}
src/Reflection/FunctionVariant.php 0000666 00000001600 13436755504 0013265 0 ustar 00 */
private $parameters;
/** @var bool */
private $isVariadic;
/** @var Type */
private $returnType;
/**
* @param array $parameters
* @param bool $isVariadic
* @param Type $returnType
*/
public function __construct(
array $parameters,
bool $isVariadic,
Type $returnType
)
{
$this->parameters = $parameters;
$this->isVariadic = $isVariadic;
$this->returnType = $returnType;
}
/**
* @return array
*/
public function getParameters(): array
{
return $this->parameters;
}
public function isVariadic(): bool
{
return $this->isVariadic;
}
public function getReturnType(): Type
{
return $this->returnType;
}
}
src/Reflection/BrokerAwareClassReflectionExtension.php 0000666 00000000250 13436755504 0017255 0 ustar 00 broker = $broker;
$this->fileTypeMapper = $fileTypeMapper;
$this->propertiesClassReflectionExtensions = $propertiesClassReflectionExtensions;
$this->methodsClassReflectionExtensions = $methodsClassReflectionExtensions;
$this->displayName = $displayName;
$this->reflection = $reflection;
$this->anonymousFilename = $anonymousFilename;
}
public function getNativeReflection(): \ReflectionClass
{
return $this->reflection;
}
/**
* @return string|false
*/
public function getFileName()
{
if ($this->anonymousFilename !== null) {
return $this->anonymousFilename;
}
$fileName = $this->reflection->getFileName();
if ($fileName === false) {
return false;
}
if (!file_exists($fileName)) {
return false;
}
return $fileName;
}
/**
* @return false|\PHPStan\Reflection\ClassReflection
*/
public function getParentClass()
{
if ($this->reflection->getParentClass() === false) {
return false;
}
return $this->broker->getClass($this->reflection->getParentClass()->getName());
}
public function getName(): string
{
return $this->reflection->getName();
}
public function getDisplayName(): string
{
return $this->displayName;
}
/**
* @return int[]
*/
public function getClassHierarchyDistances(): array
{
if ($this->classHierarchyDistances === null) {
$distance = 0;
$distances = [
$this->getName() => $distance,
];
$currentClassReflection = $this->getNativeReflection();
foreach ($this->getNativeReflection()->getTraits() as $trait) {
$distance++;
if (array_key_exists($trait->getName(), $distances)) {
continue;
}
$distances[$trait->getName()] = $distance;
}
while ($currentClassReflection->getParentClass() !== false) {
$distance++;
$parentClassName = $currentClassReflection->getParentClass()->getName();
if (!array_key_exists($parentClassName, $distances)) {
$distances[$parentClassName] = $distance;
}
$currentClassReflection = $currentClassReflection->getParentClass();
foreach ($currentClassReflection->getTraits() as $trait) {
$distance++;
if (array_key_exists($trait->getName(), $distances)) {
continue;
}
$distances[$trait->getName()] = $distance;
}
}
foreach ($this->getNativeReflection()->getInterfaces() as $interface) {
$distance++;
if (array_key_exists($interface->getName(), $distances)) {
continue;
}
$distances[$interface->getName()] = $distance;
}
$this->classHierarchyDistances = $distances;
}
return $this->classHierarchyDistances;
}
public function hasProperty(string $propertyName): bool
{
foreach ($this->propertiesClassReflectionExtensions as $extension) {
if ($extension->hasProperty($this, $propertyName)) {
return true;
}
}
return false;
}
public function hasMethod(string $methodName): bool
{
foreach ($this->methodsClassReflectionExtensions as $extension) {
if ($extension->hasMethod($this, $methodName)) {
return true;
}
}
return false;
}
public function getMethod(string $methodName, ClassMemberAccessAnswerer $scope): MethodReflection
{
$key = $methodName;
if ($scope->isInClass()) {
$key = sprintf('%s-%s', $key, $scope->getClassReflection()->getName());
}
if (!isset($this->methods[$key])) {
foreach ($this->methodsClassReflectionExtensions as $extension) {
if (!$extension->hasMethod($this, $methodName)) {
continue;
}
$method = $extension->getMethod($this, $methodName);
if ($scope->canCallMethod($method)) {
return $this->methods[$key] = $method;
}
$this->methods[$key] = $method;
}
}
if (!isset($this->methods[$key])) {
$filename = $this->getFileName();
throw new \PHPStan\Reflection\MissingMethodFromReflectionException($this->getName(), $methodName, $filename !== false ? $filename : null);
}
return $this->methods[$key];
}
public function hasNativeMethod(string $methodName): bool
{
return $this->getPhpExtension()->hasNativeMethod($this, $methodName);
}
public function getNativeMethod(string $methodName): MethodReflection
{
if (!$this->hasNativeMethod($methodName)) {
$filename = $this->getFileName();
throw new \PHPStan\Reflection\MissingMethodFromReflectionException($this->getName(), $methodName, $filename !== false ? $filename : null);
}
return $this->getPhpExtension()->getNativeMethod($this, $methodName);
}
public function hasConstructor(): bool
{
return $this->reflection->getConstructor() !== null;
}
public function getConstructor(): MethodReflection
{
$constructor = $this->reflection->getConstructor();
if ($constructor === null) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->getNativeMethod($constructor->getName());
}
private function getPhpExtension(): PhpClassReflectionExtension
{
$extension = $this->methodsClassReflectionExtensions[0];
if (!$extension instanceof PhpClassReflectionExtension) {
throw new \PHPStan\ShouldNotHappenException();
}
return $extension;
}
public function getProperty(string $propertyName, ClassMemberAccessAnswerer $scope): PropertyReflection
{
$key = $propertyName;
if ($scope->isInClass()) {
$key = sprintf('%s-%s', $key, $scope->getClassReflection()->getName());
}
if (!isset($this->properties[$key])) {
foreach ($this->propertiesClassReflectionExtensions as $extension) {
if (!$extension->hasProperty($this, $propertyName)) {
continue;
}
$property = $extension->getProperty($this, $propertyName);
if ($scope->canAccessProperty($property)) {
return $this->properties[$key] = $property;
}
$this->properties[$key] = $property;
}
}
if (!isset($this->properties[$key])) {
$filename = $this->getFileName();
throw new \PHPStan\Reflection\MissingPropertyFromReflectionException($this->getName(), $propertyName, $filename !== false ? $filename : null);
}
return $this->properties[$key];
}
public function hasNativeProperty(string $propertyName): bool
{
return $this->getPhpExtension()->hasProperty($this, $propertyName);
}
public function getNativeProperty(string $propertyName): PhpPropertyReflection
{
if (!$this->hasNativeProperty($propertyName)) {
$filename = $this->getFileName();
throw new \PHPStan\Reflection\MissingPropertyFromReflectionException($this->getName(), $propertyName, $filename !== false ? $filename : null);
}
return $this->getPhpExtension()->getNativeProperty($this, $propertyName);
}
public function isAbstract(): bool
{
return $this->reflection->isAbstract();
}
public function isInterface(): bool
{
return $this->reflection->isInterface();
}
public function isTrait(): bool
{
return $this->reflection->isTrait();
}
public function isAnonymous(): bool
{
return $this->anonymousFilename !== null;
}
public function isSubclassOf(string $className): bool
{
return $this->reflection->isSubclassOf($className);
}
/**
* @return \PHPStan\Reflection\ClassReflection[]
*/
public function getParents(): array
{
$parents = [];
$parent = $this->getParentClass();
while ($parent !== false) {
$parents[] = $parent;
$parent = $parent->getParentClass();
}
return $parents;
}
/**
* @return \PHPStan\Reflection\ClassReflection[]
*/
public function getInterfaces(): array
{
return array_map(function (\ReflectionClass $interface) {
return $this->broker->getClass($interface->getName());
}, $this->getNativeReflection()->getInterfaces());
}
/**
* @return \PHPStan\Reflection\ClassReflection[]
*/
public function getTraits(): array
{
return array_map(function (\ReflectionClass $trait) {
return $this->broker->getClass($trait->getName());
}, $this->getNativeReflection()->getTraits());
}
/**
* @return string[]
*/
public function getParentClassesNames(): array
{
$parentNames = [];
$currentClassReflection = $this;
while ($currentClassReflection->getParentClass() !== false) {
$parentNames[] = $currentClassReflection->getParentClass()->getName();
$currentClassReflection = $currentClassReflection->getParentClass();
}
return $parentNames;
}
public function hasConstant(string $name): bool
{
return $this->getNativeReflection()->hasConstant($name);
}
public function getConstant(string $name): ConstantReflection
{
if (!isset($this->constants[$name])) {
$reflectionConstant = $this->getNativeReflection()->getReflectionConstant($name);
$isDeprecated = false;
$isInternal = false;
if ($reflectionConstant->getDocComment() !== false && $this->getFileName() !== false) {
$docComment = $reflectionConstant->getDocComment();
$fileName = $this->getFileName();
$className = $reflectionConstant->getDeclaringClass()->getName();
$resolvedPhpDoc = $this->fileTypeMapper->getResolvedPhpDoc($fileName, $className, null, $docComment);
$isDeprecated = $resolvedPhpDoc->isDeprecated();
$isInternal = $resolvedPhpDoc->isInternal();
}
$this->constants[$name] = new ClassConstantReflection(
$this->broker->getClass($reflectionConstant->getDeclaringClass()->getName()),
$reflectionConstant,
$isDeprecated,
$isInternal
);
}
return $this->constants[$name];
}
public function hasTraitUse(string $traitName): bool
{
return in_array($traitName, $this->getTraitNames(), true);
}
/**
* @return string[]
*/
private function getTraitNames(): array
{
$class = $this->reflection;
$traitNames = $class->getTraitNames();
while ($class->getParentClass() !== false) {
$traitNames = array_values(array_unique(array_merge($traitNames, $class->getParentClass()->getTraitNames())));
$class = $class->getParentClass();
}
return $traitNames;
}
public function isDeprecated(): bool
{
if ($this->isDeprecated === null) {
$resolvedPhpDoc = $this->getResolvedPhpDoc();
$this->isDeprecated = $resolvedPhpDoc !== null && $resolvedPhpDoc->isDeprecated();
}
return $this->isDeprecated;
}
public function isInternal(): bool
{
if ($this->isInternal === null) {
$resolvedPhpDoc = $this->getResolvedPhpDoc();
$this->isInternal = $resolvedPhpDoc !== null && $resolvedPhpDoc->isInternal();
}
return $this->isInternal;
}
public function isFinal(): bool
{
if ($this->isFinal === null) {
$resolvedPhpDoc = $this->getResolvedPhpDoc();
$this->isFinal = $this->reflection->isFinal()
|| ($resolvedPhpDoc !== null && $resolvedPhpDoc->isFinal());
}
return $this->isFinal;
}
private function getResolvedPhpDoc(): ?ResolvedPhpDocBlock
{
$fileName = $this->reflection->getFileName();
if ($fileName === false) {
return null;
}
$docComment = $this->reflection->getDocComment();
if ($docComment === false) {
return null;
}
return $this->fileTypeMapper->getResolvedPhpDoc($fileName, $this->getName(), null, $docComment);
}
}
src/Reflection/InternableReflection.php 0000666 00000000213 13436755504 0014250 0 ustar 00 > */
private static $defaultProperties = [
\DateInterval::class => [
'y' => 'int',
'm' => 'int',
'd' => 'int',
'h' => 'int',
'i' => 'int',
's' => 'int',
'invert' => 'int',
'days' => 'mixed',
'f' => 'float',
],
\DatePeriod::class => [
'recurrences' => 'int',
'include_start_date' => 'bool',
'start' => \DateTimeInterface::class,
'current' => \DateTimeInterface::class,
'end' => \DateTimeInterface::class,
'interval' => \DateInterval::class,
],
'Directory' => [
'handle' => 'resource',
'path' => 'string',
],
'DOMAttr' => [ // extends DOMNode
'name' => 'string',
'ownerElement' => 'DOMElement',
'schemaTypeInfo' => 'bool',
'specified' => 'bool',
'value' => 'string',
],
'DOMCharacterData' => [ // extends DOMNode
'data' => 'string',
'length' => 'int',
],
'DOMDocument' => [
'actualEncoding' => 'string',
'config' => 'DOMConfiguration',
'doctype' => 'DOMDocumentType',
'documentElement' => 'DOMElement',
'documentURI' => 'string',
'encoding' => 'string',
'formatOutput' => 'bool',
'implementation' => 'DOMImplementation',
'preserveWhiteSpace' => 'bool',
'recover' => 'bool',
'resolveExternals' => 'bool',
'standalone' => 'bool',
'strictErrorChecking' => 'bool',
'substituteEntities' => 'bool',
'validateOnParse' => 'bool',
'version' => 'string',
'xmlEncoding' => 'string',
'xmlStandalone' => 'bool',
'xmlVersion' => 'string',
],
'DOMDocumentType' => [ // extends DOMNode
'publicId' => 'string',
'systemId' => 'string',
'name' => 'string',
'entities' => 'DOMNamedNodeMap',
'notations' => 'DOMNamedNodeMap',
'internalSubset' => 'string',
],
'DOMElement' => [ // extends DOMNode
'schemaTypeInfo' => 'bool',
'tagName' => 'string',
],
'DOMEntity' => [ // extends DOMNode
'publicId' => 'string',
'systemId' => 'string',
'notationName' => 'string',
'actualEncoding' => 'string',
'encoding' => 'string',
'version' => 'string',
],
'DOMNamedNodeMap' => [
'length' => 'int',
],
'DOMNode' => [
'nodeName' => 'string',
'nodeValue' => 'string',
'nodeType' => 'int',
'parentNode' => 'DOMNode',
'childNodes' => 'DOMNodeList',
'firstChild' => 'DOMNode',
'lastChild' => 'DOMNode',
'previousSibling' => 'DOMNode',
'nextSibling' => 'DOMNode',
'attributes' => 'DOMNamedNodeMap',
'ownerDocument' => 'DOMDocument',
'namespaceURI' => 'string',
'prefix' => 'string',
'localName' => 'string',
'baseURI' => 'string',
'textContent' => 'string',
],
'DOMNodeList' => [
'length' => 'int',
],
'DOMNotation' => [ // extends DOMNode
'publicId' => 'string',
'systemId' => 'string',
],
'DOMProcessingInstruction' => [ // extends DOMNode
'target' => 'string',
'data' => 'string',
],
'DOMText' => [ // extends DOMCharacterData
'wholeText' => 'string',
],
'DOMXPath' => [ // extends DOMCharacterData
'document' => 'DOMDocument',
],
'Ds\\Pair' => [
'key' => 'mixed',
'value' => 'mixed',
],
'XMLReader' => [
'attributeCount' => 'int',
'baseURI' => 'string',
'depth' => 'int',
'hasAttributes' => 'bool',
'hasValue' => 'bool',
'isDefault' => 'bool',
'isEmptyElement' => 'bool',
'localName' => 'string',
'name' => 'string',
'namespaceURI' => 'string',
'nodeType' => 'int',
'prefix' => 'string',
'value' => 'string',
'xmlLang' => 'string',
],
'ZipArchive' => [
'status' => 'int',
'statusSys' => 'int',
'numFiles' => 'int',
'filename' => 'string',
'comment' => 'string',
],
'LibXMLError' => [
'level' => 'int',
'code' => 'int',
'column' => 'int',
'message' => 'string',
'file' => 'string',
'line' => 'int',
],
];
/** @var TypeStringResolver */
private $typeStringResolver;
/** @var string[][] */
private $properties = [];
public function __construct(TypeStringResolver $typeStringResolver)
{
$this->typeStringResolver = $typeStringResolver;
$this->properties = self::$defaultProperties;
}
public function hasProperty(ClassReflection $classReflection, string $propertyName): bool
{
$classWithProperties = $this->getClassWithProperties($classReflection, $propertyName);
return $classWithProperties !== null;
}
public function getProperty(ClassReflection $classReflection, string $propertyName): PropertyReflection
{
/** @var \PHPStan\Reflection\ClassReflection $classWithProperties */
$classWithProperties = $this->getClassWithProperties($classReflection, $propertyName);
$typeString = $this->properties[$classWithProperties->getName()][$propertyName];
return new PhpDefectPropertyReflection(
$classWithProperties,
$this->typeStringResolver->resolve($typeString)
);
}
private function getClassWithProperties(ClassReflection $classReflection, string $propertyName): ?\PHPStan\Reflection\ClassReflection
{
if (isset($this->properties[$classReflection->getName()][$propertyName])) {
return $classReflection;
}
foreach ($classReflection->getParents() as $parentClass) {
if (isset($this->properties[$parentClass->getName()][$propertyName])) {
return $parentClass;
}
}
return null;
}
}
src/Reflection/PhpDefect/PhpDefectPropertyReflection.php 0000666 00000001714 13436755504 0017445 0 ustar 00 declaringClass = $declaringClass;
$this->type = $type;
}
public function getDeclaringClass(): ClassReflection
{
return $this->declaringClass;
}
public function isStatic(): bool
{
return false;
}
public function isPrivate(): bool
{
return false;
}
public function isPublic(): bool
{
return true;
}
public function getType(): Type
{
return $this->type;
}
public function isReadable(): bool
{
return true;
}
public function isWritable(): bool
{
return true;
}
}
src/Reflection/MissingPropertyFromReflectionException.php 0000666 00000001101 13436755504 0020043 0 ustar 00 ' => [', ''=>'']
* alternative signature for the same function
* '' => [', ''=>'']
*
* A '&' in front of the means the arg is always passed by reference.
* (i.e. ReflectionParameter->isPassedByReference())
* This was previously only used in cases where the function actually created the
* variable in the local scope.
* Some reference arguments will have prefixes in to indicate the way the argument is used.
* Currently, the only prefixes with meaning are 'rw_' (read-write) and 'w_' (write).
* Those prefixes don't mean anything for non-references.
* Code using these signatures should remove those prefixes from messages rendered to the user.
* 1. '&rw_' indicates that a parameter with a value is expected to be passed in, and may be modified.
* Phan will warn if the variable has an incompatible type, or is undefined.
* 2. '&w_' indicates that a parameter is expected to be passed in, and the value will be ignored, and may be overwritten.
* 3. The absence of a prefix is treated by Phan the same way as having the prefix 'w_' (Some may be changed to 'rw_name'). These will have prefixes added later.
*
* So, for functions like sort() where technically the arg is by-ref,
* indicate the reference param's signature by-ref and read-write,
* as `'&rw_array'=>'array'`
* so that Phan won't create it in the local scope
*
* However, for a function like preg_match() where the 3rd arg is an array of sub-pattern matches (and optional),
* this arg needs to be marked as by-ref and write-only, as `'&w_matches='=>'array'`.
*
* A '=' following the indicates this arg is optional.
*
* The can begin with '...' to indicate the arg is variadic.
* '...args=' indicates it is both variadic and optional.
*
* Some reference arguments will have prefixes in to indicate the way the argument is used.
* Currently, the only prefixes with meaning are 'rw_' and 'w_'.
* Code using these signatures should remove those prefixes from messages rendered to the user.
* 1. '&rw_name' indicates that a parameter with a value is expected to be passed in, and may be modified.
* 2. '&w_name' indicates that a parameter is expected to be passed in, and the value will be ignored, and may be overwritten.
*
* Sources of stub info:
*
* 1. Reflection
* 2. docs.php.net's SVN repo or website, and examples (See internal/internalsignatures.php)
* 3. Various websites documenting individual extensions
* 4. PHPStorm stubs (For anything missing from the above sources)
* See internal/internalsignatures.php
*/
return [
'_' => ['string', 'message'=>'string'],
'__halt_compiler' => ['void'],
'abs' => ['int', 'number'=>'int'],
'abs\'1' => ['float', 'number'=>'float'],
'accelerator_get_configuration' => ['array'],
'accelerator_get_scripts' => ['array'],
'accelerator_get_status' => ['array', 'fetch_scripts'=>'bool'],
'accelerator_reset' => [''],
'accelerator_set_status' => ['void', 'status'=>''],
'acos' => ['float', 'number'=>'float'],
'acosh' => ['float', 'number'=>'float'],
'addcslashes' => ['string', 'str'=>'string', 'charlist'=>'string'],
'addslashes' => ['string', 'str'=>'string'],
'AMQPChannel::__construct' => ['void', 'amqp_connection'=>'AMQPConnection'],
'AMQPChannel::basicRecover' => ['', 'requeue='=>'bool|true'],
'AMQPChannel::commitTransaction' => ['bool'],
'AMQPChannel::getChannelId' => ['int'],
'AMQPChannel::getConnection' => ['AMQPConnection'],
'AMQPChannel::getPrefetchCount' => ['int'],
'AMQPChannel::getPrefetchSize' => ['int'],
'AMQPChannel::isConnected' => ['bool'],
'AMQPChannel::qos' => ['bool', 'size'=>'int', 'count'=>'int'],
'AMQPChannel::rollbackTransaction' => ['bool'],
'AMQPChannel::setPrefetchCount' => ['bool', 'count'=>'int'],
'AMQPChannel::setPrefetchSize' => ['bool', 'size'=>'int'],
'AMQPChannel::startTransaction' => ['bool'],
'AMQPConnection::__construct' => ['void', 'credentials='=>'array'],
'AMQPConnection::connect' => ['bool'],
'AMQPConnection::disconnect' => ['bool'],
'AMQPConnection::getHost' => ['string'],
'AMQPConnection::getLogin' => ['string'],
'AMQPConnection::getMaxChannels' => ['int|null'],
'AMQPConnection::getPassword' => ['string'],
'AMQPConnection::getPort' => ['int'],
'AMQPConnection::getReadTimeout' => ['float'],
'AMQPConnection::getTimeout' => ['float'],
'AMQPConnection::getUsedChannels' => ['int'],
'AMQPConnection::getVhost' => ['string'],
'AMQPConnection::getWriteTimeout' => ['float'],
'AMQPConnection::isConnected' => ['bool'],
'AMQPConnection::isPersistent' => ['bool|null'],
'AMQPConnection::pconnect' => ['bool'],
'AMQPConnection::pdisconnect' => ['bool'],
'AMQPConnection::preconnect' => ['bool'],
'AMQPConnection::reconnect' => ['bool'],
'AMQPConnection::setHost' => ['bool', 'host'=>'string'],
'AMQPConnection::setLogin' => ['bool', 'login'=>'string'],
'AMQPConnection::setPassword' => ['bool', 'password'=>'string'],
'AMQPConnection::setPort' => ['bool', 'port'=>'int'],
'AMQPConnection::setReadTimeout' => ['bool', 'timeout'=>'int'],
'AMQPConnection::setTimeout' => ['bool', 'timeout'=>'int'],
'AMQPConnection::setVhost' => ['bool', 'vhost'=>'string'],
'AMQPConnection::setWriteTimeout' => ['bool', 'timeout'=>'int'],
'AMQPEnvelope::getAppId' => ['string'],
'AMQPEnvelope::getBody' => ['string'],
'AMQPEnvelope::getContentEncoding' => ['string'],
'AMQPEnvelope::getContentType' => ['string'],
'AMQPEnvelope::getCorrelationId' => ['string'],
'AMQPEnvelope::getDeliveryMode' => ['int'],
'AMQPEnvelope::getDeliveryTag' => ['string'],
'AMQPEnvelope::getExchangeName' => ['string'],
'AMQPEnvelope::getExpiration' => ['string'],
'AMQPEnvelope::getHeader' => ['bool|string', 'header_key'=>'string'],
'AMQPEnvelope::getHeaders' => ['array'],
'AMQPEnvelope::getMessageId' => ['string'],
'AMQPEnvelope::getPriority' => ['int'],
'AMQPEnvelope::getReplyTo' => ['string'],
'AMQPEnvelope::getRoutingKey' => ['string'],
'AMQPEnvelope::getTimeStamp' => ['string'],
'AMQPEnvelope::getType' => ['string'],
'AMQPEnvelope::getUserId' => ['string'],
'AMQPEnvelope::isRedelivery' => ['bool'],
'AMQPExchange::__construct' => ['void', 'amqp_channel'=>'AMQPChannel'],
'AMQPExchange::bind' => ['bool', 'exchange_name'=>'string', 'routing_key='=>'string', 'arguments='=>'array'],
'AMQPExchange::declareExchange' => ['bool'],
'AMQPExchange::delete' => ['bool', 'exchangeName='=>'string', 'flags='=>'int'],
'AMQPExchange::getArgument' => ['bool|int|string', 'key'=>'string'],
'AMQPExchange::getArguments' => ['array'],
'AMQPExchange::getChannel' => ['AMQPChannel'],
'AMQPExchange::getConnection' => ['AMQPConnection'],
'AMQPExchange::getFlags' => ['int'],
'AMQPExchange::getName' => ['string'],
'AMQPExchange::getType' => ['string'],
'AMQPExchange::publish' => ['bool', 'message'=>'string', 'routing_key='=>'string', 'flags='=>'int', 'attributes='=>'array'],
'AMQPExchange::setArgument' => ['bool', 'key'=>'string', 'value'=>'int|string'],
'AMQPExchange::setArguments' => ['bool', 'arguments'=>'array'],
'AMQPExchange::setFlags' => ['bool', 'flags'=>'int'],
'AMQPExchange::setName' => ['bool', 'exchange_name'=>'string'],
'AMQPExchange::setType' => ['bool', 'exchange_type'=>'string'],
'AMQPExchange::unbind' => ['bool', 'exchange_name'=>'string', 'routing_key='=>'string', 'arguments='=>'array'],
'AMQPQueue::__construct' => ['void', 'amqp_channel'=>'AMQPChannel'],
'AMQPQueue::ack' => ['bool', 'delivery_tag'=>'string', 'flags='=>'int'],
'AMQPQueue::bind' => ['bool', 'exchange_name'=>'string', 'routing_key='=>'string', 'arguments='=>'array'],
'AMQPQueue::cancel' => ['bool', 'consumer_tag='=>'string'],
'AMQPQueue::consume' => ['void', 'callback='=>'?callable', 'flags='=>'int', 'consumerTag='=>'string'],
'AMQPQueue::declareQueue' => ['int'],
'AMQPQueue::delete' => ['int', 'flags='=>'int'],
'AMQPQueue::get' => ['AMQPEnvelope|bool', 'flags='=>'int'],
'AMQPQueue::getArgument' => ['bool|int|string', 'key'=>'string'],
'AMQPQueue::getArguments' => ['array'],
'AMQPQueue::getChannel' => ['AMQPChannel'],
'AMQPQueue::getConnection' => ['AMQPConnection'],
'AMQPQueue::getFlags' => ['int'],
'AMQPQueue::getName' => ['string'],
'AMQPQueue::nack' => ['bool', 'delivery_tag'=>'string', 'flags='=>'int'],
'AMQPQueue::purge' => ['bool'],
'AMQPQueue::reject' => ['bool', 'delivery_tag'=>'string', 'flags='=>'int'],
'AMQPQueue::setArgument' => ['bool', 'key'=>'string', 'value'=>'mixed'],
'AMQPQueue::setArguments' => ['bool', 'arguments'=>'array'],
'AMQPQueue::setFlags' => ['bool', 'flags'=>'int'],
'AMQPQueue::setName' => ['bool', 'queue_name'=>'string'],
'AMQPQueue::unbind' => ['bool', 'exchange_name'=>'string', 'routing_key='=>'string', 'arguments='=>'array'],
'apache_child_terminate' => ['bool'],
'apache_get_modules' => ['array'],
'apache_get_version' => ['string|false'],
'apache_getenv' => ['string|false', 'variable'=>'string', 'walk_to_top='=>'bool'],
'apache_lookup_uri' => ['object', 'filename'=>'string'],
'apache_note' => ['string|false', 'note_name'=>'string', 'note_value='=>'string'],
'apache_request_headers' => ['array|false'],
'apache_reset_timeout' => ['bool'],
'apache_response_headers' => ['array|false'],
'apache_setenv' => ['bool', 'variable'=>'string', 'value'=>'string', 'walk_to_top='=>'bool'],
'apc_add' => ['bool', 'key'=>'string', 'ttl='=>'int'],
'apc_add\'1' => ['array', 'values'=>'array', 'unused='=>'', 'ttl='=>'int'],
'apc_bin_dump' => ['string', 'files='=>'array', 'user_vars='=>'array'],
'apc_bin_dumpfile' => ['int', 'files'=>'array', 'user_vars'=>'array', 'filename'=>'string', 'flags='=>'int', 'context='=>'resource'],
'apc_bin_load' => ['bool', 'data'=>'string', 'flags='=>'int'],
'apc_bin_loadfile' => ['bool', 'filename'=>'string', 'context='=>'resource', 'flags='=>'int'],
'apc_cache_info' => ['array', 'cache_type='=>'string', 'limited='=>'bool'],
'apc_cas' => ['bool', 'key'=>'string', 'old'=>'int', 'new'=>'int'],
'apc_clear_cache' => ['bool', 'cache_type='=>'string'],
'apc_compile_file' => ['mixed', 'filename'=>'string', 'atomic='=>'bool'],
'apc_dec' => ['int', 'key'=>'string', 'step='=>'int', '&w_success='=>'bool'],
'apc_define_constants' => ['bool', 'key'=>'string', 'constants'=>'array', 'case_sensitive='=>'bool'],
'apc_delete' => ['bool', 'key'=>'string|string[]|APCIterator'],
'apc_delete_file' => ['mixed', 'keys'=>'mixed'],
'apc_exists' => ['bool', 'keys'=>'string'],
'apc_exists\'1' => ['array', 'keys'=>'string[]'],
'apc_fetch' => ['mixed', 'key'=>'mixed', '&w_success='=>'bool'],
'apc_inc' => ['int', 'key'=>'string', 'step='=>'int', '&w_success='=>'bool'],
'apc_load_constants' => ['bool', 'key'=>'string', 'case_sensitive='=>'bool'],
'apc_sma_info' => ['array', 'limited='=>'bool'],
'apc_store' => ['bool', 'key'=>'string', 'var'=>'', 'ttl='=>'int'],
'apc_store\'1' => ['array', 'values'=>'array', 'unused='=>'', 'ttl='=>'int'],
'APCIterator::__construct' => ['void', 'cache'=>'string', 'search='=>'', 'format='=>'int', 'chunk_size='=>'int', 'list='=>'int'],
'APCIterator::current' => ['mixed'],
'APCIterator::getTotalCount' => ['int'],
'APCIterator::getTotalHits' => ['int'],
'APCIterator::getTotalSize' => ['int'],
'APCIterator::key' => ['string'],
'APCIterator::next' => ['void'],
'APCIterator::rewind' => ['void'],
'APCIterator::valid' => ['bool'],
'apcu_add' => ['bool', 'key'=>'string', 'var'=>'', 'ttl='=>'int'],
'apcu_add\'1' => ['array', 'values'=>'array', 'unused='=>'', 'ttl='=>'int'],
'apcu_cache_info' => ['array', 'limited='=>'bool'],
'apcu_cas' => ['bool', 'key'=>'string', 'old'=>'int', 'new'=>'int'],
'apcu_clear_cache' => ['bool'],
'apcu_dec' => ['int', 'key'=>'string', 'step='=>'int', '&w_success='=>'bool'],
'apcu_delete' => ['bool|array', 'key'=>'string|string[]|APCUIterator'],
'apcu_entry' => ['mixed', 'key'=>'string', 'generator'=>'callable', 'ttl='=>'int'],
'apcu_exists' => ['bool', 'keys'=>'string'],
'apcu_exists\'1' => ['array', 'keys'=>'string[]'],
'apcu_fetch' => ['mixed', 'key'=>'string|string[]', '&w_success='=>'bool'],
'apcu_inc' => ['int', 'key'=>'string', 'step='=>'int', '&w_success='=>'bool'],
'apcu_sma_info' => ['array', 'limited='=>'bool'],
'apcu_store' => ['bool', 'key'=>'string', 'var='=>'', 'ttl='=>'int'],
'apcu_store\'1' => ['array', 'values'=>'array', 'unused='=>'', 'ttl='=>'int'],
'APCUIterator::__construct' => ['void', 'search='=>'string|string[]|null', 'format='=>'int', 'chunk_size='=>'int', 'list='=>'int'],
'APCUIterator::current' => ['mixed'],
'APCUIterator::getTotalCount' => ['int'],
'APCUIterator::getTotalHits' => ['int'],
'APCUIterator::getTotalSize' => ['int'],
'APCUIterator::key' => ['string'],
'APCUIterator::next' => ['void'],
'APCUIterator::rewind' => ['void'],
'APCUIterator::valid' => ['bool'],
'apd_breakpoint' => ['bool', 'debug_level'=>'int'],
'apd_callstack' => ['array'],
'apd_clunk' => ['void', 'warning'=>'string', 'delimiter='=>'string'],
'apd_continue' => ['bool', 'debug_level'=>'int'],
'apd_croak' => ['void', 'warning'=>'string', 'delimiter='=>'string'],
'apd_dump_function_table' => ['void'],
'apd_dump_persistent_resources' => ['array'],
'apd_dump_regular_resources' => ['array'],
'apd_echo' => ['bool', 'output'=>'string'],
'apd_get_active_symbols' => ['array'],
'apd_set_pprof_trace' => ['string', 'dump_directory='=>'string', 'fragment='=>'string'],
'apd_set_session' => ['void', 'debug_level'=>'int'],
'apd_set_session_trace' => ['void', 'debug_level'=>'int', 'dump_directory='=>'string'],
'apd_set_session_trace_socket' => ['bool', 'tcp_server'=>'string', 'socket_type'=>'int', 'port'=>'int', 'debug_level'=>'int'],
'AppendIterator::__construct' => ['void'],
'AppendIterator::append' => ['void', 'it'=>'iterator'],
'AppendIterator::current' => ['mixed'],
'AppendIterator::getArrayIterator' => ['ArrayIterator'],
'AppendIterator::getInnerIterator' => ['iterator'],
'AppendIterator::getIteratorIndex' => ['int'],
'AppendIterator::key' => ['mixed'],
'AppendIterator::next' => ['void'],
'AppendIterator::rewind' => ['void'],
'AppendIterator::valid' => ['bool'],
'array_change_key_case' => ['array', 'input'=>'array', 'case='=>'int'],
'array_chunk' => ['array[]', 'input'=>'array', 'size'=>'int', 'preserve_keys='=>'bool'],
'array_column' => ['array', 'array'=>'array', 'column_key'=>'mixed', 'index_key='=>'mixed'],
'array_combine' => ['array|false', 'keys'=>'array', 'values'=>'array'],
'array_count_values' => ['int[]', 'input'=>'array'],
'array_diff' => ['array', 'arr1'=>'array', 'arr2'=>'array', '...args='=>'array'],
'array_diff_assoc' => ['array', 'arr1'=>'array', 'arr2'=>'array', '...args='=>'array'],
'array_diff_key' => ['array', 'arr1'=>'array', 'arr2'=>'array', '...args='=>'array'],
'array_diff_uassoc' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'data_comp_func'=>'callable'],
'array_diff_uassoc\'1' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable', '...rest='=>'array|callable'],
'array_diff_ukey' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'key_comp_func'=>'callable'],
'array_diff_ukey\'1' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable', '...rest='=>'array|callable'],
'array_fill' => ['array', 'start_key'=>'int', 'num'=>'int', 'val'=>'mixed'],
'array_fill_keys' => ['array', 'keys'=>'array', 'val'=>'mixed'],
'array_filter' => ['array', 'input'=>'array', 'callback='=>'callable', 'flag='=>'int'],
'array_flip' => ['array', 'input'=>'array'],
'array_intersect' => ['array', 'arr1'=>'array', 'arr2'=>'array', '...args='=>'array'],
'array_intersect_assoc' => ['array', 'arr1'=>'array', 'arr2'=>'array', '...args='=>'array'],
'array_intersect_key' => ['array', 'arr1'=>'array', 'arr2'=>'array', '...args='=>'array'],
'array_intersect_uassoc' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'key_compare_func'=>'callable'],
'array_intersect_uassoc\'1' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable', '...rest'=>'array|callable'],
'array_intersect_ukey' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'key_compare_func'=>'callable'],
'array_intersect_ukey\'1' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable', '...rest'=>'array|callable'],
'array_key_exists' => ['bool', 'key'=>'string|int', 'search'=>'array'],
'array_keys' => ['array', 'input'=>'array', 'search_value='=>'mixed', 'strict='=>'bool'],
'array_map' => ['array', 'callback'=>'?callable', 'input1'=>'array', '...args='=>'array'],
'array_merge' => ['array', 'arr1'=>'array', '...args='=>'array'],
'array_merge_recursive' => ['array', 'arr1'=>'array', '...args='=>'array'],
'array_multisort' => ['bool', '&rw_array1'=>'array', 'array1_sort_order='=>'array|int', 'array1_sort_flags='=>'array|int', '...args='=>'array|int'],
'array_pad' => ['array', 'input'=>'array', 'pad_size'=>'int', 'pad_value'=>'mixed'],
'array_pop' => ['mixed', '&rw_stack'=>'array'],
'array_product' => ['int|float', 'input'=>'array'],
'array_push' => ['int', '&rw_stack'=>'array', 'var'=>'mixed', '...vars='=>'mixed'],
'array_rand' => ['int|string|array|array', 'input'=>'array', 'num_req'=>'int'],
'array_rand\'1' => ['int|string', 'input'=>'array'],
'array_reduce' => ['mixed', 'input'=>'array', 'callback'=>'callable', 'initial='=>'mixed'],
'array_replace' => ['array', 'arr1'=>'array', 'arr2'=>'array', '...args='=>'array'],
'array_replace_recursive' => ['array', 'arr1'=>'array', 'arr2'=>'array', '...args='=>'array'],
'array_reverse' => ['array', 'input'=>'array', 'preserve='=>'bool'],
'array_search' => ['int|string|false', 'needle'=>'mixed', 'haystack'=>'array', 'strict='=>'bool'],
'array_shift' => ['mixed', '&rw_stack'=>'array'],
'array_slice' => ['array', 'input'=>'array', 'offset'=>'int', 'length='=>'?int', 'preserve_keys='=>'bool'],
'array_splice' => ['array', '&rw_input'=>'array', 'offset'=>'int', 'length='=>'int', 'replacement='=>'array|string'],
'array_sum' => ['int|float', 'input'=>'array'],
'array_udiff' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'data_comp_func'=>'callable'],
'array_udiff\'1' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable', '...rest='=>'array|callable'],
'array_udiff_assoc' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'key_comp_func'=>'callable'],
'array_udiff_assoc\'1' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable', '...rest='=>'array|callable'],
'array_udiff_uassoc' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'data_comp_func'=>'callable', 'key_comp_func'=>'callable'],
'array_udiff_uassoc\'1' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable', 'arg5'=>'array|callable', '...rest='=>'array|callable'],
'array_uintersect' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'data_compare_func'=>'callable'],
'array_uintersect\'1' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable', '...rest='=>'array|callable'],
'array_uintersect_assoc' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'data_compare_func'=>'callable'],
'array_uintersect_assoc\'1' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable', '...rest='=>'array|callable'],
'array_uintersect_uassoc' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'data_compare_func'=>'callable', 'key_compare_func'=>'callable'],
'array_uintersect_uassoc\'1' => ['array', 'arr1'=>'array', 'arr2'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable', 'arg5'=>'array|callable', '...rest='=>'array|callable'],
'array_unique' => ['array', 'input'=>'array', 'sort_flags='=>'int'],
'array_unshift' => ['int', '&rw_stack'=>'array', 'var'=>'mixed', '...vars='=>'mixed'],
'array_values' => ['array', 'input'=>'array'],
'array_walk' => ['bool', '&rw_input'=>'array', 'callback'=>'callable', 'userdata='=>'mixed'],
'array_walk_recursive' => ['bool', '&rw_input'=>'array', 'callback'=>'callable', 'userdata='=>'mixed'],
'ArrayAccess::offsetExists' => ['bool', 'offset'=>'mixed'],
'ArrayAccess::offsetGet' => ['mixed', 'offset'=>'mixed'],
'ArrayAccess::offsetSet' => ['void', 'offset'=>'mixed', 'value'=>'mixed'],
'ArrayAccess::offsetUnset' => ['void', 'offset'=>'mixed'],
'ArrayIterator::__construct' => ['void', 'array='=>'array|object', 'flags='=>'int'],
'ArrayIterator::append' => ['void', 'value'=>'mixed'],
'ArrayIterator::asort' => ['void'],
'ArrayIterator::count' => ['int'],
'ArrayIterator::current' => ['mixed'],
'ArrayIterator::getArrayCopy' => ['array'],
'ArrayIterator::getFlags' => ['void'],
'ArrayIterator::key' => ['int|string|false'],
'ArrayIterator::ksort' => ['void'],
'ArrayIterator::natcasesort' => ['void'],
'ArrayIterator::natsort' => ['void'],
'ArrayIterator::next' => ['void'],
'ArrayIterator::offsetExists' => ['bool', 'index'=>'string'],
'ArrayIterator::offsetGet' => ['mixed', 'index'=>'string'],
'ArrayIterator::offsetSet' => ['void', 'index'=>'string', 'newval'=>'mixed'],
'ArrayIterator::offsetUnset' => ['void', 'index'=>'string'],
'ArrayIterator::rewind' => ['void'],
'ArrayIterator::seek' => ['void', 'position'=>'int'],
'ArrayIterator::serialize' => ['string'],
'ArrayIterator::setFlags' => ['void', 'flags'=>'string'],
'ArrayIterator::uasort' => ['void', 'cmp_function'=>'callable'],
'ArrayIterator::uksort' => ['void', 'cmp_function'=>'callable'],
'ArrayIterator::unserialize' => ['string', 'serialized'=>'string'],
'ArrayIterator::valid' => ['bool'],
'ArrayObject::__construct' => ['void', 'input='=>'array|object', 'flags='=>'int', 'iterator_class='=>'string'],
'ArrayObject::append' => ['void', 'value'=>'mixed'],
'ArrayObject::asort' => ['void'],
'ArrayObject::count' => ['int'],
'ArrayObject::exchangeArray' => ['array', 'ar'=>'mixed'],
'ArrayObject::getArrayCopy' => ['array'],
'ArrayObject::getFlags' => ['int'],
'ArrayObject::getIterator' => ['ArrayIterator'],
'ArrayObject::getIteratorClass' => ['string'],
'ArrayObject::ksort' => ['void'],
'ArrayObject::natcasesort' => ['void'],
'ArrayObject::natsort' => ['void'],
'ArrayObject::offsetExists' => ['bool', 'index'=>'mixed'],
'ArrayObject::offsetGet' => ['mixed', 'index'=>'mixed'],
'ArrayObject::offsetSet' => ['void', 'index'=>'mixed', 'newval'=>'mixed'],
'ArrayObject::offsetUnset' => ['void', 'index'=>'mixed'],
'ArrayObject::serialize' => ['string'],
'ArrayObject::setFlags' => ['void', 'flags'=>'int'],
'ArrayObject::setIteratorClass' => ['void', 'iterator_class'=>'string'],
'ArrayObject::uasort' => ['void', 'cmp_function'=>'callable'],
'ArrayObject::uksort' => ['void', 'cmp_function'=>'callable'],
'ArrayObject::unserialize' => ['void', 'serialized'=>'string'],
'arsort' => ['bool', '&rw_array_arg'=>'array', 'sort_flags='=>'int'],
'asin' => ['float', 'number'=>'float'],
'asinh' => ['float', 'number'=>'float'],
'asort' => ['bool', '&rw_array_arg'=>'array', 'sort_flags='=>'int'],
'assert' => ['int', 'assertion'=>'string|bool', 'description='=>'string|Throwable|null'],
'assert_options' => ['mixed', 'what'=>'int', 'value='=>'mixed'],
'ast\get_kind_name' => ['string', 'kind'=>'int'],
'ast\get_metadata' => ['array'],
'ast\get_supported_versions' => ['array', 'exclude_deprecated='=>'bool'],
'ast\kind_uses_flags' => ['bool', 'kind'=>'int'],
'ast\Node::__construct' => ['void', 'kind='=>'int', 'flags='=>'int', 'children='=>'ast\Node\Decl[]|ast\Node[]|array[]|int[]|string[]|float[]|bool[]|null[]', 'start_line='=>'int'],
'ast\parse_code' => ['ast\Node', 'code'=>'string', 'version'=>'int', 'filename='=>'string'],
'ast\parse_file' => ['ast\Node', 'filename'=>'string', 'version'=>'int'],
'atan' => ['float', 'number'=>'float'],
'atan2' => ['float', 'y'=>'float', 'x'=>'float'],
'atanh' => ['float', 'number'=>'float'],
'BadFunctionCallException::__clone' => ['void'],
'BadFunctionCallException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?BadFunctionCallException'],
'BadFunctionCallException::__toString' => ['string'],
'BadFunctionCallException::getCode' => ['int'],
'BadFunctionCallException::getFile' => ['string'],
'BadFunctionCallException::getLine' => ['int'],
'BadFunctionCallException::getMessage' => ['string'],
'BadFunctionCallException::getPrevious' => ['?Throwable|?BadFunctionCallException'],
'BadFunctionCallException::getTrace' => ['array'],
'BadFunctionCallException::getTraceAsString' => ['string'],
'BadMethodCallException::__clone' => ['void'],
'BadMethodCallException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?BadMethodCallException'],
'BadMethodCallException::__toString' => ['string'],
'BadMethodCallException::getCode' => ['int'],
'BadMethodCallException::getFile' => ['string'],
'BadMethodCallException::getLine' => ['int'],
'BadMethodCallException::getMessage' => ['string'],
'BadMethodCallException::getPrevious' => ['?Throwable|?BadMethodCallException'],
'BadMethodCallException::getTrace' => ['array'],
'BadMethodCallException::getTraceAsString' => ['string'],
'base64_decode' => ['string|false', 'str'=>'string', 'strict='=>'bool'],
'base64_encode' => ['string', 'str'=>'string'],
'base_convert' => ['string', 'number'=>'string', 'frombase'=>'int', 'tobase'=>'int'],
'basename' => ['string', 'path'=>'string', 'suffix='=>'string'],
'bbcode_add_element' => ['bool', 'bbcode_container'=>'resource', 'tag_name'=>'string', 'tag_rules'=>'array'],
'bbcode_add_smiley' => ['bool', 'bbcode_container'=>'resource', 'smiley'=>'string', 'replace_by'=>'string'],
'bbcode_create' => ['resource', 'bbcode_initial_tags='=>'array'],
'bbcode_destroy' => ['bool', 'bbcode_container'=>'resource'],
'bbcode_parse' => ['string', 'bbcode_container'=>'resource', 'to_parse'=>'string'],
'bbcode_set_arg_parser' => ['bool', 'bbcode_container'=>'resource', 'bbcode_arg_parser'=>'resource'],
'bbcode_set_flags' => ['bool', 'bbcode_container'=>'resource', 'flags'=>'int', 'mode='=>'int'],
'bcadd' => ['string', 'left_operand'=>'string', 'right_operand'=>'string', 'scale='=>'int'],
'bccomp' => ['int', 'left_operand'=>'string', 'right_operand'=>'string', 'scale='=>'int'],
'bcdiv' => ['string', 'left_operand'=>'string', 'right_operand'=>'string', 'scale='=>'int'],
'bcmod' => ['string', 'left_operand'=>'string', 'right_operand'=>'string', 'scale='=>'int'],
'bcmul' => ['string', 'left_operand'=>'string', 'right_operand'=>'string', 'scale='=>'int'],
'bcompiler_load' => ['bool', 'filename'=>'string'],
'bcompiler_load_exe' => ['bool', 'filename'=>'string'],
'bcompiler_parse_class' => ['bool', 'class'=>'string', 'callback'=>'string'],
'bcompiler_read' => ['bool', 'filehandle'=>'resource'],
'bcompiler_write_class' => ['bool', 'filehandle'=>'resource', 'classname'=>'string', 'extends='=>'string'],
'bcompiler_write_constant' => ['bool', 'filehandle'=>'resource', 'constantname'=>'string'],
'bcompiler_write_exe_footer' => ['bool', 'filehandle'=>'resource', 'startpos'=>'int'],
'bcompiler_write_file' => ['bool', 'filehandle'=>'resource', 'filename'=>'string'],
'bcompiler_write_footer' => ['bool', 'filehandle'=>'resource'],
'bcompiler_write_function' => ['bool', 'filehandle'=>'resource', 'functionname'=>'string'],
'bcompiler_write_functions_from_file' => ['bool', 'filehandle'=>'resource', 'filename'=>'string'],
'bcompiler_write_header' => ['bool', 'filehandle'=>'resource', 'write_ver='=>'string'],
'bcompiler_write_included_filename' => ['bool', 'filehandle'=>'resource', 'filename'=>'string'],
'bcpow' => ['string', 'base'=>'string', 'exponent'=>'string', 'scale='=>'int'],
'bcpowmod' => ['string', 'base'=>'string', 'exponent'=>'string', 'modulus'=>'string', 'scale='=>'int'],
'bcscale' => ['bool', 'scale'=>'int'],
'bcsqrt' => ['string', 'operand'=>'string', 'scale='=>'int'],
'bcsub' => ['string', 'left_operand'=>'string', 'right_operand'=>'string', 'scale='=>'int'],
'bin2hex' => ['string', 'data'=>'string'],
'bind_textdomain_codeset' => ['string', 'domain'=>'string', 'codeset'=>'string'],
'bindec' => ['int', 'binary_number'=>'string'],
'bindtextdomain' => ['string', 'domain_name'=>'string', 'dir'=>'string'],
'birdstep_autocommit' => ['bool', 'index'=>'int'],
'birdstep_close' => ['bool', 'id'=>'int'],
'birdstep_commit' => ['bool', 'index'=>'int'],
'birdstep_connect' => ['int', 'server'=>'string', 'user'=>'string', 'pass'=>'string'],
'birdstep_exec' => ['int', 'index'=>'int', 'exec_str'=>'string'],
'birdstep_fetch' => ['bool', 'index'=>'int'],
'birdstep_fieldname' => ['string', 'index'=>'int', 'col'=>'int'],
'birdstep_fieldnum' => ['int', 'index'=>'int'],
'birdstep_freeresult' => ['bool', 'index'=>'int'],
'birdstep_off_autocommit' => ['bool', 'index'=>'int'],
'birdstep_result' => ['', 'index'=>'int', 'col'=>''],
'birdstep_rollback' => ['bool', 'index'=>'int'],
'blenc_encrypt' => ['string', 'plaintext'=>'string', 'encodedfile'=>'string', 'encryption_key='=>'string'],
'boolval' => ['bool', 'var'=>'mixed'],
'BSON\Binary::__construct' => ['void', 'data'=>'string', 'subtype'=>'string'],
'BSON\Binary::getSubType' => [''],
'BSON\fromArray' => ['string', 'array'=>'string'],
'BSON\fromJSON' => ['string', 'json'=>'string'],
'BSON\Javascript::__construct' => ['void', 'javascript'=>'string', 'scope='=>'string'],
'BSON\ObjectID::__construct' => ['void', 'id='=>'string'],
'BSON\ObjectID::__toString' => ['string'],
'BSON\Regex::__construct' => ['void', 'pattern'=>'string', 'flags'=>'string'],
'BSON\Regex::__toString' => ['string'],
'BSON\Regex::getFlags' => [''],
'BSON\Regex::getPattern' => [''],
'BSON\Serializable::bsonSerialize' => ['string'],
'BSON\Timestamp::__construct' => ['void', 'increment'=>'string', 'timestamp'=>'string'],
'BSON\Timestamp::__toString' => ['string'],
'BSON\toArray' => ['array', 'bson'=>'string'],
'BSON\toJSON' => ['string', 'bson'=>'string'],
'BSON\Unserializable::bsonUnserialize' => ['', 'data'=>'array'],
'BSON\UTCDatetime::__construct' => ['void', 'milliseconds'=>'string'],
'BSON\UTCDatetime::__toString' => ['string'],
'BSON\UTCDatetime::toDateTime' => [''],
'bson_decode' => ['array', 'bson'=>'string'],
'bson_encode' => ['string', 'anything'=>'mixed'],
'bzclose' => ['int', 'bz'=>'resource'],
'bzcompress' => ['string', 'source'=>'string', 'blocksize100k='=>'int', 'workfactor='=>'int'],
'bzdecompress' => ['string', 'source'=>'string', 'small='=>'int'],
'bzerrno' => ['int', 'bz'=>'resource'],
'bzerror' => ['array', 'bz'=>'resource'],
'bzerrstr' => ['string', 'bz'=>'resource'],
'bzflush' => ['int', 'bz'=>'resource'],
'bzopen' => ['resource', 'file'=>'string|resource', 'mode'=>'string'],
'bzread' => ['string', 'bz'=>'resource', 'length='=>'int'],
'bzwrite' => ['int', 'bz'=>'resource', 'data'=>'string', 'length='=>'int'],
'CachingIterator::__construct' => ['void', 'it'=>'iterator', 'flags='=>''],
'CachingIterator::__toString' => ['string'],
'CachingIterator::count' => ['int'],
'CachingIterator::current' => ['void'],
'CachingIterator::getCache' => ['array'],
'CachingIterator::getFlags' => ['int'],
'CachingIterator::getInnerIterator' => ['Iterator'],
'CachingIterator::hasNext' => ['bool'],
'CachingIterator::key' => ['mixed'],
'CachingIterator::next' => ['void'],
'CachingIterator::offsetExists' => ['bool', 'index'=>'string'],
'CachingIterator::offsetGet' => ['mixed', 'index'=>'string'],
'CachingIterator::offsetSet' => ['void', 'index'=>'string', 'newval'=>'mixed'],
'CachingIterator::offsetUnset' => ['void', 'index'=>'string'],
'CachingIterator::rewind' => ['void'],
'CachingIterator::setFlags' => ['void', 'flags'=>'int'],
'CachingIterator::valid' => ['bool'],
'Cairo::availableFonts' => ['array'],
'Cairo::availableSurfaces' => ['array'],
'Cairo::statusToString' => ['string', 'status'=>'int'],
'Cairo::version' => ['int'],
'Cairo::versionString' => ['string'],
'cairo_append_path' => ['', 'path'=>'cairopath', 'context'=>'cairocontext'],
'cairo_arc' => ['', 'x'=>'float', 'y'=>'float', 'radius'=>'float', 'angle1'=>'float', 'angle2'=>'float', 'context'=>'cairocontext'],
'cairo_arc_negative' => ['', 'x'=>'float', 'y'=>'float', 'radius'=>'float', 'angle1'=>'float', 'angle2'=>'float', 'context'=>'cairocontext'],
'cairo_available_fonts' => ['array'],
'cairo_available_surfaces' => ['array'],
'cairo_clip' => ['', 'context'=>'cairocontext'],
'cairo_clip_extents' => ['array', 'context'=>'cairocontext'],
'cairo_clip_preserve' => ['', 'context'=>'cairocontext'],
'cairo_clip_rectangle_list' => ['array', 'context'=>'cairocontext'],
'cairo_close_path' => ['', 'context'=>'cairocontext'],
'cairo_copy_page' => ['', 'context'=>'cairocontext'],
'cairo_copy_path' => ['CairoPath', 'context'=>'cairocontext'],
'cairo_copy_path_flat' => ['CairoPath', 'context'=>'cairocontext'],
'cairo_create' => ['CairoContext', 'surface'=>'cairosurface'],
'cairo_curve_to' => ['', 'x1'=>'float', 'y1'=>'float', 'x2'=>'float', 'y2'=>'float', 'x3'=>'float', 'y3'=>'float', 'context'=>'cairocontext'],
'cairo_device_to_user' => ['array', 'x'=>'float', 'y'=>'float', 'context'=>'cairocontext'],
'cairo_device_to_user_distance' => ['array', 'x'=>'float', 'y'=>'float', 'context'=>'cairocontext'],
'cairo_fill' => ['', 'context'=>'cairocontext'],
'cairo_fill_extents' => ['array', 'context'=>'cairocontext'],
'cairo_fill_preserve' => ['', 'context'=>'cairocontext'],
'cairo_font_extents' => ['array', 'context'=>'cairocontext'],
'cairo_font_face_get_type' => ['int', 'fontface'=>'cairofontface'],
'cairo_font_face_status' => ['int', 'fontface'=>'cairofontface'],
'cairo_font_options_create' => ['CairoFontOptions'],
'cairo_font_options_equal' => ['bool', 'options'=>'cairofontoptions', 'other'=>'cairofontoptions'],
'cairo_font_options_get_antialias' => ['int', 'options'=>'cairofontoptions'],
'cairo_font_options_get_hint_metrics' => ['int', 'options'=>'cairofontoptions'],
'cairo_font_options_get_hint_style' => ['int', 'options'=>'cairofontoptions'],
'cairo_font_options_get_subpixel_order' => ['int', 'options'=>'cairofontoptions'],
'cairo_font_options_hash' => ['int', 'options'=>'cairofontoptions'],
'cairo_font_options_merge' => ['void', 'options'=>'cairofontoptions', 'other'=>'cairofontoptions'],
'cairo_font_options_set_antialias' => ['void', 'options'=>'cairofontoptions', 'antialias'=>'int'],
'cairo_font_options_set_hint_metrics' => ['void', 'options'=>'cairofontoptions', 'hint_metrics'=>'int'],
'cairo_font_options_set_hint_style' => ['void', 'options'=>'cairofontoptions', 'hint_style'=>'int'],
'cairo_font_options_set_subpixel_order' => ['void', 'options'=>'cairofontoptions', 'subpixel_order'=>'int'],
'cairo_font_options_status' => ['int', 'options'=>'cairofontoptions'],
'cairo_format_stride_for_width' => ['int', 'format'=>'int', 'width'=>'int'],
'cairo_get_antialias' => ['int', 'context'=>'cairocontext'],
'cairo_get_current_point' => ['array', 'context'=>'cairocontext'],
'cairo_get_dash' => ['array', 'context'=>'cairocontext'],
'cairo_get_dash_count' => ['int', 'context'=>'cairocontext'],
'cairo_get_fill_rule' => ['int', 'context'=>'cairocontext'],
'cairo_get_font_face' => ['', 'context'=>'cairocontext'],
'cairo_get_font_matrix' => ['', 'context'=>'cairocontext'],
'cairo_get_font_options' => ['', 'context'=>'cairocontext'],
'cairo_get_group_target' => ['', 'context'=>'cairocontext'],
'cairo_get_line_cap' => ['int', 'context'=>'cairocontext'],
'cairo_get_line_join' => ['int', 'context'=>'cairocontext'],
'cairo_get_line_width' => ['float', 'context'=>'cairocontext'],
'cairo_get_matrix' => ['', 'context'=>'cairocontext'],
'cairo_get_miter_limit' => ['float', 'context'=>'cairocontext'],
'cairo_get_operator' => ['int', 'context'=>'cairocontext'],
'cairo_get_scaled_font' => ['', 'context'=>'cairocontext'],
'cairo_get_source' => ['', 'context'=>'cairocontext'],
'cairo_get_target' => ['', 'context'=>'cairocontext'],
'cairo_get_tolerance' => ['float', 'context'=>'cairocontext'],
'cairo_glyph_path' => ['', 'glyphs'=>'array', 'context'=>'cairocontext'],
'cairo_has_current_point' => ['bool', 'context'=>'cairocontext'],
'cairo_identity_matrix' => ['', 'context'=>'cairocontext'],
'cairo_image_surface_create' => ['CairoImageSurface', 'format'=>'int', 'width'=>'int', 'height'=>'int'],
'cairo_image_surface_create_for_data' => ['CairoImageSurface', 'data'=>'string', 'format'=>'int', 'width'=>'int', 'height'=>'int', 'stride='=>'int'],
'cairo_image_surface_create_from_png' => ['CairoImageSurface', 'file'=>'string'],
'cairo_image_surface_get_data' => ['string', 'surface'=>'cairoimagesurface'],
'cairo_image_surface_get_format' => ['int', 'surface'=>'cairoimagesurface'],
'cairo_image_surface_get_height' => ['int', 'surface'=>'cairoimagesurface'],
'cairo_image_surface_get_stride' => ['int', 'surface'=>'cairoimagesurface'],
'cairo_image_surface_get_width' => ['int', 'surface'=>'cairoimagesurface'],
'cairo_in_fill' => ['bool', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'cairo_in_stroke' => ['bool', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'cairo_line_to' => ['', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'cairo_mask' => ['', 'pattern'=>'cairopattern', 'context'=>'cairocontext'],
'cairo_mask_surface' => ['', 'surface'=>'cairosurface', 'x='=>'string', 'y='=>'string', 'context='=>'cairocontext'],
'cairo_matrix_create_scale' => ['object', 'sx'=>'float', 'sy'=>'float'],
'cairo_matrix_init' => ['object', 'xx='=>'float', 'yx='=>'float', 'xy='=>'float', 'yy='=>'float', 'x0='=>'float', 'y0='=>'float'],
'cairo_matrix_init_identity' => ['object'],
'cairo_matrix_init_rotate' => ['object', 'radians'=>'float'],
'cairo_matrix_init_scale' => ['object', 'sx'=>'float', 'sy'=>'float'],
'cairo_matrix_init_translate' => ['object', 'tx'=>'float', 'ty'=>'float'],
'cairo_matrix_invert' => ['void', 'matrix'=>'cairomatrix'],
'cairo_matrix_multiply' => ['CairoMatrix', 'matrix1'=>'cairomatrix', 'matrix2'=>'cairomatrix'],
'cairo_matrix_rotate' => ['', 'matrix'=>'cairomatrix', 'radians'=>'float'],
'cairo_matrix_scale' => ['', 'sx'=>'float', 'sy'=>'float', 'context'=>'cairocontext'],
'cairo_matrix_transform_distance' => ['array', 'matrix'=>'cairomatrix', 'dx'=>'float', 'dy'=>'float'],
'cairo_matrix_transform_point' => ['array', 'matrix'=>'cairomatrix', 'dx'=>'float', 'dy'=>'float'],
'cairo_matrix_translate' => ['void', 'matrix'=>'cairomatrix', 'tx'=>'float', 'ty'=>'float'],
'cairo_move_to' => ['', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'cairo_new_path' => ['', 'context'=>'cairocontext'],
'cairo_new_sub_path' => ['', 'context'=>'cairocontext'],
'cairo_paint' => ['', 'context'=>'cairocontext'],
'cairo_paint_with_alpha' => ['', 'alpha'=>'string', 'context'=>'cairocontext'],
'cairo_path_extents' => ['array', 'context'=>'cairocontext'],
'cairo_pattern_add_color_stop_rgb' => ['void', 'pattern'=>'cairogradientpattern', 'offset'=>'float', 'red'=>'float', 'green'=>'float', 'blue'=>'float'],
'cairo_pattern_add_color_stop_rgba' => ['void', 'pattern'=>'cairogradientpattern', 'offset'=>'float', 'red'=>'float', 'green'=>'float', 'blue'=>'float', 'alpha'=>'float'],
'cairo_pattern_create_for_surface' => ['CairoPattern', 'surface'=>'cairosurface'],
'cairo_pattern_create_linear' => ['CairoPattern', 'x0'=>'float', 'y0'=>'float', 'x1'=>'float', 'y1'=>'float'],
'cairo_pattern_create_radial' => ['CairoPattern', 'x0'=>'float', 'y0'=>'float', 'r0'=>'float', 'x1'=>'float', 'y1'=>'float', 'r1'=>'float'],
'cairo_pattern_create_rgb' => ['CairoPattern', 'red'=>'float', 'green'=>'float', 'blue'=>'float'],
'cairo_pattern_create_rgba' => ['CairoPattern', 'red'=>'float', 'green'=>'float', 'blue'=>'float', 'alpha'=>'float'],
'cairo_pattern_get_color_stop_count' => ['int', 'pattern'=>'cairogradientpattern'],
'cairo_pattern_get_color_stop_rgba' => ['array', 'pattern'=>'cairogradientpattern', 'index'=>'int'],
'cairo_pattern_get_extend' => ['int', 'pattern'=>'string'],
'cairo_pattern_get_filter' => ['int', 'pattern'=>'cairosurfacepattern'],
'cairo_pattern_get_linear_points' => ['array', 'pattern'=>'cairolineargradient'],
'cairo_pattern_get_matrix' => ['CairoMatrix', 'pattern'=>'cairopattern'],
'cairo_pattern_get_radial_circles' => ['array', 'pattern'=>'cairoradialgradient'],
'cairo_pattern_get_rgba' => ['array', 'pattern'=>'cairosolidpattern'],
'cairo_pattern_get_surface' => ['CairoSurface', 'pattern'=>'cairosurfacepattern'],
'cairo_pattern_get_type' => ['int', 'pattern'=>'cairopattern'],
'cairo_pattern_set_extend' => ['void', 'pattern'=>'string', 'extend'=>'string'],
'cairo_pattern_set_filter' => ['void', 'pattern'=>'cairosurfacepattern', 'filter'=>'int'],
'cairo_pattern_set_matrix' => ['void', 'pattern'=>'cairopattern', 'matrix'=>'cairomatrix'],
'cairo_pattern_status' => ['int', 'pattern'=>'cairopattern'],
'cairo_pdf_surface_create' => ['CairoPdfSurface', 'file'=>'string', 'width'=>'float', 'height'=>'float'],
'cairo_pdf_surface_set_size' => ['void', 'surface'=>'cairopdfsurface', 'width'=>'float', 'height'=>'float'],
'cairo_pop_group' => ['', 'context'=>'cairocontext'],
'cairo_pop_group_to_source' => ['', 'context'=>'cairocontext'],
'cairo_ps_get_levels' => ['array'],
'cairo_ps_level_to_string' => ['string', 'level'=>'int'],
'cairo_ps_surface_create' => ['CairoPsSurface', 'file'=>'string', 'width'=>'float', 'height'=>'float'],
'cairo_ps_surface_dsc_begin_page_setup' => ['void', 'surface'=>'cairopssurface'],
'cairo_ps_surface_dsc_begin_setup' => ['void', 'surface'=>'cairopssurface'],
'cairo_ps_surface_dsc_comment' => ['void', 'surface'=>'cairopssurface', 'comment'=>'string'],
'cairo_ps_surface_get_eps' => ['bool', 'surface'=>'cairopssurface'],
'cairo_ps_surface_restrict_to_level' => ['void', 'surface'=>'cairopssurface', 'level'=>'int'],
'cairo_ps_surface_set_eps' => ['void', 'surface'=>'cairopssurface', 'level'=>'bool'],
'cairo_ps_surface_set_size' => ['void', 'surface'=>'cairopssurface', 'width'=>'float', 'height'=>'float'],
'cairo_push_group' => ['', 'context'=>'cairocontext'],
'cairo_push_group_with_content' => ['', 'content'=>'string', 'context'=>'cairocontext'],
'cairo_rectangle' => ['', 'x'=>'string', 'y'=>'string', 'width'=>'string', 'height'=>'string', 'context'=>'cairocontext'],
'cairo_rel_curve_to' => ['', 'x1'=>'string', 'y1'=>'string', 'x2'=>'string', 'y2'=>'string', 'x3'=>'string', 'y3'=>'string', 'context'=>'cairocontext'],
'cairo_rel_line_to' => ['', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'cairo_rel_move_to' => ['', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'cairo_reset_clip' => ['', 'context'=>'cairocontext'],
'cairo_restore' => ['', 'context'=>'cairocontext'],
'cairo_rotate' => ['', 'sx'=>'string', 'sy'=>'string', 'context'=>'cairocontext', 'angle'=>'string'],
'cairo_save' => ['', 'context'=>'cairocontext'],
'cairo_scale' => ['', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'cairo_scaled_font_create' => ['CairoScaledFont', 'fontface'=>'cairofontface', 'matrix'=>'cairomatrix', 'ctm'=>'cairomatrix', 'fontoptions'=>'cairofontoptions'],
'cairo_scaled_font_extents' => ['array', 'scaledfont'=>'cairoscaledfont'],
'cairo_scaled_font_get_ctm' => ['CairoMatrix', 'scaledfont'=>'cairoscaledfont'],
'cairo_scaled_font_get_font_face' => ['CairoFontFace', 'scaledfont'=>'cairoscaledfont'],
'cairo_scaled_font_get_font_matrix' => ['CairoFontOptions', 'scaledfont'=>'cairoscaledfont'],
'cairo_scaled_font_get_font_options' => ['CairoFontOptions', 'scaledfont'=>'cairoscaledfont'],
'cairo_scaled_font_get_scale_matrix' => ['CairoMatrix', 'scaledfont'=>'cairoscaledfont'],
'cairo_scaled_font_get_type' => ['int', 'scaledfont'=>'cairoscaledfont'],
'cairo_scaled_font_glyph_extents' => ['array', 'scaledfont'=>'cairoscaledfont', 'glyphs'=>'array'],
'cairo_scaled_font_status' => ['int', 'scaledfont'=>'cairoscaledfont'],
'cairo_scaled_font_text_extents' => ['array', 'scaledfont'=>'cairoscaledfont', 'text'=>'string'],
'cairo_select_font_face' => ['', 'family'=>'string', 'slant='=>'string', 'weight='=>'string', 'context='=>'cairocontext'],
'cairo_set_antialias' => ['', 'antialias='=>'string', 'context='=>'cairocontext'],
'cairo_set_dash' => ['', 'dashes'=>'array', 'offset='=>'string', 'context='=>'cairocontext'],
'cairo_set_fill_rule' => ['', 'setting'=>'string', 'context'=>'cairocontext'],
'cairo_set_font_face' => ['', 'fontface'=>'cairofontface', 'context'=>'cairocontext'],
'cairo_set_font_matrix' => ['', 'matrix'=>'cairomatrix', 'context'=>'cairocontext'],
'cairo_set_font_options' => ['', 'fontoptions'=>'cairofontoptions', 'context'=>'cairocontext'],
'cairo_set_font_size' => ['', 'size'=>'string', 'context'=>'cairocontext'],
'cairo_set_line_cap' => ['', 'setting'=>'string', 'context'=>'cairocontext'],
'cairo_set_line_join' => ['', 'setting'=>'string', 'context'=>'cairocontext'],
'cairo_set_line_width' => ['', 'width'=>'string', 'context'=>'cairocontext'],
'cairo_set_matrix' => ['', 'matrix'=>'cairomatrix', 'context'=>'cairocontext'],
'cairo_set_miter_limit' => ['', 'limit'=>'string', 'context'=>'cairocontext'],
'cairo_set_operator' => ['', 'setting'=>'string', 'context'=>'cairocontext'],
'cairo_set_scaled_font' => ['', 'scaledfont'=>'cairoscaledfont', 'context'=>'cairocontext'],
'cairo_set_source' => ['', 'red'=>'string', 'green'=>'string', 'blue'=>'string', 'alpha'=>'string', 'context'=>'cairocontext', 'pattern'=>'cairopattern'],
'cairo_set_source_surface' => ['', 'surface'=>'cairosurface', 'x='=>'string', 'y='=>'string', 'context='=>'cairocontext'],
'cairo_set_tolerance' => ['', 'tolerance'=>'string', 'context'=>'cairocontext'],
'cairo_show_page' => ['', 'context'=>'cairocontext'],
'cairo_show_text' => ['', 'text'=>'string', 'context'=>'cairocontext'],
'cairo_status' => ['int', 'context'=>'cairocontext'],
'cairo_status_to_string' => ['string', 'status'=>'int'],
'cairo_stroke' => ['', 'context'=>'cairocontext'],
'cairo_stroke_extents' => ['array', 'context'=>'cairocontext'],
'cairo_stroke_preserve' => ['', 'context'=>'cairocontext'],
'cairo_surface_copy_page' => ['void', 'surface'=>'cairosurface'],
'cairo_surface_create_similar' => ['CairoSurface', 'surface'=>'cairosurface', 'content'=>'int', 'width'=>'float', 'height'=>'float'],
'cairo_surface_finish' => ['void', 'surface'=>'cairosurface'],
'cairo_surface_flush' => ['void', 'surface'=>'cairosurface'],
'cairo_surface_get_content' => ['int', 'surface'=>'cairosurface'],
'cairo_surface_get_device_offset' => ['array', 'surface'=>'cairosurface'],
'cairo_surface_get_font_options' => ['CairoFontOptions', 'surface'=>'cairosurface'],
'cairo_surface_get_type' => ['int', 'surface'=>'cairosurface'],
'cairo_surface_mark_dirty' => ['void', 'surface'=>'cairosurface'],
'cairo_surface_mark_dirty_rectangle' => ['void', 'surface'=>'cairosurface', 'x'=>'float', 'y'=>'float', 'width'=>'float', 'height'=>'float'],
'cairo_surface_set_device_offset' => ['void', 'surface'=>'cairosurface', 'x'=>'float', 'y'=>'float'],
'cairo_surface_set_fallback_resolution' => ['void', 'surface'=>'cairosurface', 'x'=>'float', 'y'=>'float'],
'cairo_surface_show_page' => ['void', 'surface'=>'cairosurface'],
'cairo_surface_status' => ['int', 'surface'=>'cairosurface'],
'cairo_surface_write_to_png' => ['void', 'surface'=>'cairosurface', 'stream'=>'resource'],
'cairo_svg_get_versions' => ['array'],
'cairo_svg_surface_create' => ['CairoSvgSurface', 'file'=>'string', 'width'=>'float', 'height'=>'float'],
'cairo_svg_surface_get_versions' => ['array'],
'cairo_svg_surface_restrict_to_version' => ['void', 'surface'=>'cairosvgsurface', 'version'=>'int'],
'cairo_svg_version_to_string' => ['string', 'version'=>'int'],
'cairo_text_extents' => ['array', 'text'=>'string', 'context'=>'cairocontext'],
'cairo_text_path' => ['', 'string'=>'string', 'context'=>'cairocontext', 'text'=>'string'],
'cairo_transform' => ['', 'matrix'=>'cairomatrix', 'context'=>'cairocontext'],
'cairo_translate' => ['', 'tx'=>'string', 'ty'=>'string', 'context'=>'cairocontext', 'x'=>'string', 'y'=>'string'],
'cairo_user_to_device' => ['array', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'cairo_user_to_device_distance' => ['array', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'cairo_version' => ['int'],
'cairo_version_string' => ['string'],
'CairoContext::__construct' => ['void', 'surface'=>'CairoSurface'],
'CairoContext::appendPath' => ['', 'path'=>'cairopath', 'context'=>'cairocontext'],
'CairoContext::arc' => ['', 'x'=>'float', 'y'=>'float', 'radius'=>'float', 'angle1'=>'float', 'angle2'=>'float', 'context'=>'cairocontext'],
'CairoContext::arcNegative' => ['', 'x'=>'float', 'y'=>'float', 'radius'=>'float', 'angle1'=>'float', 'angle2'=>'float', 'context'=>'cairocontext'],
'CairoContext::clip' => ['', 'context'=>'cairocontext'],
'CairoContext::clipExtents' => ['array', 'context'=>'cairocontext'],
'CairoContext::clipPreserve' => ['', 'context'=>'cairocontext'],
'CairoContext::clipRectangleList' => ['array', 'context'=>'cairocontext'],
'CairoContext::closePath' => ['', 'context'=>'cairocontext'],
'CairoContext::copyPage' => ['', 'context'=>'cairocontext'],
'CairoContext::copyPath' => ['CairoPath', 'context'=>'cairocontext'],
'CairoContext::copyPathFlat' => ['CairoPath', 'context'=>'cairocontext'],
'CairoContext::curveTo' => ['', 'x1'=>'float', 'y1'=>'float', 'x2'=>'float', 'y2'=>'float', 'x3'=>'float', 'y3'=>'float', 'context'=>'cairocontext'],
'CairoContext::deviceToUser' => ['array', 'x'=>'float', 'y'=>'float', 'context'=>'cairocontext'],
'CairoContext::deviceToUserDistance' => ['array', 'x'=>'float', 'y'=>'float', 'context'=>'cairocontext'],
'CairoContext::fill' => ['', 'context'=>'cairocontext'],
'CairoContext::fillExtents' => ['array', 'context'=>'cairocontext'],
'CairoContext::fillPreserve' => ['', 'context'=>'cairocontext'],
'CairoContext::fontExtents' => ['array', 'context'=>'cairocontext'],
'CairoContext::getAntialias' => ['int', 'context'=>'cairocontext'],
'CairoContext::getCurrentPoint' => ['array', 'context'=>'cairocontext'],
'CairoContext::getDash' => ['array', 'context'=>'cairocontext'],
'CairoContext::getDashCount' => ['int', 'context'=>'cairocontext'],
'CairoContext::getFillRule' => ['int', 'context'=>'cairocontext'],
'CairoContext::getFontFace' => ['', 'context'=>'cairocontext'],
'CairoContext::getFontMatrix' => ['', 'context'=>'cairocontext'],
'CairoContext::getFontOptions' => ['', 'context'=>'cairocontext'],
'CairoContext::getGroupTarget' => ['', 'context'=>'cairocontext'],
'CairoContext::getLineCap' => ['int', 'context'=>'cairocontext'],
'CairoContext::getLineJoin' => ['int', 'context'=>'cairocontext'],
'CairoContext::getLineWidth' => ['float', 'context'=>'cairocontext'],
'CairoContext::getMatrix' => ['', 'context'=>'cairocontext'],
'CairoContext::getMiterLimit' => ['float', 'context'=>'cairocontext'],
'CairoContext::getOperator' => ['int', 'context'=>'cairocontext'],
'CairoContext::getScaledFont' => ['', 'context'=>'cairocontext'],
'CairoContext::getSource' => ['', 'context'=>'cairocontext'],
'CairoContext::getTarget' => ['', 'context'=>'cairocontext'],
'CairoContext::getTolerance' => ['float', 'context'=>'cairocontext'],
'CairoContext::glyphPath' => ['', 'glyphs'=>'array', 'context'=>'cairocontext'],
'CairoContext::hasCurrentPoint' => ['bool', 'context'=>'cairocontext'],
'CairoContext::identityMatrix' => ['', 'context'=>'cairocontext'],
'CairoContext::inFill' => ['bool', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'CairoContext::inStroke' => ['bool', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'CairoContext::lineTo' => ['', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'CairoContext::mask' => ['', 'pattern'=>'cairopattern', 'context'=>'cairocontext'],
'CairoContext::maskSurface' => ['', 'surface'=>'cairosurface', 'x='=>'string', 'y='=>'string', 'context='=>'cairocontext'],
'CairoContext::moveTo' => ['', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'CairoContext::newPath' => ['', 'context'=>'cairocontext'],
'CairoContext::newSubPath' => ['', 'context'=>'cairocontext'],
'CairoContext::paint' => ['', 'context'=>'cairocontext'],
'CairoContext::paintWithAlpha' => ['', 'alpha'=>'string', 'context'=>'cairocontext'],
'CairoContext::pathExtents' => ['array', 'context'=>'cairocontext'],
'CairoContext::popGroup' => ['', 'context'=>'cairocontext'],
'CairoContext::popGroupToSource' => ['', 'context'=>'cairocontext'],
'CairoContext::pushGroup' => ['', 'context'=>'cairocontext'],
'CairoContext::pushGroupWithContent' => ['', 'content'=>'string', 'context'=>'cairocontext'],
'CairoContext::rectangle' => ['', 'x'=>'string', 'y'=>'string', 'width'=>'string', 'height'=>'string', 'context'=>'cairocontext'],
'CairoContext::relCurveTo' => ['', 'x1'=>'string', 'y1'=>'string', 'x2'=>'string', 'y2'=>'string', 'x3'=>'string', 'y3'=>'string', 'context'=>'cairocontext'],
'CairoContext::relLineTo' => ['', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'CairoContext::relMoveTo' => ['', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'CairoContext::resetClip' => ['', 'context'=>'cairocontext'],
'CairoContext::restore' => ['', 'context'=>'cairocontext'],
'CairoContext::rotate' => ['', 'angle'=>'string', 'context'=>'cairocontext'],
'CairoContext::save' => ['', 'context'=>'cairocontext'],
'CairoContext::scale' => ['', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'CairoContext::selectFontFace' => ['', 'family'=>'string', 'slant='=>'string', 'weight='=>'string', 'context='=>'cairocontext'],
'CairoContext::setAntialias' => ['', 'antialias='=>'string', 'context='=>'cairocontext'],
'CairoContext::setDash' => ['', 'dashes'=>'array', 'offset='=>'string', 'context='=>'cairocontext'],
'CairoContext::setFillRule' => ['', 'setting'=>'string', 'context'=>'cairocontext'],
'CairoContext::setFontFace' => ['', 'fontface'=>'cairofontface', 'context'=>'cairocontext'],
'CairoContext::setFontMatrix' => ['', 'matrix'=>'cairomatrix', 'context'=>'cairocontext'],
'CairoContext::setFontOptions' => ['', 'fontoptions'=>'cairofontoptions', 'context'=>'cairocontext'],
'CairoContext::setFontSize' => ['', 'size'=>'string', 'context'=>'cairocontext'],
'CairoContext::setLineCap' => ['', 'setting'=>'string', 'context'=>'cairocontext'],
'CairoContext::setLineJoin' => ['', 'setting'=>'string', 'context'=>'cairocontext'],
'CairoContext::setLineWidth' => ['', 'width'=>'string', 'context'=>'cairocontext'],
'CairoContext::setMatrix' => ['', 'matrix'=>'cairomatrix', 'context'=>'cairocontext'],
'CairoContext::setMiterLimit' => ['', 'limit'=>'string', 'context'=>'cairocontext'],
'CairoContext::setOperator' => ['', 'setting'=>'string', 'context'=>'cairocontext'],
'CairoContext::setScaledFont' => ['', 'scaledfont'=>'cairoscaledfont', 'context'=>'cairocontext'],
'CairoContext::setSource' => ['', 'pattern'=>'cairopattern', 'context'=>'cairocontext'],
'CairoContext::setSourceRGB' => ['', 'red'=>'string', 'green'=>'string', 'blue'=>'string', 'context'=>'cairocontext', 'pattern'=>'cairopattern'],
'CairoContext::setSourceRGBA' => ['', 'red'=>'string', 'green'=>'string', 'blue'=>'string', 'alpha'=>'string', 'context'=>'cairocontext', 'pattern'=>'cairopattern'],
'CairoContext::setSourceSurface' => ['', 'surface'=>'cairosurface', 'x='=>'string', 'y='=>'string', 'context='=>'cairocontext'],
'CairoContext::setTolerance' => ['', 'tolerance'=>'string', 'context'=>'cairocontext'],
'CairoContext::showPage' => ['', 'context'=>'cairocontext'],
'CairoContext::showText' => ['', 'text'=>'string', 'context'=>'cairocontext'],
'CairoContext::status' => ['int', 'context'=>'cairocontext'],
'CairoContext::stroke' => ['', 'context'=>'cairocontext'],
'CairoContext::strokeExtents' => ['array', 'context'=>'cairocontext'],
'CairoContext::strokePreserve' => ['', 'context'=>'cairocontext'],
'CairoContext::textExtents' => ['array', 'text'=>'string', 'context'=>'cairocontext'],
'CairoContext::textPath' => ['', 'string'=>'string', 'context'=>'cairocontext', 'text'=>'string'],
'CairoContext::transform' => ['', 'matrix'=>'cairomatrix', 'context'=>'cairocontext'],
'CairoContext::translate' => ['', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'CairoContext::userToDevice' => ['array', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'CairoContext::userToDeviceDistance' => ['array', 'x'=>'string', 'y'=>'string', 'context'=>'cairocontext'],
'CairoFontFace::__construct' => ['void'],
'CairoFontFace::getType' => ['int'],
'CairoFontFace::status' => ['int', 'fontface'=>'cairofontface'],
'CairoFontOptions::__construct' => ['void'],
'CairoFontOptions::equal' => ['bool', 'other'=>'string'],
'CairoFontOptions::getAntialias' => ['int', 'context'=>'cairocontext'],
'CairoFontOptions::getHintMetrics' => ['int'],
'CairoFontOptions::getHintStyle' => ['int'],
'CairoFontOptions::getSubpixelOrder' => ['int'],
'CairoFontOptions::hash' => ['int'],
'CairoFontOptions::merge' => ['void', 'other'=>'string'],
'CairoFontOptions::setAntialias' => ['', 'antialias='=>'string', 'context='=>'cairocontext'],
'CairoFontOptions::setHintMetrics' => ['void', 'hint_metrics'=>'string'],
'CairoFontOptions::setHintStyle' => ['void', 'hint_style'=>'string'],
'CairoFontOptions::setSubpixelOrder' => ['void', 'subpixel_order'=>'string'],
'CairoFontOptions::status' => ['int', 'context'=>'cairocontext'],
'CairoFormat::strideForWidth' => ['int', 'format'=>'int', 'width'=>'int'],
'CairoGradientPattern::addColorStopRgb' => ['void', 'offset'=>'string', 'red'=>'string', 'green'=>'string', 'blue'=>'string'],
'CairoGradientPattern::addColorStopRgba' => ['void', 'offset'=>'string', 'red'=>'string', 'green'=>'string', 'blue'=>'string', 'alpha'=>'string'],
'CairoGradientPattern::getColorStopCount' => ['int'],
'CairoGradientPattern::getColorStopRgba' => ['array', 'index'=>'string'],
'CairoGradientPattern::getExtend' => ['int'],
'CairoGradientPattern::setExtend' => ['void', 'extend'=>'int'],
'CairoImageSurface::__construct' => ['void', 'format'=>'int', 'width'=>'int', 'height'=>'int'],
'CairoImageSurface::createForData' => ['void', 'data'=>'string', 'format'=>'int', 'width'=>'int', 'height'=>'int', 'stride='=>'int'],
'CairoImageSurface::createFromPng' => ['CairoImageSurface', 'file'=>'string'],
'CairoImageSurface::getData' => ['string'],
'CairoImageSurface::getFormat' => ['int'],
'CairoImageSurface::getHeight' => ['int'],
'CairoImageSurface::getStride' => ['int'],
'CairoImageSurface::getWidth' => ['int'],
'CairoLinearGradient::__construct' => ['void', 'x0'=>'float', 'y0'=>'float', 'x1'=>'float', 'y1'=>'float'],
'CairoLinearGradient::getPoints' => ['array'],
'CairoMatrix::__construct' => ['void', 'xx='=>'float', 'yx='=>'float', 'xy='=>'float', 'yy='=>'float', 'x0='=>'float', 'y0='=>'float'],
'CairoMatrix::initIdentity' => ['object'],
'CairoMatrix::initRotate' => ['object', 'radians'=>'float'],
'CairoMatrix::initScale' => ['object', 'sx'=>'float', 'sy'=>'float'],
'CairoMatrix::initTranslate' => ['object', 'tx'=>'float', 'ty'=>'float'],
'CairoMatrix::invert' => ['void'],
'CairoMatrix::multiply' => ['CairoMatrix', 'matrix1'=>'cairomatrix', 'matrix2'=>'cairomatrix'],
'CairoMatrix::rotate' => ['', 'sx'=>'string', 'sy'=>'string', 'context'=>'cairocontext', 'angle'=>'string'],
'CairoMatrix::scale' => ['', 'sx'=>'float', 'sy'=>'float', 'context'=>'cairocontext'],
'CairoMatrix::transformDistance' => ['array', 'dx'=>'string', 'dy'=>'string'],
'CairoMatrix::transformPoint' => ['array', 'dx'=>'string', 'dy'=>'string'],
'CairoMatrix::translate' => ['', 'tx'=>'string', 'ty'=>'string', 'context'=>'cairocontext', 'x'=>'string', 'y'=>'string'],
'CairoPattern::__construct' => ['void'],
'CairoPattern::getMatrix' => ['', 'context'=>'cairocontext'],
'CairoPattern::getType' => ['int'],
'CairoPattern::setMatrix' => ['', 'matrix'=>'cairomatrix', 'context'=>'cairocontext'],
'CairoPattern::status' => ['int', 'context'=>'cairocontext'],
'CairoPdfSurface::__construct' => ['void', 'file'=>'string', 'width'=>'float', 'height'=>'float'],
'CairoPdfSurface::setSize' => ['void', 'width'=>'string', 'height'=>'string'],
'CairoPsSurface::__construct' => ['void', 'file'=>'string', 'width'=>'float', 'height'=>'float'],
'CairoPsSurface::dscBeginPageSetup' => ['void'],
'CairoPsSurface::dscBeginSetup' => ['void'],
'CairoPsSurface::dscComment' => ['void', 'comment'=>'string'],
'CairoPsSurface::getEps' => ['bool'],
'CairoPsSurface::getLevels' => ['array'],
'CairoPsSurface::levelToString' => ['string', 'level'=>'int'],
'CairoPsSurface::restrictToLevel' => ['void', 'level'=>'string'],
'CairoPsSurface::setEps' => ['void', 'level'=>'string'],
'CairoPsSurface::setSize' => ['void', 'width'=>'string', 'height'=>'string'],
'CairoRadialGradient::__construct' => ['void', 'x0'=>'float', 'y0'=>'float', 'r0'=>'float', 'x1'=>'float', 'y1'=>'float', 'r1'=>'float'],
'CairoRadialGradient::getCircles' => ['array'],
'CairoScaledFont::__construct' => ['void', 'font_face'=>'CairoFontFace', 'matrix'=>'CairoMatrix', 'ctm'=>'CairoMatrix', 'options'=>'CairoFontOptions'],
'CairoScaledFont::extents' => ['array'],
'CairoScaledFont::getCtm' => ['CairoMatrix'],
'CairoScaledFont::getFontFace' => ['', 'context'=>'cairocontext'],
'CairoScaledFont::getFontMatrix' => ['', 'context'=>'cairocontext'],
'CairoScaledFont::getFontOptions' => ['', 'context'=>'cairocontext'],
'CairoScaledFont::getScaleMatrix' => ['void'],
'CairoScaledFont::getType' => ['int'],
'CairoScaledFont::glyphExtents' => ['array', 'glyphs'=>'string'],
'CairoScaledFont::status' => ['int', 'context'=>'cairocontext'],
'CairoScaledFont::textExtents' => ['array', 'text'=>'string', 'context'=>'cairocontext'],
'CairoSolidPattern::__construct' => ['void', 'red'=>'float', 'green'=>'float', 'blue'=>'float', 'alpha='=>'float'],
'CairoSolidPattern::getRgba' => ['array'],
'CairoSurface::__construct' => ['void'],
'CairoSurface::copyPage' => ['', 'context'=>'cairocontext'],
'CairoSurface::createSimilar' => ['void', 'other'=>'cairosurface', 'content'=>'int', 'width'=>'string', 'height'=>'string'],
'CairoSurface::finish' => ['void'],
'CairoSurface::flush' => ['void'],
'CairoSurface::getContent' => ['int'],
'CairoSurface::getDeviceOffset' => ['array'],
'CairoSurface::getFontOptions' => ['', 'context'=>'cairocontext'],
'CairoSurface::getType' => ['int'],
'CairoSurface::markDirty' => ['void'],
'CairoSurface::markDirtyRectangle' => ['void', 'x'=>'string', 'y'=>'string', 'width'=>'string', 'height'=>'string'],
'CairoSurface::setDeviceOffset' => ['void', 'x'=>'string', 'y'=>'string'],
'CairoSurface::setFallbackResolution' => ['void', 'x'=>'string', 'y'=>'string'],
'CairoSurface::showPage' => ['', 'context'=>'cairocontext'],
'CairoSurface::status' => ['int', 'context'=>'cairocontext'],
'CairoSurface::writeToPng' => ['void', 'file'=>'string'],
'CairoSurfacePattern::__construct' => ['void', 'surface'=>'CairoSurface'],
'CairoSurfacePattern::getExtend' => ['int'],
'CairoSurfacePattern::getFilter' => ['int'],
'CairoSurfacePattern::getSurface' => ['void'],
'CairoSurfacePattern::setExtend' => ['void', 'extend'=>'int'],
'CairoSurfacePattern::setFilter' => ['void', 'filter'=>'string'],
'CairoSvgSurface::__construct' => ['void', 'file'=>'string', 'width'=>'float', 'height'=>'float'],
'CairoSvgSurface::getVersions' => ['array'],
'CairoSvgSurface::restrictToVersion' => ['void', 'version'=>'string'],
'CairoSvgSurface::versionToString' => ['string', 'version'=>'int'],
'cal_days_in_month' => ['int', 'calendar'=>'int', 'month'=>'int', 'year'=>'int'],
'cal_from_jd' => ['array', 'jd'=>'int', 'calendar'=>'int'],
'cal_info' => ['array', 'calendar='=>'int'],
'cal_to_jd' => ['int', 'calendar'=>'int', 'month'=>'int', 'day'=>'int', 'year'=>'int'],
'calcul_hmac' => ['string', 'clent'=>'string', 'siretcode'=>'string', 'price'=>'string', 'reference'=>'string', 'validity'=>'string', 'taxation'=>'string', 'devise'=>'string', 'language'=>'string'],
'calculhmac' => ['string', 'clent'=>'string', 'data'=>'string'],
'call_user_func' => ['mixed', 'function'=>'callable', '...parameters='=>'mixed'],
'call_user_func_array' => ['mixed', 'function'=>'callable', 'parameters'=>'array'],
'call_user_method' => ['mixed', 'method_name'=>'string', 'obj'=>'object', 'parameter='=>'mixed', '...args='=>'mixed'],
'call_user_method_array' => ['mixed', 'method_name'=>'string', 'obj'=>'object', 'params'=>'array'],
'CallbackFilterIterator::__construct' => ['void', 'it'=>'iterator', 'func'=>'callable'],
'CallbackFilterIterator::accept' => ['bool'],
'CallbackFilterIterator::current' => ['mixed'],
'CallbackFilterIterator::getInnerIterator' => ['iterator'],
'CallbackFilterIterator::key' => ['mixed'],
'CallbackFilterIterator::next' => ['void'],
'CallbackFilterIterator::rewind' => ['void'],
'CallbackFilterIterator::valid' => ['bool'],
'ceil' => ['float|int', 'number'=>'float'],
'chdb::__construct' => ['void', 'pathname'=>'string'],
'chdb::get' => ['string', 'key'=>'string'],
'chdb_create' => ['bool', 'pathname'=>'string', 'data'=>'array'],
'chdir' => ['bool', 'directory'=>'string'],
'checkdate' => ['bool', 'month'=>'int', 'day'=>'int', 'year'=>'int'],
'checkdnsrr' => ['bool', 'host'=>'string', 'type='=>'string'],
'chgrp' => ['bool', 'filename'=>'string', 'group'=>'string|int'],
'chmod' => ['bool', 'filename'=>'string', 'mode'=>'int'],
'chop' => ['string', 'str'=>'string', 'character_mask='=>'string'],
'chown' => ['bool', 'filename'=>'string', 'user'=>'string|int'],
'chr' => ['string', 'ascii'=>'int'],
'chroot' => ['bool', 'directory'=>'string'],
'chunk_split' => ['string', 'str'=>'string', 'chunklen='=>'int', 'ending='=>'string'],
'class_alias' => ['bool', 'user_class_name'=>'string', 'alias_name'=>'string', 'autoload='=>'bool'],
'class_exists' => ['bool', 'classname'=>'string', 'autoload='=>'bool'],
'class_implements' => ['array', 'what'=>'object|string', 'autoload='=>'bool'],
'class_parents' => ['array', 'instance'=>'object|string', 'autoload='=>'bool'],
'class_uses' => ['array', 'what'=>'object|string', 'autoload='=>'bool'],
'classkit_import' => ['array', 'filename'=>'string'],
'classkit_method_add' => ['bool', 'classname'=>'string', 'methodname'=>'string', 'args'=>'string', 'code'=>'string', 'flags='=>'int'],
'classkit_method_copy' => ['bool', 'dclass'=>'string', 'dmethod'=>'string', 'sclass'=>'string', 'smethod='=>'string'],
'classkit_method_redefine' => ['bool', 'classname'=>'string', 'methodname'=>'string', 'args'=>'string', 'code'=>'string', 'flags='=>'int'],
'classkit_method_remove' => ['bool', 'classname'=>'string', 'methodname'=>'string'],
'classkit_method_rename' => ['bool', 'classname'=>'string', 'methodname'=>'string', 'newname'=>'string'],
'classObj::__construct' => ['void', 'layer'=>'layerObj', 'class'=>'classObj'],
'classObj::addLabel' => ['int', 'label'=>'labelObj'],
'classObj::convertToString' => ['string'],
'classObj::createLegendIcon' => ['imageObj', 'width'=>'int', 'height'=>'int'],
'classObj::deletestyle' => ['int', 'index'=>'int'],
'classObj::drawLegendIcon' => ['int', 'width'=>'int', 'height'=>'int', 'im'=>'imageObj', 'dstX'=>'int', 'dstY'=>'int'],
'classObj::free' => ['void'],
'classObj::getExpressionString' => ['string'],
'classObj::getLabel' => ['labelObj', 'index'=>'int'],
'classObj::getMetaData' => ['int', 'name'=>'string'],
'classObj::getStyle' => ['styleObj', 'index'=>'int'],
'classObj::getTextString' => ['string'],
'classObj::movestyledown' => ['int', 'index'=>'int'],
'classObj::movestyleup' => ['int', 'index'=>'int'],
'classObj::ms_newClassObj' => ['classObj', 'layer'=>'layerObj', 'class'=>'classObj'],
'classObj::removeLabel' => ['labelObj', 'index'=>'int'],
'classObj::removeMetaData' => ['int', 'name'=>'string'],
'classObj::set' => ['int', 'property_name'=>'string', 'new_value'=>''],
'classObj::setExpression' => ['int', 'expression'=>'string'],
'classObj::setMetaData' => ['int', 'name'=>'string', 'value'=>'string'],
'classObj::settext' => ['int', 'text'=>'string'],
'classObj::updateFromString' => ['int', 'snippet'=>'string'],
'clearstatcache' => ['void', 'clear_realpath_cache='=>'bool', 'filename='=>'string'],
'cli_get_process_title' => ['string'],
'cli_set_process_title' => ['bool', 'arg'=>'string'],
'ClosedGeneratorException::__clone' => ['void'],
'ClosedGeneratorException::__toString' => ['string'],
'ClosedGeneratorException::getCode' => ['int'],
'ClosedGeneratorException::getFile' => ['string'],
'ClosedGeneratorException::getLine' => ['int'],
'ClosedGeneratorException::getMessage' => ['string'],
'ClosedGeneratorException::getPrevious' => ['Throwable|ClosedGeneratorException|null'],
'ClosedGeneratorException::getTrace' => ['array'],
'ClosedGeneratorException::getTraceAsString' => ['string'],
'closedir' => ['void', 'dir_handle='=>'resource'],
'closelog' => ['bool'],
'Closure::__construct' => ['void'],
'Closure::__invoke' => ['', '...args='=>''],
'Closure::bind' => ['Closure', 'old'=>'Closure', 'to'=>'?object', 'scope='=>'object|string'],
'Closure::bindTo' => ['Closure', 'new'=>'?object', 'newscope='=>'object|string'],
'Closure::call' => ['', 'to'=>'object', '...parameters='=>''],
'Closure::fromCallable' => ['Closure', 'callable'=>'callable'],
'clusterObj::convertToString' => ['string'],
'clusterObj::getFilterString' => ['string'],
'clusterObj::getGroupString' => ['string'],
'clusterObj::setFilter' => ['int', 'expression'=>'string'],
'clusterObj::setGroup' => ['int', 'expression'=>'string'],
'Collator::__construct' => ['void', 'locale'=>'string'],
'Collator::asort' => ['bool', '&rw_arr'=>'array', 'sort_flag='=>'int'],
'Collator::compare' => ['int', 'str1'=>'string', 'str2'=>'string'],
'Collator::create' => ['Collator', 'locale'=>'string'],
'Collator::getAttribute' => ['int', 'attr'=>'int'],
'Collator::getErrorCode' => ['int'],
'Collator::getErrorMessage' => ['string'],
'Collator::getLocale' => ['string', 'type'=>'int'],
'Collator::getSortKey' => ['string', 'str'=>'string'],
'Collator::getStrength' => ['int'],
'Collator::setAttribute' => ['bool', 'attr'=>'int', 'val'=>'int'],
'Collator::setStrength' => ['bool', 'strength'=>'int'],
'Collator::sort' => ['bool', '&rw_arr'=>'array', 'sort_flags='=>'int'],
'Collator::sortWithSortKeys' => ['bool', '&rw_arr'=>'array'],
'collator_asort' => ['bool', 'coll'=>'collator', '&rw_arr'=>'array', 'sort_flag='=>'int'],
'collator_compare' => ['int', 'coll'=>'collator', 'str1'=>'string', 'str2'=>'string'],
'collator_create' => ['Collator', 'locale'=>'string'],
'collator_get_attribute' => ['int', 'coll'=>'collator', 'attr'=>'int'],
'collator_get_error_code' => ['int', 'coll'=>'collator'],
'collator_get_error_message' => ['string', 'coll'=>'collator'],
'collator_get_locale' => ['string', 'coll'=>'collator', 'type'=>'int'],
'collator_get_sort_key' => ['string', 'coll'=>'collator', 'str'=>'string'],
'collator_get_strength' => ['int', 'coll'=>'collator'],
'collator_set_attribute' => ['bool', 'coll'=>'collator', 'attr'=>'int', 'val'=>'int'],
'collator_set_strength' => ['bool', 'coll'=>'collator', 'strength'=>'int'],
'collator_sort' => ['bool', 'coll'=>'collator', '&rw_arr'=>'array', 'sort_flag='=>'int'],
'collator_sort_with_sort_keys' => ['bool', 'coll'=>'collator', '&rw_arr'=>'array'],
'Collectable::isGarbage' => ['bool'],
'Collectable::setGarbage' => ['void'],
'colorObj::setHex' => ['int', 'hex'=>'string'],
'colorObj::toHex' => ['string'],
'COM::__call' => ['', 'name'=>'', 'args'=>''],
'COM::__construct' => ['void', 'module_name'=>'string', 'server_name='=>'mixed', 'codepage='=>'int', 'typelib='=>'string'],
'COM::__get' => ['', 'name'=>''],
'COM::__set' => ['', 'name'=>'', 'value'=>''],
'com_addref' => [''],
'com_create_guid' => ['string'],
'com_event_sink' => ['bool', 'comobject'=>'object', 'sinkobject'=>'object', 'sinkinterface='=>'mixed'],
'com_get_active_object' => ['object', 'progid'=>'string', 'code_page='=>'int'],
'com_isenum' => ['bool', 'com_module'=>'variant'],
'com_load_typelib' => ['bool', 'typelib_name'=>'string', 'case_insensitive='=>'int'],
'com_message_pump' => ['bool', 'timeoutms='=>'int'],
'com_print_typeinfo' => ['bool', 'comobject_or_typelib'=>'object', 'dispinterface='=>'string', 'wantsink='=>'bool'],
'com_release' => [''],
'compact' => ['array', '...var_names='=>'string|array'],
'COMPersistHelper::__construct' => ['void', 'com_object'=>'object'],
'COMPersistHelper::GetCurFile' => ['string'],
'COMPersistHelper::GetMaxStreamSize' => ['int'],
'COMPersistHelper::InitNew' => ['int'],
'COMPersistHelper::LoadFromFile' => ['bool', 'filename'=>'string', 'flags'=>'int'],
'COMPersistHelper::LoadFromStream' => ['', 'stream'=>''],
'COMPersistHelper::SaveToFile' => ['bool', 'filename'=>'string', 'remember'=>'bool'],
'COMPersistHelper::SaveToStream' => ['int', 'stream'=>''],
'componere\cast' => ['Type', 'arg1'=>'', 'object'=>''],
'componere\cast_by_ref' => ['Type', 'arg1'=>'', 'object'=>''],
'Cond::broadcast' => ['bool', 'condition'=>'long'],
'Cond::create' => ['long'],
'Cond::destroy' => ['bool', 'condition'=>'long'],
'Cond::signal' => ['bool', 'condition'=>'long'],
'Cond::wait' => ['bool', 'condition'=>'long', 'mutex'=>'long', 'timeout='=>'long'],
'confirm_pdo_ibm_compiled' => [''],
'connection_aborted' => ['int'],
'connection_status' => ['int'],
'connection_timeout' => ['int'],
'constant' => ['mixed', 'const_name'=>'string'],
'convert_cyr_string' => ['string', 'str'=>'string', 'from'=>'string', 'to'=>'string'],
'convert_uudecode' => ['string', 'data'=>'string'],
'convert_uuencode' => ['string', 'data'=>'string'],
'copy' => ['bool', 'source_file'=>'string', 'destination_file'=>'string', 'context='=>'resource'],
'cos' => ['float', 'number'=>'float'],
'cosh' => ['float', 'number'=>'float'],
'Couchbase\AnalyticsQuery::__construct' => ['void'],
'Couchbase\AnalyticsQuery::fromString' => ['Couchbase\AnalyticsQuery', 'statement'=>'string'],
'Couchbase\basicDecoderV1' => ['mixed', 'bytes'=>'string', 'flags'=>'int', 'datatype'=>'int', 'options'=>'array'],
'Couchbase\basicEncoderV1' => ['array', 'value'=>'mixed', 'options'=>'array'],
'Couchbase\BooleanFieldSearchQuery::__construct' => ['void'],
'Couchbase\BooleanFieldSearchQuery::boost' => ['Couchbase\BooleanFieldSearchQuery', 'boost'=>'float'],
'Couchbase\BooleanFieldSearchQuery::field' => ['Couchbase\BooleanFieldSearchQuery', 'field'=>'string'],
'Couchbase\BooleanFieldSearchQuery::jsonSerialize' => ['array'],
'Couchbase\BooleanSearchQuery::__construct' => ['void'],
'Couchbase\BooleanSearchQuery::boost' => ['Couchbase\BooleanSearchQuery', 'boost'=>'float'],
'Couchbase\BooleanSearchQuery::jsonSerialize' => ['array'],
'Couchbase\BooleanSearchQuery::must' => ['Couchbase\BooleanSearchQuery', '...queries='=>'array'],
'Couchbase\BooleanSearchQuery::mustNot' => ['Couchbase\BooleanSearchQuery', '...queries='=>'array'],
'Couchbase\BooleanSearchQuery::should' => ['Couchbase\BooleanSearchQuery', '...queries='=>'array'],
'Couchbase\Bucket::__construct' => ['void'],
'Couchbase\Bucket::__get' => ['int', 'name'=>'string'],
'Couchbase\Bucket::__set' => ['int', 'name'=>'string', 'value'=>'int'],
'Couchbase\Bucket::append' => ['Couchbase\Document|array', 'ids'=>'array|string', 'value'=>'mixed', 'options='=>'array'],
'Couchbase\Bucket::counter' => ['Couchbase\Document|array', 'ids'=>'array|string', 'delta='=>'int', 'options='=>'array'],
'Couchbase\Bucket::diag' => ['array', 'reportId='=>'string'],
'Couchbase\Bucket::get' => ['Couchbase\Document|array', 'ids'=>'array|string', 'options='=>'array'],
'Couchbase\Bucket::getAndLock' => ['Couchbase\Document|array', 'ids'=>'array|string', 'lockTime'=>'int', 'options='=>'array'],
'Couchbase\Bucket::getAndTouch' => ['Couchbase\Document|array', 'ids'=>'array|string', 'expiry'=>'int', 'options='=>'array'],
'Couchbase\Bucket::getFromReplica' => ['Couchbase\Document|array', 'ids'=>'array|string', 'options='=>'array'],
'Couchbase\Bucket::insert' => ['Couchbase\Document|array', 'ids'=>'array|string', 'value'=>'mixed', 'options='=>'array'],
'Couchbase\Bucket::listExists' => ['bool', 'id'=>'string', 'value'=>'mixed'],
'Couchbase\Bucket::listGet' => ['mixed', 'id'=>'string', 'index'=>'int'],
'Couchbase\Bucket::listPush' => ['', 'id'=>'string', 'value'=>'mixed'],
'Couchbase\Bucket::listRemove' => ['', 'id'=>'string', 'index'=>'int'],
'Couchbase\Bucket::listSet' => ['', 'id'=>'string', 'index'=>'int', 'value'=>'mixed'],
'Couchbase\Bucket::listShift' => ['', 'id'=>'string', 'value'=>'mixed'],
'Couchbase\Bucket::listSize' => ['int', 'id'=>'string'],
'Couchbase\Bucket::lookupIn' => ['Couchbase\LookupInBuilder', 'id'=>'string'],
'Couchbase\Bucket::manager' => ['Couchbase\BucketManager'],
'Couchbase\Bucket::mapAdd' => ['', 'id'=>'string', 'key'=>'string', 'value'=>'mixed'],
'Couchbase\Bucket::mapGet' => ['mixed', 'id'=>'string', 'key'=>'string'],
'Couchbase\Bucket::mapRemove' => ['', 'id'=>'string', 'key'=>'string'],
'Couchbase\Bucket::mapSize' => ['int', 'id'=>'string'],
'Couchbase\Bucket::mutateIn' => ['Couchbase\MutateInBuilder', 'id'=>'string', 'cas'=>'string'],
'Couchbase\Bucket::ping' => ['array', 'services='=>'int', 'reportId='=>'string'],
'Couchbase\Bucket::prepend' => ['Couchbase\Document|array', 'ids'=>'array|string', 'value'=>'mixed', 'options='=>'array'],
'Couchbase\Bucket::query' => ['object', 'query'=>'Couchbase\AnalyticsQuery|Couchbase\N1qlQuery|Couchbase\SearchQuery|Couchbase\SpatialViewQuery|Couchbase\ViewQuery', 'jsonAsArray='=>'bool|false'],
'Couchbase\Bucket::queueAdd' => ['', 'id'=>'string', 'value'=>'mixed'],
'Couchbase\Bucket::queueExists' => ['bool', 'id'=>'string', 'value'=>'mixed'],
'Couchbase\Bucket::queueRemove' => ['mixed', 'id'=>'string'],
'Couchbase\Bucket::queueSize' => ['int', 'id'=>'string'],
'Couchbase\Bucket::remove' => ['Couchbase\Document|array', 'ids'=>'array|string', 'options='=>'array'],
'Couchbase\Bucket::replace' => ['Couchbase\Document|array', 'ids'=>'array|string', 'value'=>'mixed', 'options='=>'array'],
'Couchbase\Bucket::retrieveIn' => ['Couchbase\DocumentFragment', 'id'=>'string', '...paths='=>'array'],
'Couchbase\Bucket::setAdd' => ['', 'id'=>'string', 'value'=>'bool|float|int|string'],
'Couchbase\Bucket::setExists' => ['bool', 'id'=>'string', 'value'=>'bool|float|int|string'],
'Couchbase\Bucket::setRemove' => ['', 'id'=>'string', 'value'=>'bool|float|int|string'],
'Couchbase\Bucket::setSize' => ['int', 'id'=>'string'],
'Couchbase\Bucket::setTranscoder' => ['', 'encoder'=>'callable', 'decoder'=>'callable'],
'Couchbase\Bucket::touch' => ['Couchbase\Document|array', 'ids'=>'array|string', 'expiry'=>'int', 'options='=>'array'],
'Couchbase\Bucket::unlock' => ['Couchbase\Document|array', 'ids'=>'array|string', 'options='=>'array'],
'Couchbase\Bucket::upsert' => ['Couchbase\Document|array', 'ids'=>'array|string', 'value'=>'mixed', 'options='=>'array'],
'Couchbase\BucketManager::__construct' => ['void'],
'Couchbase\BucketManager::createN1qlIndex' => ['', 'name'=>'string', 'fields'=>'array', 'whereClause='=>'string', 'ignoreIfExist='=>'bool|false', 'defer='=>'bool|false'],
'Couchbase\BucketManager::createN1qlPrimaryIndex' => ['', 'customName='=>'string', 'ignoreIfExist='=>'bool|false', 'defer='=>'bool|false'],
'Couchbase\BucketManager::dropN1qlIndex' => ['', 'name'=>'string', 'ignoreIfNotExist='=>'bool|false'],
'Couchbase\BucketManager::dropN1qlPrimaryIndex' => ['', 'customName='=>'string', 'ignoreIfNotExist='=>'bool|false'],
'Couchbase\BucketManager::flush' => [''],
'Couchbase\BucketManager::getDesignDocument' => ['array', 'name'=>'string'],
'Couchbase\BucketManager::info' => ['array'],
'Couchbase\BucketManager::insertDesignDocument' => ['', 'name'=>'string', 'document'=>'array'],
'Couchbase\BucketManager::listDesignDocuments' => ['array'],
'Couchbase\BucketManager::listN1qlIndexes' => ['array'],
'Couchbase\BucketManager::removeDesignDocument' => ['', 'name'=>'string'],
'Couchbase\BucketManager::upsertDesignDocument' => ['', 'name'=>'string', 'document'=>'array'],
'Couchbase\ClassicAuthenticator::bucket' => ['', 'name'=>'string', 'password'=>'string'],
'Couchbase\ClassicAuthenticator::cluster' => ['', 'username'=>'string', 'password'=>'string'],
'Couchbase\Cluster::__construct' => ['void', 'connstr'=>'string'],
'Couchbase\Cluster::authenticate' => ['null', 'authenticator'=>'Couchbase\Authenticator'],
'Couchbase\Cluster::authenticateAs' => ['null', 'username'=>'string', 'password'=>'string'],
'Couchbase\Cluster::manager' => ['Couchbase\ClusterManager', 'username='=>'string', 'password='=>'string'],
'Couchbase\Cluster::openBucket' => ['Couchbase\Bucket', 'name='=>'string', 'password='=>'string'],
'Couchbase\ClusterManager::__construct' => ['void'],
'Couchbase\ClusterManager::createBucket' => ['', 'name'=>'string', 'options='=>'array'],
'Couchbase\ClusterManager::getUser' => ['array', 'username'=>'string', 'domain='=>'int'],
'Couchbase\ClusterManager::info' => ['array'],
'Couchbase\ClusterManager::listBuckets' => ['array'],
'Couchbase\ClusterManager::listUsers' => ['array', 'domain='=>'int'],
'Couchbase\ClusterManager::removeBucket' => ['', 'name'=>'string'],
'Couchbase\ClusterManager::removeUser' => ['', 'name'=>'string', 'domain='=>'int'],
'Couchbase\ClusterManager::upsertUser' => ['', 'name'=>'string', 'settings'=>'Couchbase\UserSettings', 'domain='=>'int'],
'Couchbase\ConjunctionSearchQuery::__construct' => ['void'],
'Couchbase\ConjunctionSearchQuery::boost' => ['Couchbase\ConjunctionSearchQuery', 'boost'=>'float'],
'Couchbase\ConjunctionSearchQuery::every' => ['Couchbase\ConjunctionSearchQuery', '...queries='=>'array'],
'Couchbase\ConjunctionSearchQuery::jsonSerialize' => ['array'],
'Couchbase\DateRangeSearchFacet::__construct' => ['void'],
'Couchbase\DateRangeSearchFacet::addRange' => ['Couchbase\DateSearchFacet', 'name'=>'string', 'start'=>'int|string', 'end'=>'int|string'],
'Couchbase\DateRangeSearchFacet::jsonSerialize' => ['array'],
'Couchbase\DateRangeSearchQuery::__construct' => ['void'],
'Couchbase\DateRangeSearchQuery::boost' => ['Couchbase\DateRangeSearchQuery', 'boost'=>'float'],
'Couchbase\DateRangeSearchQuery::dateTimeParser' => ['Couchbase\DateRangeSearchQuery', 'dateTimeParser'=>'string'],
'Couchbase\DateRangeSearchQuery::end' => ['Couchbase\DateRangeSearchQuery', 'end'=>'int|string', 'inclusive='=>'bool|false'],
'Couchbase\DateRangeSearchQuery::field' => ['Couchbase\DateRangeSearchQuery', 'field'=>'string'],
'Couchbase\DateRangeSearchQuery::jsonSerialize' => ['array'],
'Couchbase\DateRangeSearchQuery::start' => ['Couchbase\DateRangeSearchQuery', 'start'=>'int|string', 'inclusive='=>'bool|true'],
'Couchbase\defaultDecoder' => ['mixed', 'bytes'=>'string', 'flags'=>'int', 'datatype'=>'int'],
'Couchbase\defaultEncoder' => ['array', 'value'=>'mixed'],
'Couchbase\DisjunctionSearchQuery::__construct' => ['void'],
'Couchbase\DisjunctionSearchQuery::boost' => ['Couchbase\DisjunctionSearchQuery', 'boost'=>'float'],
'Couchbase\DisjunctionSearchQuery::either' => ['Couchbase\DisjunctionSearchQuery', '...queries='=>'array'],
'Couchbase\DisjunctionSearchQuery::jsonSerialize' => ['array'],
'Couchbase\DisjunctionSearchQuery::min' => ['Couchbase\DisjunctionSearchQuery', 'min'=>'int'],
'Couchbase\DocIdSearchQuery::__construct' => ['void'],
'Couchbase\DocIdSearchQuery::boost' => ['Couchbase\DocIdSearchQuery', 'boost'=>'float'],
'Couchbase\DocIdSearchQuery::docIds' => ['Couchbase\DocIdSearchQuery', '...documentIds='=>'array'],
'Couchbase\DocIdSearchQuery::field' => ['Couchbase\DocIdSearchQuery', 'field'=>'string'],
'Couchbase\DocIdSearchQuery::jsonSerialize' => ['array'],
'Couchbase\fastlzCompress' => ['string', 'data'=>'string'],
'Couchbase\fastlzDecompress' => ['string', 'data'=>'string'],
'Couchbase\GeoBoundingBoxSearchQuery::__construct' => ['void'],
'Couchbase\GeoBoundingBoxSearchQuery::boost' => ['Couchbase\GeoBoundingBoxSearchQuery', 'boost'=>'float'],
'Couchbase\GeoBoundingBoxSearchQuery::field' => ['Couchbase\GeoBoundingBoxSearchQuery', 'field'=>'string'],
'Couchbase\GeoBoundingBoxSearchQuery::jsonSerialize' => ['array'],
'Couchbase\GeoDistanceSearchQuery::__construct' => ['void'],
'Couchbase\GeoDistanceSearchQuery::boost' => ['Couchbase\GeoDistanceSearchQuery', 'boost'=>'float'],
'Couchbase\GeoDistanceSearchQuery::field' => ['Couchbase\GeoDistanceSearchQuery', 'field'=>'string'],
'Couchbase\GeoDistanceSearchQuery::jsonSerialize' => ['array'],
'Couchbase\LookupInBuilder::__construct' => ['void'],
'Couchbase\LookupInBuilder::execute' => ['Couchbase\DocumentFragment'],
'Couchbase\LookupInBuilder::exists' => ['Couchbase\LookupInBuilder', 'path'=>'string', 'options='=>'array'],
'Couchbase\LookupInBuilder::get' => ['Couchbase\LookupInBuilder', 'path'=>'string', 'options='=>'array'],
'Couchbase\LookupInBuilder::getCount' => ['Couchbase\LookupInBuilder', 'path'=>'string', 'options='=>'array'],
'Couchbase\MatchAllSearchQuery::__construct' => ['void'],
'Couchbase\MatchAllSearchQuery::boost' => ['Couchbase\MatchAllSearchQuery', 'boost'=>'float'],
'Couchbase\MatchAllSearchQuery::jsonSerialize' => ['array'],
'Couchbase\MatchNoneSearchQuery::__construct' => ['void'],
'Couchbase\MatchNoneSearchQuery::boost' => ['Couchbase\MatchNoneSearchQuery', 'boost'=>'float'],
'Couchbase\MatchNoneSearchQuery::jsonSerialize' => ['array'],
'Couchbase\MatchPhraseSearchQuery::__construct' => ['void'],
'Couchbase\MatchPhraseSearchQuery::analyzer' => ['Couchbase\MatchPhraseSearchQuery', 'analyzer'=>'string'],
'Couchbase\MatchPhraseSearchQuery::boost' => ['Couchbase\MatchPhraseSearchQuery', 'boost'=>'float'],
'Couchbase\MatchPhraseSearchQuery::field' => ['Couchbase\MatchPhraseSearchQuery', 'field'=>'string'],
'Couchbase\MatchPhraseSearchQuery::jsonSerialize' => ['array'],
'Couchbase\MatchSearchQuery::__construct' => ['void'],
'Couchbase\MatchSearchQuery::analyzer' => ['Couchbase\MatchSearchQuery', 'analyzer'=>'string'],
'Couchbase\MatchSearchQuery::boost' => ['Couchbase\MatchSearchQuery', 'boost'=>'float'],
'Couchbase\MatchSearchQuery::field' => ['Couchbase\MatchSearchQuery', 'field'=>'string'],
'Couchbase\MatchSearchQuery::fuzziness' => ['Couchbase\MatchSearchQuery', 'fuzziness'=>'int'],
'Couchbase\MatchSearchQuery::jsonSerialize' => ['array'],
'Couchbase\MatchSearchQuery::prefixLength' => ['Couchbase\MatchSearchQuery', 'prefixLength'=>'int'],
'Couchbase\MutateInBuilder::__construct' => ['void'],
'Couchbase\MutateInBuilder::arrayAddUnique' => ['Couchbase\MutateInBuilder', 'path'=>'string', 'value'=>'mixed', 'options='=>'array|bool'],
'Couchbase\MutateInBuilder::arrayAppend' => ['Couchbase\MutateInBuilder', 'path'=>'string', 'value'=>'mixed', 'options='=>'array|bool'],
'Couchbase\MutateInBuilder::arrayAppendAll' => ['Couchbase\MutateInBuilder', 'path'=>'string', 'values'=>'array', 'options='=>'array|bool'],
'Couchbase\MutateInBuilder::arrayInsert' => ['Couchbase\MutateInBuilder', 'path'=>'string', 'value'=>'mixed', 'options='=>'array'],
'Couchbase\MutateInBuilder::arrayInsertAll' => ['Couchbase\MutateInBuilder', 'path'=>'string', 'values'=>'array', 'options='=>'array'],
'Couchbase\MutateInBuilder::arrayPrepend' => ['Couchbase\MutateInBuilder', 'path'=>'string', 'value'=>'mixed', 'options='=>'array|bool'],
'Couchbase\MutateInBuilder::arrayPrependAll' => ['Couchbase\MutateInBuilder', 'path'=>'string', 'values'=>'array', 'options='=>'array|bool'],
'Couchbase\MutateInBuilder::counter' => ['Couchbase\MutateInBuilder', 'path'=>'string', 'delta'=>'int', 'options='=>'array|bool'],
'Couchbase\MutateInBuilder::execute' => ['Couchbase\DocumentFragment'],
'Couchbase\MutateInBuilder::insert' => ['Couchbase\MutateInBuilder', 'path'=>'string', 'value'=>'mixed', 'options='=>'array|bool'],
'Couchbase\MutateInBuilder::modeDocument' => ['', 'mode'=>'int'],
'Couchbase\MutateInBuilder::remove' => ['Couchbase\MutateInBuilder', 'path'=>'string', 'options='=>'array'],
'Couchbase\MutateInBuilder::replace' => ['Couchbase\MutateInBuilder', 'path'=>'string', 'value'=>'mixed', 'options='=>'array'],
'Couchbase\MutateInBuilder::upsert' => ['Couchbase\MutateInBuilder', 'path'=>'string', 'value'=>'mixed', 'options='=>'array|bool'],
'Couchbase\MutateInBuilder::withExpiry' => ['Couchbase\MutateInBuilder', 'expiry'=>'Couchbase\expiry'],
'Couchbase\MutationState::__construct' => ['void'],
'Couchbase\MutationState::add' => ['', 'source'=>'Couchbase\Document|Couchbase\DocumentFragment|array'],
'Couchbase\MutationState::from' => ['Couchbase\MutationState', 'source'=>'Couchbase\Document|Couchbase\DocumentFragment|array'],
'Couchbase\MutationToken::__construct' => ['void'],
'Couchbase\MutationToken::bucketName' => ['string'],
'Couchbase\MutationToken::from' => ['', 'bucketName'=>'string', 'vbucketId'=>'int', 'vbucketUuid'=>'string', 'sequenceNumber'=>'string'],
'Couchbase\MutationToken::sequenceNumber' => ['string'],
'Couchbase\MutationToken::vbucketId' => ['int'],
'Couchbase\MutationToken::vbucketUuid' => ['string'],
'Couchbase\N1qlIndex::__construct' => ['void'],
'Couchbase\N1qlQuery::__construct' => ['void'],
'Couchbase\N1qlQuery::adhoc' => ['Couchbase\N1qlQuery', 'adhoc'=>'bool'],
'Couchbase\N1qlQuery::consistency' => ['Couchbase\N1qlQuery', 'consistency'=>'int'],
'Couchbase\N1qlQuery::consistentWith' => ['Couchbase\N1qlQuery', 'state'=>'Couchbase\MutationState'],
'Couchbase\N1qlQuery::crossBucket' => ['Couchbase\N1qlQuery', 'crossBucket'=>'bool'],
'Couchbase\N1qlQuery::fromString' => ['Couchbase\N1qlQuery', 'statement'=>'string'],
'Couchbase\N1qlQuery::maxParallelism' => ['Couchbase\N1qlQuery', 'maxParallelism'=>'int'],
'Couchbase\N1qlQuery::namedParams' => ['Couchbase\N1qlQuery', 'params'=>'array'],
'Couchbase\N1qlQuery::pipelineBatch' => ['Couchbase\N1qlQuery', 'pipelineBatch'=>'int'],
'Couchbase\N1qlQuery::pipelineCap' => ['Couchbase\N1qlQuery', 'pipelineCap'=>'int'],
'Couchbase\N1qlQuery::positionalParams' => ['Couchbase\N1qlQuery', 'params'=>'array'],
'Couchbase\N1qlQuery::readonly' => ['Couchbase\N1qlQuery', 'readonly'=>'bool'],
'Couchbase\N1qlQuery::scanCap' => ['Couchbase\N1qlQuery', 'scanCap'=>'int'],
'Couchbase\NumericRangeSearchFacet::__construct' => ['void'],
'Couchbase\NumericRangeSearchFacet::addRange' => ['Couchbase\NumericSearchFacet', 'name'=>'string', 'min'=>'float', 'max'=>'float'],
'Couchbase\NumericRangeSearchFacet::jsonSerialize' => ['array'],
'Couchbase\NumericRangeSearchQuery::__construct' => ['void'],
'Couchbase\NumericRangeSearchQuery::boost' => ['Couchbase\NumericRangeSearchQuery', 'boost'=>'float'],
'Couchbase\NumericRangeSearchQuery::field' => ['Couchbase\NumericRangeSearchQuery', 'field'=>'string'],
'Couchbase\NumericRangeSearchQuery::jsonSerialize' => ['array'],
'Couchbase\NumericRangeSearchQuery::max' => ['Couchbase\NumericRangeSearchQuery', 'max'=>'float', 'inclusive='=>'bool|false'],
'Couchbase\NumericRangeSearchQuery::min' => ['Couchbase\NumericRangeSearchQuery', 'min'=>'float', 'inclusive='=>'bool|true'],
'Couchbase\passthruDecoder' => ['string', 'bytes'=>'string', 'flags'=>'int', 'datatype'=>'int'],
'Couchbase\passthruEncoder' => ['array', 'value'=>'string'],
'Couchbase\PasswordAuthenticator::password' => ['Couchbase\PasswordAuthenticator', 'password'=>'string'],
'Couchbase\PasswordAuthenticator::username' => ['Couchbase\PasswordAuthenticator', 'username'=>'string'],
'Couchbase\PhraseSearchQuery::__construct' => ['void'],
'Couchbase\PhraseSearchQuery::boost' => ['Couchbase\PhraseSearchQuery', 'boost'=>'float'],
'Couchbase\PhraseSearchQuery::field' => ['Couchbase\PhraseSearchQuery', 'field'=>'string'],
'Couchbase\PhraseSearchQuery::jsonSerialize' => ['array'],
'Couchbase\PrefixSearchQuery::__construct' => ['void'],
'Couchbase\PrefixSearchQuery::boost' => ['Couchbase\PrefixSearchQuery', 'boost'=>'float'],
'Couchbase\PrefixSearchQuery::field' => ['Couchbase\PrefixSearchQuery', 'field'=>'string'],
'Couchbase\PrefixSearchQuery::jsonSerialize' => ['array'],
'Couchbase\QueryStringSearchQuery::__construct' => ['void'],
'Couchbase\QueryStringSearchQuery::boost' => ['Couchbase\QueryStringSearchQuery', 'boost'=>'float'],
'Couchbase\QueryStringSearchQuery::jsonSerialize' => ['array'],
'Couchbase\RegexpSearchQuery::__construct' => ['void'],
'Couchbase\RegexpSearchQuery::boost' => ['Couchbase\RegexpSearchQuery', 'boost'=>'float'],
'Couchbase\RegexpSearchQuery::field' => ['Couchbase\RegexpSearchQuery', 'field'=>'string'],
'Couchbase\RegexpSearchQuery::jsonSerialize' => ['array'],
'Couchbase\SearchQuery::__construct' => ['void', 'indexName'=>'string', 'queryPart'=>'Couchbase\SearchQueryPart'],
'Couchbase\SearchQuery::addFacet' => ['Couchbase\SearchQuery', 'name'=>'string', 'facet'=>'Couchbase\SearchFacet'],
'Couchbase\SearchQuery::boolean' => ['Couchbase\BooleanSearchQuery'],
'Couchbase\SearchQuery::booleanField' => ['Couchbase\BooleanFieldSearchQuery', 'value'=>'bool'],
'Couchbase\SearchQuery::conjuncts' => ['Couchbase\ConjunctionSearchQuery', '...queries='=>'array'],
'Couchbase\SearchQuery::consistentWith' => ['Couchbase\SearchQuery', 'state'=>'Couchbase\MutationState'],
'Couchbase\SearchQuery::dateRange' => ['Couchbase\DateRangeSearchQuery'],
'Couchbase\SearchQuery::dateRangeFacet' => ['Couchbase\DateRangeSearchFacet', 'field'=>'string', 'limit'=>'int'],
'Couchbase\SearchQuery::disjuncts' => ['Couchbase\DisjunctionSearchQuery', '...queries='=>'array'],
'Couchbase\SearchQuery::docId' => ['Couchbase\DocIdSearchQuery', '...documentIds='=>'array'],
'Couchbase\SearchQuery::explain' => ['Couchbase\SearchQuery', 'explain'=>'bool'],
'Couchbase\SearchQuery::fields' => ['Couchbase\SearchQuery', '...fields='=>'array'],
'Couchbase\SearchQuery::geoBoundingBox' => ['Couchbase\GeoBoundingBoxSearchQuery', 'topLeftLongitude'=>'float', 'topLeftLatitude'=>'float', 'bottomRightLongitude'=>'float', 'bottomRightLatitude'=>'float'],
'Couchbase\SearchQuery::geoDistance' => ['Couchbase\GeoDistanceSearchQuery', 'longitude'=>'float', 'latitude'=>'float', 'distance'=>'string'],
'Couchbase\SearchQuery::highlight' => ['Couchbase\SearchQuery', 'style'=>'string', '...fields='=>'array'],
'Couchbase\SearchQuery::jsonSerialize' => ['array'],
'Couchbase\SearchQuery::limit' => ['Couchbase\SearchQuery', 'limit'=>'int'],
'Couchbase\SearchQuery::match' => ['Couchbase\MatchSearchQuery', 'match'=>'string'],
'Couchbase\SearchQuery::matchAll' => ['Couchbase\MatchAllSearchQuery'],
'Couchbase\SearchQuery::matchNone' => ['Couchbase\MatchNoneSearchQuery'],
'Couchbase\SearchQuery::matchPhrase' => ['Couchbase\MatchPhraseSearchQuery', '...terms='=>'array'],
'Couchbase\SearchQuery::numericRange' => ['Couchbase\NumericRangeSearchQuery'],
'Couchbase\SearchQuery::numericRangeFacet' => ['Couchbase\NumericRangeSearchFacet', 'field'=>'string', 'limit'=>'int'],
'Couchbase\SearchQuery::prefix' => ['Couchbase\PrefixSearchQuery', 'prefix'=>'string'],
'Couchbase\SearchQuery::queryString' => ['Couchbase\QueryStringSearchQuery', 'queryString'=>'string'],
'Couchbase\SearchQuery::regexp' => ['Couchbase\RegexpSearchQuery', 'regexp'=>'string'],
'Couchbase\SearchQuery::serverSideTimeout' => ['Couchbase\SearchQuery', 'serverSideTimeout'=>'int'],
'Couchbase\SearchQuery::skip' => ['Couchbase\SearchQuery', 'skip'=>'int'],
'Couchbase\SearchQuery::sort' => ['Couchbase\SearchQuery', '...sort='=>'array'],
'Couchbase\SearchQuery::term' => ['Couchbase\TermSearchQuery', 'term'=>'string'],
'Couchbase\SearchQuery::termFacet' => ['Couchbase\TermSearchFacet', 'field'=>'string', 'limit'=>'int'],
'Couchbase\SearchQuery::termRange' => ['Couchbase\TermRangeSearchQuery'],
'Couchbase\SearchQuery::wildcard' => ['Couchbase\WildcardSearchQuery', 'wildcard'=>'string'],
'Couchbase\SpatialViewQuery::__construct' => ['void'],
'Couchbase\SpatialViewQuery::bbox' => ['Couchbase\SpatialViewQuery', 'bbox'=>'array'],
'Couchbase\SpatialViewQuery::consistency' => ['Couchbase\SpatialViewQuery', 'consistency'=>'int'],
'Couchbase\SpatialViewQuery::custom' => ['', 'customParameters'=>'array'],
'Couchbase\SpatialViewQuery::encode' => ['array'],
'Couchbase\SpatialViewQuery::endRange' => ['Couchbase\SpatialViewQuery', 'range'=>'array'],
'Couchbase\SpatialViewQuery::limit' => ['Couchbase\SpatialViewQuery', 'limit'=>'int'],
'Couchbase\SpatialViewQuery::order' => ['Couchbase\SpatialViewQuery', 'order'=>'int'],
'Couchbase\SpatialViewQuery::skip' => ['Couchbase\SpatialViewQuery', 'skip'=>'int'],
'Couchbase\SpatialViewQuery::startRange' => ['Couchbase\SpatialViewQuery', 'range'=>'array'],
'Couchbase\TermRangeSearchQuery::__construct' => ['void'],
'Couchbase\TermRangeSearchQuery::boost' => ['Couchbase\TermRangeSearchQuery', 'boost'=>'float'],
'Couchbase\TermRangeSearchQuery::field' => ['Couchbase\TermRangeSearchQuery', 'field'=>'string'],
'Couchbase\TermRangeSearchQuery::jsonSerialize' => ['array'],
'Couchbase\TermRangeSearchQuery::max' => ['Couchbase\TermRangeSearchQuery', 'max'=>'string', 'inclusive='=>'bool|false'],
'Couchbase\TermRangeSearchQuery::min' => ['Couchbase\TermRangeSearchQuery', 'min'=>'string', 'inclusive='=>'bool|true'],
'Couchbase\TermSearchFacet::__construct' => ['void'],
'Couchbase\TermSearchFacet::jsonSerialize' => ['array'],
'Couchbase\TermSearchQuery::__construct' => ['void'],
'Couchbase\TermSearchQuery::boost' => ['Couchbase\TermSearchQuery', 'boost'=>'float'],
'Couchbase\TermSearchQuery::field' => ['Couchbase\TermSearchQuery', 'field'=>'string'],
'Couchbase\TermSearchQuery::fuzziness' => ['Couchbase\TermSearchQuery', 'fuzziness'=>'int'],
'Couchbase\TermSearchQuery::jsonSerialize' => ['array'],
'Couchbase\TermSearchQuery::prefixLength' => ['Couchbase\TermSearchQuery', 'prefixLength'=>'int'],
'Couchbase\UserSettings::fullName' => ['Couchbase\UserSettings', 'fullName'=>'string'],
'Couchbase\UserSettings::password' => ['Couchbase\UserSettings', 'password'=>'string'],
'Couchbase\UserSettings::role' => ['Couchbase\UserSettings', 'role'=>'string', 'bucket='=>'string'],
'Couchbase\ViewQuery::__construct' => ['void'],
'Couchbase\ViewQuery::consistency' => ['Couchbase\ViewQuery', 'consistency'=>'int'],
'Couchbase\ViewQuery::custom' => ['Couchbase\ViewQuery', 'customParameters'=>'array'],
'Couchbase\ViewQuery::encode' => ['array'],
'Couchbase\ViewQuery::from' => ['Couchbase\ViewQuery', 'designDocumentName'=>'string', 'viewName'=>'string'],
'Couchbase\ViewQuery::fromSpatial' => ['Couchbase\SpatialViewQuery', 'designDocumentName'=>'string', 'viewName'=>'string'],
'Couchbase\ViewQuery::group' => ['Couchbase\ViewQuery', 'group'=>'bool'],
'Couchbase\ViewQuery::groupLevel' => ['Couchbase\ViewQuery', 'groupLevel'=>'int'],
'Couchbase\ViewQuery::idRange' => ['Couchbase\ViewQuery', 'startKeyDocumentId'=>'string', 'endKeyDocumentId'=>'string'],
'Couchbase\ViewQuery::key' => ['Couchbase\ViewQuery', 'key'=>'mixed'],
'Couchbase\ViewQuery::keys' => ['Couchbase\ViewQuery', 'keys'=>'array'],
'Couchbase\ViewQuery::limit' => ['Couchbase\ViewQuery', 'limit'=>'int'],
'Couchbase\ViewQuery::order' => ['Couchbase\ViewQuery', 'order'=>'int'],
'Couchbase\ViewQuery::range' => ['Couchbase\ViewQuery', 'startKey'=>'mixed', 'endKey'=>'mixed', 'inclusiveEnd='=>'bool|false'],
'Couchbase\ViewQuery::reduce' => ['Couchbase\ViewQuery', 'reduce'=>'bool'],
'Couchbase\ViewQuery::skip' => ['Couchbase\ViewQuery', 'skip'=>'int'],
'Couchbase\ViewQueryEncodable::encode' => ['array'],
'Couchbase\WildcardSearchQuery::__construct' => ['void'],
'Couchbase\WildcardSearchQuery::boost' => ['Couchbase\WildcardSearchQuery', 'boost'=>'float'],
'Couchbase\WildcardSearchQuery::field' => ['Couchbase\WildcardSearchQuery', 'field'=>'string'],
'Couchbase\WildcardSearchQuery::jsonSerialize' => ['array'],
'Couchbase\zlibCompress' => ['string', 'data'=>'string'],
'Couchbase\zlibDecompress' => ['string', 'data'=>'string'],
'count' => ['int', 'var'=>'Countable|array', 'mode='=>'int'],
'count_chars' => ['mixed', 'input'=>'string', 'mode='=>'int'],
'Countable::count' => ['int'],
'crack_check' => ['bool', 'dictionary'=>'', 'password'=>'string'],
'crack_closedict' => ['bool', 'dictionary='=>'resource'],
'crack_getlastmessage' => ['string'],
'crack_opendict' => ['resource', 'dictionary'=>'string'],
'crash' => [''],
'crc32' => ['int', 'str'=>'string'],
'create_function' => ['string', 'args'=>'string', 'code'=>'string'],
'crypt' => ['string', 'str'=>'string', 'salt='=>'string'],
'ctype_alnum' => ['bool', 'c'=>'string|int'],
'ctype_alpha' => ['bool', 'c'=>'string|int'],
'ctype_cntrl' => ['bool', 'c'=>'string|int'],
'ctype_digit' => ['bool', 'c'=>'string|int'],
'ctype_graph' => ['bool', 'c'=>'string|int'],
'ctype_lower' => ['bool', 'c'=>'string|int'],
'ctype_print' => ['bool', 'c'=>'string|int'],
'ctype_punct' => ['bool', 'c'=>'string|int'],
'ctype_space' => ['bool', 'c'=>'string|int'],
'ctype_upper' => ['bool', 'c'=>'string|int'],
'ctype_xdigit' => ['bool', 'c'=>'string|int'],
'cubrid_affected_rows' => ['int', 'req_identifier='=>''],
'cubrid_bind' => ['bool', 'req_identifier'=>'resource', 'bind_param'=>'int', 'bind_value'=>'mixed', 'bind_value_type='=>'string'],
'cubrid_client_encoding' => ['string', 'conn_identifier='=>''],
'cubrid_close' => ['bool', 'conn_identifier='=>''],
'cubrid_close_prepare' => ['int', 'req_identifier'=>'resource'],
'cubrid_close_request' => ['bool', 'req_identifier'=>'resource'],
'cubrid_col_get' => ['array', 'conn_identifier'=>'resource', 'oid'=>'string', 'attr_name'=>'string'],
'cubrid_col_size' => ['int', 'conn_identifier'=>'resource', 'oid'=>'string', 'attr_name'=>'string'],
'cubrid_column_names' => ['array', 'req_identifier'=>'resource'],
'cubrid_column_types' => ['array', 'req_identifier'=>'resource'],
'cubrid_commit' => ['bool', 'conn_identifier'=>'resource'],
'cubrid_connect' => ['resource', 'host'=>'string', 'port'=>'int', 'dbname'=>'string', 'userid='=>'string', 'passwd='=>'string'],
'cubrid_connect_with_url' => ['resource', 'conn_url'=>'string', 'userid='=>'string', 'passwd='=>'string'],
'cubrid_current_oid' => ['string', 'req_identifier'=>'resource'],
'cubrid_data_seek' => ['bool', 'req_identifier'=>'', 'row_number'=>'int'],
'cubrid_db_name' => ['string', 'result'=>'array', 'index'=>'int'],
'cubrid_db_parameter' => ['array', 'conn_identifier'=>'resource'],
'cubrid_disconnect' => ['bool', 'conn_identifier'=>'resource'],
'cubrid_drop' => ['bool', 'conn_identifier'=>'resource', 'oid'=>'string'],
'cubrid_errno' => ['int', 'conn_identifier='=>''],
'cubrid_error' => ['string', 'connection='=>''],
'cubrid_error_code' => ['int'],
'cubrid_error_code_facility' => ['int'],
'cubrid_error_msg' => ['string'],
'cubrid_execute' => ['bool', 'conn_identifier'=>'', 'sql'=>'string', 'option='=>'int', 'request_identifier='=>''],
'cubrid_fetch' => ['mixed', 'result'=>'resource', 'type='=>'int'],
'cubrid_fetch_array' => ['array', 'result'=>'', 'type='=>'int'],
'cubrid_fetch_assoc' => ['array', 'result'=>''],
'cubrid_fetch_field' => ['object', 'result'=>'', 'field_offset='=>'int'],
'cubrid_fetch_lengths' => ['array', 'result'=>''],
'cubrid_fetch_object' => ['object', 'result'=>'', 'class_name='=>'string', 'params='=>'array'],
'cubrid_fetch_row' => ['array', 'result'=>''],
'cubrid_field_flags' => ['string', 'result'=>'', 'field_offset'=>'int'],
'cubrid_field_len' => ['int', 'result'=>'', 'field_offset'=>'int'],
'cubrid_field_name' => ['string', 'result'=>'', 'field_offset'=>'int'],
'cubrid_field_seek' => ['bool', 'result'=>'', 'field_offset='=>'int'],
'cubrid_field_table' => ['string', 'result'=>'', 'field_offset'=>'int'],
'cubrid_field_type' => ['string', 'result'=>'', 'field_offset'=>'int'],
'cubrid_free_result' => ['bool', 'req_identifier'=>'resource'],
'cubrid_get' => ['mixed', 'conn_identifier'=>'resource', 'oid'=>'string', 'attr='=>'mixed'],
'cubrid_get_autocommit' => ['bool', 'conn_identifier'=>'resource'],
'cubrid_get_charset' => ['string', 'conn_identifier'=>'resource'],
'cubrid_get_class_name' => ['string', 'conn_identifier'=>'resource', 'oid'=>'string'],
'cubrid_get_client_info' => ['string'],
'cubrid_get_db_parameter' => ['array', 'conn_identifier'=>'resource'],
'cubrid_get_query_timeout' => ['int', 'req_identifier'=>'resource'],
'cubrid_get_server_info' => ['string', 'conn_identifier'=>'resource'],
'cubrid_insert_id' => ['string', 'conn_identifier='=>'resource'],
'cubrid_is_instance' => ['int', 'conn_identifier'=>'resource', 'oid'=>'string'],
'cubrid_list_dbs' => ['array', 'conn_identifier'=>''],
'cubrid_load_from_glo' => ['int', 'conn_identifier'=>'', 'oid'=>'string', 'file_name'=>'string'],
'cubrid_lob2_bind' => ['bool', 'req_identifier'=>'resource', 'bind_index'=>'int', 'bind_value'=>'mixed', 'bind_value_type='=>'string'],
'cubrid_lob2_close' => ['bool', 'lob_identifier'=>'resource'],
'cubrid_lob2_export' => ['bool', 'lob_identifier'=>'resource', 'file_name'=>'string'],
'cubrid_lob2_import' => ['bool', 'lob_identifier'=>'resource', 'file_name'=>'string'],
'cubrid_lob2_new' => ['resource', 'conn_identifier='=>'resource', 'type='=>'string'],
'cubrid_lob2_read' => ['string', 'lob_identifier'=>'resource', 'len'=>'int'],
'cubrid_lob2_seek' => ['bool', 'lob_identifier'=>'resource', 'offset'=>'int', 'origin='=>'int'],
'cubrid_lob2_seek64' => ['bool', 'lob_identifier'=>'resource', 'offset'=>'string', 'origin='=>'int'],
'cubrid_lob2_size' => ['int', 'lob_identifier'=>'resource'],
'cubrid_lob2_size64' => ['string', 'lob_identifier'=>'resource'],
'cubrid_lob2_tell' => ['int', 'lob_identifier'=>'resource'],
'cubrid_lob2_tell64' => ['string', 'lob_identifier'=>'resource'],
'cubrid_lob2_write' => ['bool', 'lob_identifier'=>'resource', 'buf'=>'string'],
'cubrid_lob_close' => ['bool', 'lob_identifier_array'=>'array'],
'cubrid_lob_export' => ['bool', 'conn_identifier'=>'resource', 'lob_identifier'=>'resource', 'path_name'=>'string'],
'cubrid_lob_get' => ['array', 'conn_identifier'=>'resource', 'sql'=>'string'],
'cubrid_lob_send' => ['bool', 'conn_identifier'=>'resource', 'lob_identifier'=>'resource'],
'cubrid_lob_size' => ['string', 'lob_identifier'=>'resource'],
'cubrid_lock_read' => ['bool', 'conn_identifier'=>'resource', 'oid'=>'string'],
'cubrid_lock_write' => ['bool', 'conn_identifier'=>'resource', 'oid'=>'string'],
'cubrid_move_cursor' => ['int', 'req_identifier'=>'resource', 'offset'=>'int', 'origin='=>'int'],
'cubrid_new_glo' => ['string', 'conn_identifier'=>'', 'class_name'=>'string', 'file_name'=>'string'],
'cubrid_next_result' => ['bool', 'result'=>'resource'],
'cubrid_num_cols' => ['int', 'req_identifier'=>'resource'],
'cubrid_num_fields' => ['int', 'result'=>''],
'cubrid_num_rows' => ['int', 'req_identifier'=>'resource'],
'cubrid_pconnect' => ['resource', 'host'=>'string', 'port'=>'int', 'dbname'=>'string', 'userid='=>'string', 'passwd='=>'string'],
'cubrid_pconnect_with_url' => ['resource', 'conn_url'=>'string', 'userid='=>'string', 'passwd='=>'string'],
'cubrid_ping' => ['bool', 'conn_identifier='=>''],
'cubrid_prepare' => ['resource', 'conn_identifier'=>'resource', 'prepare_stmt'=>'string', 'option='=>'int'],
'cubrid_put' => ['int', 'conn_identifier'=>'resource', 'oid'=>'string', 'attr='=>'string', 'value='=>'mixed'],
'cubrid_query' => ['resource', 'query'=>'string', 'conn_identifier='=>''],
'cubrid_real_escape_string' => ['string', 'unescaped_string'=>'string', 'conn_identifier='=>''],
'cubrid_result' => ['string', 'result'=>'', 'row'=>'int', 'field='=>''],
'cubrid_rollback' => ['bool', 'conn_identifier'=>'resource'],
'cubrid_save_to_glo' => ['int', 'conn_identifier'=>'', 'oid'=>'string', 'file_name'=>'string'],
'cubrid_schema' => ['array', 'conn_identifier'=>'resource', 'schema_type'=>'int', 'class_name='=>'string', 'attr_name='=>'string'],
'cubrid_send_glo' => ['int', 'conn_identifier'=>'', 'oid'=>'string'],
'cubrid_seq_drop' => ['bool', 'conn_identifier'=>'resource', 'oid'=>'string', 'attr_name'=>'string', 'index'=>'int'],
'cubrid_seq_insert' => ['bool', 'conn_identifier'=>'resource', 'oid'=>'string', 'attr_name'=>'string', 'index'=>'int', 'seq_element'=>'string'],
'cubrid_seq_put' => ['bool', 'conn_identifier'=>'resource', 'oid'=>'string', 'attr_name'=>'string', 'index'=>'int', 'seq_element'=>'string'],
'cubrid_set_add' => ['bool', 'conn_identifier'=>'resource', 'oid'=>'string', 'attr_name'=>'string', 'set_element'=>'string'],
'cubrid_set_autocommit' => ['bool', 'conn_identifier'=>'resource', 'mode'=>'bool'],
'cubrid_set_db_parameter' => ['bool', 'conn_identifier'=>'resource', 'param_type'=>'int', 'param_value'=>'int'],
'cubrid_set_drop' => ['bool', 'conn_identifier'=>'resource', 'oid'=>'string', 'attr_name'=>'string', 'set_element'=>'string'],
'cubrid_set_query_timeout' => ['bool', 'req_identifier'=>'resource', 'timeout'=>'int'],
'cubrid_unbuffered_query' => ['resource', 'query'=>'string', 'conn_identifier='=>''],
'cubrid_version' => ['string'],
'curl_close' => ['void', 'ch'=>'resource'],
'curl_copy_handle' => ['resource', 'ch'=>'resource'],
'curl_errno' => ['int', 'ch'=>'resource'],
'curl_error' => ['string', 'ch'=>'resource'],
'curl_escape' => ['string', 'ch'=>'resource', 'str'=>'string'],
'curl_exec' => ['bool|string', 'ch'=>'resource'],
'curl_file_create' => ['CURLFile', 'filename'=>'string', 'mimetype='=>'string', 'postfilename='=>'string'],
'curl_getinfo' => ['mixed', 'ch'=>'resource', 'option='=>'int'],
'curl_init' => ['resource|false', 'url='=>'string'],
'curl_multi_add_handle' => ['int', 'mh'=>'resource', 'ch'=>'resource'],
'curl_multi_close' => ['void', 'mh'=>'resource'],
'curl_multi_errno' => ['int', 'mh'=>'resource'],
'curl_multi_exec' => ['int', 'mh'=>'resource', '&w_still_running'=>'int'],
'curl_multi_getcontent' => ['string', 'ch'=>'resource'],
'curl_multi_info_read' => ['array|false', 'mh'=>'resource', 'msgs_in_queue='=>'int'],
'curl_multi_init' => ['resource|false'],
'curl_multi_remove_handle' => ['int', 'mh'=>'resource', 'ch'=>'resource'],
'curl_multi_select' => ['int', 'mh'=>'resource', 'timeout='=>'float'],
'curl_multi_setopt' => ['bool', 'mh'=>'resource', 'option'=>'int', 'value'=>'mixed'],
'curl_multi_strerror' => ['string', 'code'=>'int'],
'curl_pause' => ['int', 'ch'=>'resource', 'bitmask'=>'int'],
'curl_reset' => ['void', 'ch'=>'resource'],
'curl_setopt' => ['bool', 'ch'=>'resource', 'option'=>'int', 'value'=>'mixed'],
'curl_setopt_array' => ['bool', 'ch'=>'resource', 'options'=>'array'],
'curl_share_close' => ['void', 'sh'=>'resource'],
'curl_share_errno' => ['int', 'sh'=>'resource'],
'curl_share_init' => ['resource'],
'curl_share_setopt' => ['bool', 'sh'=>'resource', 'option'=>'int', 'value'=>'string'],
'curl_share_strerror' => ['string', 'code'=>'int'],
'curl_strerror' => ['string', 'code'=>'int'],
'curl_unescape' => ['string', 'ch'=>'resource', 'str'=>'string'],
'curl_version' => ['array', 'version='=>'int'],
'CURLFile::__construct' => ['void', 'filename'=>'string', 'mimetype='=>'string', 'postfilename='=>'string'],
'CURLFile::__wakeup' => ['void'],
'CURLFile::getFilename' => ['string'],
'CURLFile::getMimeType' => ['string'],
'CURLFile::getPostFilename' => ['string'],
'CURLFile::setMimeType' => ['void', 'mime'=>'string'],
'CURLFile::setPostFilename' => ['void', 'name'=>'string'],
'current' => ['mixed', 'array_arg'=>'array|object'],
'cyrus_authenticate' => ['void', 'connection'=>'resource', 'mechlist='=>'string', 'service='=>'string', 'user='=>'string', 'minssf='=>'int', 'maxssf='=>'int', 'authname='=>'string', 'password='=>'string'],
'cyrus_bind' => ['bool', 'connection'=>'resource', 'callbacks'=>'array'],
'cyrus_close' => ['bool', 'connection'=>'resource'],
'cyrus_connect' => ['resource', 'host='=>'string', 'port='=>'string', 'flags='=>'int'],
'cyrus_query' => ['array', 'connection'=>'resource', 'query'=>'string'],
'cyrus_unbind' => ['bool', 'connection'=>'resource', 'trigger_name'=>'string'],
'date' => ['string', 'format'=>'string', 'timestamp='=>'int'],
'date_add' => ['DateTime|false', 'object'=>'', 'interval'=>''],
'date_create' => ['DateTime|false', 'time='=>'string|null', 'timezone='=>'?\DateTimeZone'],
'date_create_from_format' => ['DateTime|false', 'format'=>'string', 'time'=>'string', 'timezone='=>'DateTimeZone'],
'date_create_immutable' => ['DateTimeImmutable|false', 'time='=>'string', 'timezone='=>'?\DateTimeZone'],
'date_create_immutable_from_format' => ['DateTimeImmutable', 'format'=>'string', 'time'=>'string', 'timezone='=>'?\DateTimeZone'],
'date_date_set' => ['DateTime|false', 'object'=>'', 'year'=>'', 'month'=>'', 'day'=>''],
'date_default_timezone_get' => ['string'],
'date_default_timezone_set' => ['bool', 'timezone_identifier'=>'string'],
'date_diff' => ['DateInterval', 'obj1'=>'DateTimeInterface', 'obj2'=>'DateTimeInterface', 'absolute='=>'bool'],
'date_format' => ['string', 'obj'=>'DateTimeInterface', 'format'=>'string'],
'date_get_last_errors' => ['array'],
'date_interval_create_from_date_string' => ['DateInterval', 'time'=>''],
'date_interval_format' => ['DateInterval', 'object'=>'', 'format'=>''],
'date_isodate_set' => ['DateTime|false', 'object'=>'DateTime', 'year'=>'int', 'week'=>'int', 'day='=>'int|mixed'],
'date_modify' => ['DateTime|false', 'object'=>'DateTime', 'modify'=>'string'],
'date_offset_get' => ['int', 'obj'=>'DateTimeInterface'],
'date_parse' => ['array', 'date'=>'string'],
'date_parse_from_format' => ['array', 'format'=>'string', 'date'=>'string'],
'date_sub' => ['DateTime|false', 'object'=>'DateTime', 'interval'=>'DateInterval'],
'date_sun_info' => ['array', 'time'=>'int', 'latitude'=>'float', 'longitude'=>'float'],
'date_sunrise' => ['mixed', 'time'=>'int', 'format='=>'int', 'latitude='=>'float', 'longitude='=>'float', 'zenith='=>'float', 'gmt_offset='=>'float'],
'date_sunset' => ['mixed', 'time'=>'int', 'format='=>'int', 'latitude='=>'float', 'longitude='=>'float', 'zenith='=>'float', 'gmt_offset='=>'float'],
'date_time_set' => ['DateTime|false', 'object'=>'', 'hour'=>'', 'minute'=>'', 'second'=>'', 'microseconds'=>''],
'date_timestamp_get' => ['int', 'obj'=>'DateTimeInterface'],
'date_timestamp_set' => ['DateTime|false', 'object'=>'DateTime', 'unixtimestamp'=>'int'],
'date_timezone_get' => ['DateTimeZone', 'obj'=>'DateTimeInterface'],
'date_timezone_set' => ['DateTime|false', 'object'=>'DateTime', 'timezone'=>'DateTimeZone'],
'datefmt_create' => ['IntlDateFormatter', 'locale'=>'string', 'datetype'=>'int', 'timetype'=>'int', 'timezone='=>'int', 'calendar='=>'int|IntlCalendar', 'pattern='=>'string'],
'datefmt_format' => ['string', 'fmt'=>'IntlDateFormatter', 'value'=>'DateTime|IntlCalendar|array|int'],
'datefmt_format_object' => ['string', 'object'=>'object', 'format='=>'mixed', 'locale='=>'string'],
'datefmt_get_calendar' => ['int', 'fmt'=>'IntlDateFormatter'],
'datefmt_get_calendar_object' => ['IntlCalendar', 'fmt'=>'IntlDateFormatter'],
'datefmt_get_datetype' => ['int', 'fmt'=>'IntlDateFormatter'],
'datefmt_get_error_code' => ['int', 'fmt'=>'IntlDateFormatter'],
'datefmt_get_error_message' => ['string', 'fmt'=>'IntlDateFormatter'],
'datefmt_get_locale' => ['string', 'fmt'=>'IntlDateFormatter', 'which='=>'int'],
'datefmt_get_pattern' => ['string', 'fmt'=>'IntlDateFormatter'],
'datefmt_get_timetype' => ['int', 'fmt'=>'IntlDateFormatter'],
'datefmt_get_timezone' => ['IntlTimeZone'],
'datefmt_get_timezone_id' => ['string', 'fmt'=>'IntlDateFormatter'],
'datefmt_is_lenient' => ['bool', 'fmt'=>'IntlDateFormatter'],
'datefmt_localtime' => ['array|bool', 'fmt'=>'IntlDateFormatter', 'text_to_parse='=>'string', '&rw_parse_pos='=>'int'],
'datefmt_parse' => ['int|false', 'fmt'=>'IntlDateFormatter', 'text_to_parse='=>'string', '&rw_parse_pos='=>'int'],
'datefmt_set_calendar' => ['bool', 'fmt'=>'IntlDateFormatter', 'which'=>'int'],
'datefmt_set_lenient' => ['?bool', 'fmt'=>'IntlDateFormatter', 'lenient'=>'bool'],
'datefmt_set_pattern' => ['bool', 'fmt'=>'IntlDateFormatter', 'pattern'=>'string'],
'datefmt_set_timezone' => ['bool', 'zone'=>'mixed'],
'datefmt_set_timezone_id' => ['bool', 'fmt'=>'IntlDateFormatter', 'zone'=>'string'],
'DateInterval::__construct' => ['void', 'spec'=>'string'],
'DateInterval::__set_state' => ['DateInterval', 'array'=>'array'],
'DateInterval::__wakeup' => ['void'],
'DateInterval::createFromDateString' => ['DateInterval', 'time'=>'string'],
'DateInterval::format' => ['string', 'format'=>'string'],
'DatePeriod::__construct' => ['void', 'start'=>'DateTimeInterface', 'interval'=>'DateInterval', 'recur'=>'int', 'options='=>'int'],
'DatePeriod::__construct\'1' => ['void', 'start'=>'DateTimeInterface', 'interval'=>'DateInterval', 'end'=>'DateTimeInterface', 'options='=>'int'],
'DatePeriod::__construct\'2' => ['void', 'iso'=>'string', 'options='=>'int'],
'DatePeriod::__wakeup' => ['void'],
'DatePeriod::getDateInterval' => ['DateInterval'],
'DatePeriod::getEndDate' => ['DateTimeInterface'],
'DatePeriod::getStartDate' => ['DateTimeInterface'],
'DateTime::__construct' => ['void', 'time='=>'string|null', 'timezone='=>'?DateTimeZone'],
'DateTime::__set_state' => ['static', 'array'=>'array'],
'DateTime::__wakeup' => ['void'],
'DateTime::add' => ['static', 'interval'=>'DateInterval'],
'DateTime::createFromFormat' => ['static|false', 'format'=>'string', 'time'=>'string', 'timezone='=>'DateTimeZone|null'],
'DateTime::diff' => ['DateInterval', 'datetime2'=>'DateTimeInterface', 'absolute='=>'bool'],
'DateTime::format' => ['string', 'format'=>'string'],
'DateTime::getLastErrors' => ['array'],
'DateTime::getOffset' => ['int'],
'DateTime::getTimestamp' => ['int'],
'DateTime::getTimezone' => ['DateTimeZone'],
'DateTime::modify' => ['static', 'modify'=>'string'],
'DateTime::setDate' => ['static', 'year'=>'int', 'month'=>'int', 'day'=>'int'],
'DateTime::setISODate' => ['static', 'year'=>'int', 'week'=>'int', 'day='=>'int'],
'DateTime::setTime' => ['static', 'hour'=>'int', 'minute'=>'int', 'second='=>'int', 'microseconds='=>'int'],
'DateTime::setTimestamp' => ['static', 'unixtimestamp'=>'int'],
'DateTime::setTimezone' => ['static', 'timezone'=>'DateTimeZone'],
'DateTime::sub' => ['static', 'interval'=>'DateInterval'],
'DateTimeImmutable::__construct' => ['void', 'time='=>'string|null', 'timezone='=>'?DateTimeZone'],
'DateTimeImmutable::__set_state' => ['static', 'array'=>'array'],
'DateTimeImmutable::__wakeup' => ['void'],
'DateTimeImmutable::add' => ['static', 'interval'=>'DateInterval'],
'DateTimeImmutable::createFromFormat' => ['static|false', 'format'=>'string', 'time'=>'string', 'timezone='=>'DateTimeZone|null'],
'DateTimeImmutable::createFromMutable' => ['static', 'datetime'=>'DateTime'],
'DateTimeImmutable::diff' => ['DateInterval', 'datetime2'=>'DateTimeInterface', 'absolute='=>'bool'],
'DateTimeImmutable::format' => ['string', 'format'=>'string'],
'DateTimeImmutable::getLastErrors' => ['array'],
'DateTimeImmutable::getOffset' => ['int'],
'DateTimeImmutable::getTimestamp' => ['int'],
'DateTimeImmutable::getTimezone' => ['DateTimeZone'],
'DateTimeImmutable::modify' => ['static', 'modify'=>'string'],
'DateTimeImmutable::setDate' => ['static', 'year'=>'int', 'month'=>'int', 'day'=>'int'],
'DateTimeImmutable::setISODate' => ['static', 'year'=>'int', 'week'=>'int', 'day='=>'int'],
'DateTimeImmutable::setTime' => ['static', 'hour'=>'int', 'minute'=>'int', 'second='=>'int', 'microseconds='=>'int'],
'DateTimeImmutable::setTimestamp' => ['static', 'unixtimestamp'=>'int'],
'DateTimeImmutable::setTimezone' => ['static', 'timezone'=>'DateTimeZone'],
'DateTimeImmutable::sub' => ['static', 'interval'=>'DateInterval'],
'DateTimeInterface::diff' => ['DateInterval', 'datetime2'=>'DateTimeInterface', 'absolute='=>'bool'],
'DateTimeInterface::format' => ['string', 'format'=>'string'],
'DateTimeInterface::getOffset' => ['int'],
'DateTimeInterface::getTimestamp' => ['int'],
'DateTimeInterface::getTimezone' => ['DateTimeZone'],
'DateTimeZone::__construct' => ['void', 'timezone'=>'string'],
'DateTimeZone::__set_state' => ['DateTimeZone', 'array'=>'array'],
'DateTimeZone::__wakeup' => ['void'],
'DateTimeZone::getLocation' => ['array'],
'DateTimeZone::getName' => ['string'],
'DateTimeZone::getOffset' => ['int', 'datetime'=>'DateTimeInterface'],
'DateTimeZone::getTransitions' => ['array', 'timestamp_begin='=>'int', 'timestamp_end='=>'int'],
'DateTimeZone::listAbbreviations' => ['array'],
'DateTimeZone::listIdentifiers' => ['array', 'what='=>'int', 'country='=>'string'],
'db2_autocommit' => ['mixed', 'connection'=>'resource', 'value='=>'bool'],
'db2_bind_param' => ['bool', 'stmt'=>'resource', 'parameter_number'=>'int', 'variable_name'=>'string', 'parameter_type='=>'int', 'data_type='=>'int', 'precision='=>'int', 'scale='=>'int'],
'db2_client_info' => ['object', 'connection'=>'resource'],
'db2_close' => ['bool', 'connection'=>'resource'],
'db2_column_privileges' => ['resource', 'connection'=>'resource', 'qualifier='=>'string', 'schema='=>'string', 'table_name='=>'string', 'column_name='=>'string'],
'db2_columns' => ['resource', 'connection'=>'resource', 'qualifier='=>'string', 'schema='=>'string', 'table_name='=>'string', 'column_name='=>'string'],
'db2_commit' => ['bool', 'connection'=>'resource'],
'db2_conn_error' => ['string', 'connection='=>'resource'],
'db2_conn_errormsg' => ['string', 'connection='=>'resource'],
'db2_connect' => ['resource', 'database'=>'string', 'username'=>'string', 'password'=>'string', 'options='=>'array'],
'db2_cursor_type' => ['int', 'stmt'=>'resource'],
'db2_escape_string' => ['string', 'string_literal'=>'string'],
'db2_exec' => ['resource', 'connection'=>'resource', 'statement'=>'string', 'options='=>'array'],
'db2_execute' => ['bool', 'stmt'=>'resource', 'parameters='=>'array'],
'db2_fetch_array' => ['array', 'stmt'=>'resource', 'row_number='=>'int'],
'db2_fetch_assoc' => ['array', 'stmt'=>'resource', 'row_number='=>'int'],
'db2_fetch_both' => ['array', 'stmt'=>'resource', 'row_number='=>'int'],
'db2_fetch_object' => ['object', 'stmt'=>'resource', 'row_number='=>'int'],
'db2_fetch_row' => ['bool', 'stmt'=>'resource', 'row_number='=>'int'],
'db2_field_display_size' => ['int', 'stmt'=>'resource', 'column'=>'mixed'],
'db2_field_name' => ['string', 'stmt'=>'resource', 'column'=>'mixed'],
'db2_field_num' => ['int', 'stmt'=>'resource', 'column'=>'mixed'],
'db2_field_precision' => ['int', 'stmt'=>'resource', 'column'=>'mixed'],
'db2_field_scale' => ['int', 'stmt'=>'resource', 'column'=>'mixed'],
'db2_field_type' => ['string', 'stmt'=>'resource', 'column'=>'mixed'],
'db2_field_width' => ['int', 'stmt'=>'resource', 'column'=>'mixed'],
'db2_foreign_keys' => ['resource', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'table_name'=>'string'],
'db2_free_result' => ['bool', 'stmt'=>'resource'],
'db2_free_stmt' => ['bool', 'stmt'=>'resource'],
'db2_get_option' => ['string', 'resource'=>'resource', 'option'=>'string'],
'db2_last_insert_id' => ['string', 'resource'=>'resource'],
'db2_lob_read' => ['string', 'stmt'=>'resource', 'colnum'=>'int', 'length'=>'int'],
'db2_next_result' => ['resource', 'stmt'=>'resource'],
'db2_num_fields' => ['int', 'stmt'=>'resource'],
'db2_num_rows' => ['bool', 'stmt'=>'resource'],
'db2_pclose' => ['bool', 'resource'=>'resource'],
'db2_pconnect' => ['resource', 'database'=>'string', 'username'=>'string', 'password'=>'string', 'options='=>'array'],
'db2_prepare' => ['resource', 'connection'=>'resource', 'statement'=>'string', 'options='=>'array'],
'db2_primary_keys' => ['resource', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'table_name'=>'string'],
'db2_primarykeys' => [''],
'db2_procedure_columns' => ['resource', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'procedure'=>'string', 'parameter'=>'string'],
'db2_procedurecolumns' => [''],
'db2_procedures' => ['resource', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'procedure'=>'string'],
'db2_result' => ['mixed', 'stmt'=>'resource', 'column'=>'mixed'],
'db2_rollback' => ['bool', 'connection'=>'resource'],
'db2_server_info' => ['object', 'connection'=>'resource'],
'db2_set_option' => ['bool', 'resource'=>'resource', 'options'=>'array', 'type'=>'int'],
'db2_setoption' => [''],
'db2_special_columns' => ['resource', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'table_name'=>'string', 'scope'=>'int'],
'db2_specialcolumns' => [''],
'db2_statistics' => ['resource', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'table_name'=>'string', 'unique'=>'bool'],
'db2_stmt_error' => ['string', 'stmt='=>'resource'],
'db2_stmt_errormsg' => ['string', 'stmt='=>'resource'],
'db2_table_privileges' => ['resource', 'connection'=>'resource', 'qualifier='=>'string', 'schema='=>'string', 'table_name='=>'string'],
'db2_tableprivileges' => [''],
'db2_tables' => ['resource', 'connection'=>'resource', 'qualifier='=>'string', 'schema='=>'string', 'table_name='=>'string', 'table_type='=>'string'],
'dba_close' => ['void', 'handle'=>'resource'],
'dba_delete' => ['bool', 'key'=>'string', 'handle'=>'resource'],
'dba_exists' => ['bool', 'key'=>'string', 'handle'=>'resource'],
'dba_fetch' => ['string', 'key'=>'string', 'skip'=>'int', 'handle'=>'resource'],
'dba_fetch\'1' => ['string', 'key'=>'string', 'handle'=>'resource'],
'dba_firstkey' => ['string', 'handle'=>'resource'],
'dba_handlers' => ['array', 'full_info='=>'bool'],
'dba_insert' => ['bool', 'key'=>'string', 'value'=>'string', 'handle'=>'resource'],
'dba_key_split' => ['array|false', 'key'=>'string'],
'dba_list' => ['array'],
'dba_nextkey' => ['string', 'handle'=>'resource'],
'dba_open' => ['resource', 'path'=>'string', 'mode'=>'string', 'handlername='=>'string', '...args='=>'string'],
'dba_optimize' => ['bool', 'handle'=>'resource'],
'dba_popen' => ['resource', 'path'=>'string', 'mode'=>'string', 'handlername='=>'string', '...args='=>'string'],
'dba_replace' => ['bool', 'key'=>'string', 'value'=>'string', 'handle'=>'resource'],
'dba_sync' => ['bool', 'handle'=>'resource'],
'dbase_add_record' => ['bool', 'dbase_identifier'=>'int', 'record'=>'array'],
'dbase_close' => ['bool', 'dbase_identifier'=>'int'],
'dbase_create' => ['int', 'filename'=>'string', 'fields'=>'array'],
'dbase_delete_record' => ['bool', 'dbase_identifier'=>'int', 'record_number'=>'int'],
'dbase_get_header_info' => ['array', 'dbase_identifier'=>'int'],
'dbase_get_record' => ['array', 'dbase_identifier'=>'int', 'record_number'=>'int'],
'dbase_get_record_with_names' => ['array', 'dbase_identifier'=>'int', 'record_number'=>'int'],
'dbase_numfields' => ['int', 'dbase_identifier'=>'int'],
'dbase_numrecords' => ['int', 'dbase_identifier'=>'int'],
'dbase_open' => ['int', 'filename'=>'string', 'mode'=>'int'],
'dbase_pack' => ['bool', 'dbase_identifier'=>'int'],
'dbase_replace_record' => ['bool', 'dbase_identifier'=>'int', 'record'=>'array', 'record_number'=>'int'],
'dbplus_add' => ['int', 'relation'=>'resource', 'tuple'=>'array'],
'dbplus_aql' => ['resource', 'query'=>'string', 'server='=>'string', 'dbpath='=>'string'],
'dbplus_chdir' => ['string', 'newdir='=>'string'],
'dbplus_close' => ['mixed', 'relation'=>'resource'],
'dbplus_curr' => ['int', 'relation'=>'resource', 'tuple'=>'array'],
'dbplus_errcode' => ['string', 'errno='=>'int'],
'dbplus_errno' => ['int'],
'dbplus_find' => ['int', 'relation'=>'resource', 'constraints'=>'array', 'tuple'=>'mixed'],
'dbplus_first' => ['int', 'relation'=>'resource', 'tuple'=>'array'],
'dbplus_flush' => ['int', 'relation'=>'resource'],
'dbplus_freealllocks' => ['int'],
'dbplus_freelock' => ['int', 'relation'=>'resource', 'tuple'=>'string'],
'dbplus_freerlocks' => ['int', 'relation'=>'resource'],
'dbplus_getlock' => ['int', 'relation'=>'resource', 'tuple'=>'string'],
'dbplus_getunique' => ['int', 'relation'=>'resource', 'uniqueid'=>'int'],
'dbplus_info' => ['int', 'relation'=>'resource', 'key'=>'string', 'result'=>'array'],
'dbplus_last' => ['int', 'relation'=>'resource', 'tuple'=>'array'],
'dbplus_lockrel' => ['int', 'relation'=>'resource'],
'dbplus_next' => ['int', 'relation'=>'resource', 'tuple'=>'array'],
'dbplus_open' => ['resource', 'name'=>'string'],
'dbplus_prev' => ['int', 'relation'=>'resource', 'tuple'=>'array'],
'dbplus_rchperm' => ['int', 'relation'=>'resource', 'mask'=>'int', 'user'=>'string', 'group'=>'string'],
'dbplus_rcreate' => ['resource', 'name'=>'string', 'domlist'=>'mixed', 'overwrite='=>'bool'],
'dbplus_rcrtexact' => ['mixed', 'name'=>'string', 'relation'=>'resource', 'overwrite='=>'bool'],
'dbplus_rcrtlike' => ['mixed', 'name'=>'string', 'relation'=>'resource', 'overwrite='=>'int'],
'dbplus_resolve' => ['array', 'relation_name'=>'string'],
'dbplus_restorepos' => ['int', 'relation'=>'resource', 'tuple'=>'array'],
'dbplus_rkeys' => ['mixed', 'relation'=>'resource', 'domlist'=>'mixed'],
'dbplus_ropen' => ['resource', 'name'=>'string'],
'dbplus_rquery' => ['resource', 'query'=>'string', 'dbpath='=>'string'],
'dbplus_rrename' => ['int', 'relation'=>'resource', 'name'=>'string'],
'dbplus_rsecindex' => ['mixed', 'relation'=>'resource', 'domlist'=>'mixed', 'type'=>'int'],
'dbplus_runlink' => ['int', 'relation'=>'resource'],
'dbplus_rzap' => ['int', 'relation'=>'resource'],
'dbplus_savepos' => ['int', 'relation'=>'resource'],
'dbplus_setindex' => ['int', 'relation'=>'resource', 'idx_name'=>'string'],
'dbplus_setindexbynumber' => ['int', 'relation'=>'resource', 'idx_number'=>'int'],
'dbplus_sql' => ['resource', 'query'=>'string', 'server='=>'string', 'dbpath='=>'string'],
'dbplus_tcl' => ['string', 'sid'=>'int', 'script'=>'string'],
'dbplus_tremove' => ['int', 'relation'=>'resource', 'tuple'=>'array', 'current='=>'array'],
'dbplus_undo' => ['int', 'relation'=>'resource'],
'dbplus_undoprepare' => ['int', 'relation'=>'resource'],
'dbplus_unlockrel' => ['int', 'relation'=>'resource'],
'dbplus_unselect' => ['int', 'relation'=>'resource'],
'dbplus_update' => ['int', 'relation'=>'resource', 'old'=>'array', 'new'=>'array'],
'dbplus_xlockrel' => ['int', 'relation'=>'resource'],
'dbplus_xunlockrel' => ['int', 'relation'=>'resource'],
'dbx_close' => ['int', 'link_identifier'=>'object'],
'dbx_compare' => ['int', 'row_a'=>'array', 'row_b'=>'array', 'column_key'=>'string', 'flags='=>'int'],
'dbx_connect' => ['object', 'module'=>'mixed', 'host'=>'string', 'database'=>'string', 'username'=>'string', 'password'=>'string', 'persistent='=>'int'],
'dbx_error' => ['string', 'link_identifier'=>'object'],
'dbx_escape_string' => ['string', 'link_identifier'=>'object', 'text'=>'string'],
'dbx_fetch_row' => ['mixed', 'result_identifier'=>'object'],
'dbx_query' => ['mixed', 'link_identifier'=>'object', 'sql_statement'=>'string', 'flags='=>'int'],
'dbx_sort' => ['bool', 'result'=>'object', 'user_compare_function'=>'string'],
'dcgettext' => ['string', 'domain_name'=>'string', 'msgid'=>'string', 'category'=>'int'],
'dcngettext' => ['string', 'domain'=>'string', 'msgid1'=>'string', 'msgid2'=>'string', 'n'=>'int', 'category'=>'int'],
'deaggregate' => ['', 'object'=>'object', 'class_name='=>'string'],
'debug_backtrace' => ['array', 'options='=>'int|bool', 'limit='=>'int'],
'debug_print_backtrace' => ['void', 'options='=>'int|bool', 'limit='=>'int'],
'debug_zval_dump' => ['void', '...var'=>'mixed'],
'debugger_connect' => [''],
'debugger_connector_pid' => [''],
'debugger_get_server_start_time' => [''],
'debugger_print' => [''],
'debugger_start_debug' => [''],
'decbin' => ['string', 'decimal_number'=>'int'],
'dechex' => ['string', 'decimal_number'=>'int'],
'decoct' => ['string', 'decimal_number'=>'int'],
'define' => ['bool', 'constant_name'=>'string', 'value'=>'mixed', 'case_insensitive='=>'bool'],
'define_syslog_variables' => ['void'],
'defined' => ['bool', 'name'=>'string'],
'deflate_add' => ['string|false', 'context'=>'resource', 'data'=>'string', 'flush_mode='=>'int'],
'deflate_init' => ['resource|false', 'encoding'=>'int', 'options='=>'array'],
'deg2rad' => ['float', 'number'=>'float'],
'dgettext' => ['string', 'domain_name'=>'string', 'msgid'=>'string'],
'dio_close' => ['void', 'fd'=>'resource'],
'dio_fcntl' => ['mixed', 'fd'=>'resource', 'cmd'=>'int', 'args='=>'mixed'],
'dio_open' => ['resource', 'filename'=>'string', 'flags'=>'int', 'mode='=>'int'],
'dio_read' => ['string', 'fd'=>'resource', 'len='=>'int'],
'dio_seek' => ['int', 'fd'=>'resource', 'pos'=>'int', 'whence='=>'int'],
'dio_stat' => ['array|null', 'fd'=>'resource'],
'dio_tcsetattr' => ['bool', 'fd'=>'resource', 'options'=>'array'],
'dio_truncate' => ['bool', 'fd'=>'resource', 'offset'=>'int'],
'dio_write' => ['int', 'fd'=>'resource', 'data'=>'string', 'len='=>'int'],
'dir' => ['Directory|false', 'directory'=>'string', 'context='=>'resource'],
'Directory::close' => ['void', 'dir_handle='=>'resource'],
'Directory::read' => ['string|false', 'dir_handle='=>'resource'],
'Directory::rewind' => ['void', 'dir_handle='=>'resource'],
'DirectoryIterator::__construct' => ['void', 'path'=>'string'],
'DirectoryIterator::__toString' => ['string'],
'DirectoryIterator::current' => ['DirectoryIterator'],
'DirectoryIterator::getATime' => ['int'],
'DirectoryIterator::getBasename' => ['string', 'suffix='=>'string'],
'DirectoryIterator::getChildren' => ['RecursiveDirectoryIterator'],
'DirectoryIterator::getCTime' => ['int'],
'DirectoryIterator::getExtension' => ['string'],
'DirectoryIterator::getFileInfo' => ['SplFileInfo', 'class_name='=>'string'],
'DirectoryIterator::getFilename' => ['string'],
'DirectoryIterator::getGroup' => ['int'],
'DirectoryIterator::getInode' => ['int'],
'DirectoryIterator::getLinkTarget' => ['string'],
'DirectoryIterator::getMTime' => ['int'],
'DirectoryIterator::getOwner' => ['int'],
'DirectoryIterator::getPath' => ['string'],
'DirectoryIterator::getPathInfo' => ['SplFileInfo', 'class_name='=>'string'],
'DirectoryIterator::getPathname' => ['string'],
'DirectoryIterator::getPerms' => ['int'],
'DirectoryIterator::getRealPath' => ['string'],
'DirectoryIterator::getSize' => ['int'],
'DirectoryIterator::getType' => ['string'],
'DirectoryIterator::isDir' => ['bool'],
'DirectoryIterator::isDot' => ['bool'],
'DirectoryIterator::isExecutable' => ['bool'],
'DirectoryIterator::isFile' => ['bool'],
'DirectoryIterator::isLink' => ['bool'],
'DirectoryIterator::isReadable' => ['bool'],
'DirectoryIterator::isWritable' => ['bool'],
'DirectoryIterator::key' => ['string'],
'DirectoryIterator::next' => ['void'],
'DirectoryIterator::openFile' => ['SplFileObject', 'mode='=>'string', 'use_include_path='=>'bool', 'context='=>'resource'],
'DirectoryIterator::rewind' => ['void'],
'DirectoryIterator::seek' => ['void', 'position'=>'int'],
'DirectoryIterator::setFileClass' => ['void', 'class_name='=>'string'],
'DirectoryIterator::setInfoClass' => ['void', 'class_name='=>'string'],
'DirectoryIterator::valid' => ['bool'],
'dirname' => ['string', 'path'=>'string', 'levels='=>'int'],
'disk_free_space' => ['float|false', 'path'=>'string'],
'disk_total_space' => ['float', 'path'=>'string'],
'diskfreespace' => ['', 'path'=>''],
'display_disabled_function' => [''],
'dl' => ['int', 'extension_filename'=>'string'],
'dngettext' => ['string', 'domain'=>'string', 'msgid1'=>'string', 'msgid2'=>'string', 'count'=>'int'],
'dns_check_record' => ['bool', 'host'=>'string', 'type='=>'string'],
'dns_get_mx' => ['bool', 'hostname'=>'string', '&w_mxhosts'=>'array', '&w_weight'=>'array'],
'dns_get_record' => ['array|false', 'hostname'=>'string', 'type='=>'int', '&w_authns='=>'array', '&w_addtl='=>'array', 'raw='=>'bool'],
'dom_document_relaxNG_validate_file' => ['bool', 'filename'=>'string'],
'dom_document_relaxNG_validate_xml' => ['bool', 'source'=>'string'],
'dom_document_schema_validate' => ['bool', 'source'=>'string', 'flags'=>'int'],
'dom_document_schema_validate_file' => ['bool', 'filename'=>'string', 'flags'=>'int'],
'dom_document_xinclude' => ['int', 'options'=>'int'],
'dom_import_simplexml' => ['DOMElement|false', 'node'=>'SimpleXMLElement'],
'dom_xpath_evaluate' => ['', 'expr'=>'string', 'context'=>'DOMNode', 'registernodens'=>'bool'],
'dom_xpath_query' => ['DOMNodeList', 'expr'=>'string', 'context'=>'DOMNode', 'registernodens'=>'bool'],
'dom_xpath_register_ns' => ['bool', 'prefix'=>'string', 'uri'=>'string'],
'dom_xpath_register_php_functions' => [''],
'DomainException::__clone' => ['void'],
'DomainException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?DomainException'],
'DomainException::__toString' => ['string'],
'DomainException::__wakeup' => ['void'],
'DomainException::getCode' => ['int'],
'DomainException::getFile' => ['string'],
'DomainException::getLine' => ['int'],
'DomainException::getMessage' => ['string'],
'DomainException::getPrevious' => ['Throwable|DomainException|null'],
'DomainException::getTrace' => ['array'],
'DomainException::getTraceAsString' => ['string'],
'DOMAttr::__construct' => ['void', 'name'=>'string', 'value='=>'string'],
'DOMAttr::isId' => ['bool'],
'DomAttribute::name' => ['string'],
'DomAttribute::set_value' => ['bool', 'content'=>'string'],
'DomAttribute::specified' => ['bool'],
'DomAttribute::value' => ['string'],
'DOMCdataSection::__construct' => ['void', 'value'=>'string'],
'DOMCharacterData::appendData' => ['void', 'data'=>'string'],
'DOMCharacterData::deleteData' => ['void', 'offset'=>'int', 'count'=>'int'],
'DOMCharacterData::insertData' => ['void', 'offset'=>'int', 'data'=>'string'],
'DOMCharacterData::replaceData' => ['void', 'offset'=>'int', 'count'=>'int', 'data'=>'string'],
'DOMCharacterData::substringData' => ['string', 'offset'=>'int', 'count'=>'int'],
'DOMComment::__construct' => ['void', 'value='=>'string'],
'DOMDocument::__construct' => ['void', 'version='=>'string', 'encoding='=>'string'],
'DOMDocument::createAttribute' => ['DOMAttr', 'name'=>'string'],
'DOMDocument::createAttributeNS' => ['DOMAttr', 'namespaceuri'=>'string', 'qualifiedname'=>'string'],
'DOMDocument::createCDATASection' => ['DOMCDATASection', 'data'=>'string'],
'DOMDocument::createComment' => ['DOMComment', 'data'=>'string'],
'DOMDocument::createDocumentFragment' => ['DOMDocumentFragment'],
'DOMDocument::createElement' => ['DOMElement', 'name'=>'string', 'value='=>'string'],
'DOMDocument::createElementNS' => ['DOMElement', 'namespaceuri'=>'string', 'qualifiedname'=>'string', 'value='=>'string'],
'DOMDocument::createEntityReference' => ['DOMEntityReference', 'name'=>'string'],
'DOMDocument::createProcessingInstruction' => ['DOMProcessingInstruction', 'target'=>'string', 'data='=>'string'],
'DOMDocument::createTextNode' => ['DOMText', 'content'=>'string'],
'DOMDocument::getElementById' => ['DOMElement|null', 'elementid'=>'string'],
'DOMDocument::getElementsByTagName' => ['DOMNodeList', 'name'=>'string'],
'DOMDocument::getElementsByTagNameNS' => ['DOMNodeList', 'namespaceuri'=>'string', 'localname'=>'string'],
'DOMDocument::importNode' => ['DOMNode', 'importednode'=>'DOMNode', 'deep='=>'bool'],
'DOMDocument::load' => ['mixed', 'filename'=>'string', 'options='=>'int'],
'DOMDocument::loadHTML' => ['bool', 'source'=>'string', 'options='=>'int'],
'DOMDocument::loadHTMLFile' => ['bool', 'filename'=>'string', 'options='=>'int'],
'DOMDocument::loadXML' => ['mixed', 'source'=>'string', 'options='=>'int'],
'DOMDocument::normalizeDocument' => ['void'],
'DOMDocument::registerNodeClass' => ['bool', 'baseclass'=>'string', 'extendedclass'=>'string'],
'DOMDocument::relaxNGValidate' => ['bool', 'filename'=>'string'],
'DOMDocument::relaxNGValidateSource' => ['bool', 'source'=>'string'],
'DOMDocument::save' => ['int', 'filename'=>'string', 'options='=>'int'],
'DOMDocument::saveHTML' => ['string', 'node='=>'?DOMNode'],
'DOMDocument::saveHTMLFile' => ['int', 'filename'=>'string'],
'DOMDocument::saveXML' => ['string', 'node='=>'DOMNode', 'options='=>'int'],
'DOMDocument::schemaValidate' => ['bool', 'filename'=>'string', 'flags='=>'int'],
'DOMDocument::schemaValidateSource' => ['bool', 'source'=>'string', 'flags='=>'int'],
'DOMDocument::validate' => ['bool'],
'DOMDocument::xinclude' => ['int', 'options='=>'int'],
'DOMDocumentFragment::__construct' => ['void'],
'DOMDocumentFragment::appendXML' => ['bool', 'data'=>'string'],
'DomDocumentType::entities' => ['array'],
'DomDocumentType::internal_subset' => ['bool'],
'DomDocumentType::name' => ['string'],
'DomDocumentType::notations' => ['array'],
'DomDocumentType::public_id' => ['string'],
'DomDocumentType::system_id' => ['string'],
'DOMElement::__construct' => ['void', 'name'=>'string', 'value='=>'string', 'uri='=>'string'],
'DOMElement::get_attribute' => ['string', 'name'=>'string'],
'DOMElement::get_attribute_node' => ['DomAttribute', 'name'=>'string'],
'DOMElement::get_elements_by_tagname' => ['array', 'name'=>'string'],
'DOMElement::getAttribute' => ['string', 'name'=>'string'],
'DOMElement::getAttributeNode' => ['DOMAttr', 'name'=>'string'],
'DOMElement::getAttributeNodeNS' => ['DOMAttr', 'namespaceuri'=>'string', 'localname'=>'string'],
'DOMElement::getAttributeNS' => ['string', 'namespaceuri'=>'string', 'localname'=>'string'],
'DOMElement::getElementsByTagName' => ['DOMNodeList', 'name'=>'string'],
'DOMElement::getElementsByTagNameNS' => ['DOMNodeList', 'namespaceuri'=>'string', 'localname'=>'string'],
'DOMElement::has_attribute' => ['bool', 'name'=>'string'],
'DOMElement::hasAttribute' => ['bool', 'name'=>'string'],
'DOMElement::hasAttributeNS' => ['bool', 'namespaceuri'=>'string', 'localname'=>'string'],
'DOMElement::remove_attribute' => ['bool', 'name'=>'string'],
'DOMElement::removeAttribute' => ['bool', 'name'=>'string'],
'DOMElement::removeAttributeNode' => ['bool', 'oldnode'=>'DOMAttr'],
'DOMElement::removeAttributeNS' => ['bool', 'namespaceuri'=>'string', 'localname'=>'string'],
'DOMElement::set_attribute' => ['DomAttribute', 'name'=>'string', 'value'=>'string'],
'DOMElement::set_attribute_node' => ['DomNode', 'attr'=>'DOMNode'],
'DOMElement::setAttribute' => ['DOMAttr', 'name'=>'string', 'value'=>'string'],
'DOMElement::setAttributeNode' => ['DOMAttr', 'attr'=>'DOMAttr'],
'DOMElement::setAttributeNodeNS' => ['DOMAttr', 'attr'=>'DOMAttr'],
'DOMElement::setAttributeNS' => ['void', 'namespaceuri'=>'string', 'qualifiedname'=>'string', 'value'=>'string'],
'DOMElement::setIdAttribute' => ['void', 'name'=>'string', 'isid'=>'bool'],
'DOMElement::setIdAttributeNode' => ['void', 'attr'=>'DOMAttr', 'isid'=>'bool'],
'DOMElement::setIdAttributeNS' => ['void', 'namespaceuri'=>'string', 'localname'=>'string', 'isid'=>'bool'],
'DOMElement::tagname' => ['string'],
'DOMEntityReference::__construct' => ['void', 'name'=>'string'],
'DOMImplementation::__construct' => ['void'],
'DOMImplementation::createDocument' => ['DOMDocument', 'namespaceuri='=>'string', 'qualifiedname='=>'string', 'doctype='=>'DOMDocumentType'],
'DOMImplementation::createDocumentType' => ['DOMDocumentType', 'qualifiedname='=>'string', 'publicid='=>'string', 'systemid='=>'string'],
'DOMImplementation::hasFeature' => ['bool', 'feature'=>'string', 'version'=>'string'],
'DOMNamedNodeMap::getNamedItem' => ['?DOMNode', 'name'=>'string'],
'DOMNamedNodeMap::getNamedItemNS' => ['?DOMNode', 'namespaceuri'=>'string', 'localname'=>'string'],
'DOMNamedNodeMap::item' => ['?DOMNode', 'index'=>'int'],
'DomNode::add_namespace' => ['bool', 'uri'=>'string', 'prefix'=>'string'],
'DomNode::append_child' => ['DOMNode', 'newnode'=>'DOMNode'],
'DOMNode::appendChild' => ['DOMNode', 'newnode'=>'DOMNode'],
'DOMNode::C14N' => ['string', 'exclusive='=>'bool', 'with_comments='=>'bool', 'xpath='=>'array', 'ns_prefixes='=>'array'],
'DOMNode::C14NFile' => ['int', 'uri='=>'string', 'exclusive='=>'bool', 'with_comments='=>'bool', 'xpath='=>'array', 'ns_prefixes='=>'array'],
'DOMNode::cloneNode' => ['DOMNode', 'deep='=>'bool'],
'DOMNode::getLineNo' => ['int'],
'DOMNode::getNodePath' => ['?string'],
'DOMNode::hasAttributes' => ['bool'],
'DOMNode::hasChildNodes' => ['bool'],
'DOMNode::insertBefore' => ['DOMNode', 'newnode'=>'DOMNode', 'refnode='=>'DOMNode'],
'DOMNode::isDefaultNamespace' => ['bool', 'namespaceuri'=>'string'],
'DOMNode::isSameNode' => ['bool', 'node'=>'DOMNode'],
'DOMNode::isSupported' => ['bool', 'feature'=>'string', 'version'=>'string'],
'DOMNode::lookupNamespaceURI' => ['string', 'prefix'=>'string'],
'DOMNode::lookupPrefix' => ['string', 'namespaceuri'=>'string'],
'DOMNode::normalize' => ['void'],
'DOMNode::removeChild' => ['DOMNode', 'oldnode'=>'DOMNode'],
'DOMNode::replaceChild' => ['DOMNode', 'newnode'=>'DOMNode', 'oldnode'=>'DOMNode'],
'DOMNodeList::count' => ['int'],
'DOMNodeList::item' => ['?DOMNode', 'index'=>'int'],
'DOMProcessingInstruction::__construct' => ['void', 'name'=>'string', 'value'=>'string'],
'DomProcessingInstruction::data' => ['string'],
'DomProcessingInstruction::target' => ['string'],
'DOMText::__construct' => ['void', 'value='=>'string'],
'DOMText::isElementContentWhitespace' => ['bool'],
'DOMText::isWhitespaceInElementContent' => ['bool'],
'DOMText::splitText' => ['DOMText', 'offset'=>'int'],
'domxml_new_doc' => ['DomDocument', 'version'=>'string'],
'domxml_open_file' => ['DomDocument', 'filename'=>'string', 'mode='=>'int', 'error='=>'array'],
'domxml_open_mem' => ['DomDocument', 'str'=>'string', 'mode='=>'int', 'error='=>'array'],
'domxml_version' => ['string'],
'domxml_xmltree' => ['DomDocument', 'str'=>'string'],
'domxml_xslt_stylesheet' => ['DomXsltStylesheet', 'xsl_buf'=>'string'],
'domxml_xslt_stylesheet_doc' => ['DomXsltStylesheet', 'xsl_doc'=>'DOMDocument'],
'domxml_xslt_stylesheet_file' => ['DomXsltStylesheet', 'xsl_file'=>'string'],
'domxml_xslt_version' => ['int'],
'DOMXPath::__construct' => ['void', 'doc'=>'DOMDocument'],
'DOMXPath::evaluate' => ['mixed', 'expression'=>'string', 'contextnode='=>'DOMNode', 'registernodens='=>'bool'],
'DOMXPath::query' => ['DOMNodeList', 'expression'=>'string', 'contextnode='=>'DOMNode', 'registernodens='=>'bool'],
'DOMXPath::registerNamespace' => ['bool', 'prefix'=>'string', 'namespaceuri'=>'string'],
'DOMXPath::registerPhpFunctions' => ['void', 'restrict='=>'mixed'],
'DomXsltStylesheet::process' => ['DomDocument', 'xml_doc'=>'DOMDocument', 'xslt_params='=>'array', 'is_xpath_param='=>'bool', 'profile_filename='=>'string'],
'DomXsltStylesheet::result_dump_file' => ['string', 'xmldoc'=>'DOMDocument', 'filename'=>'string'],
'DomXsltStylesheet::result_dump_mem' => ['string', 'xmldoc'=>'DOMDocument'],
'DOTNET::__construct' => ['void', 'assembly_name'=>'string', 'class_name'=>'string', 'codepage='=>'int'],
'dotnet_load' => ['int', 'assembly_name'=>'string', 'datatype_name='=>'string', 'codepage='=>'int'],
'doubleval' => ['float', 'var'=>'mixed'],
'Ds\Collection::clear' => ['void'],
'Ds\Collection::copy' => ['Ds\Collection'],
'Ds\Collection::isEmpty' => ['bool'],
'Ds\Collection::toArray' => ['array'],
'Ds\Hashable::hash' => ['void'],
'Ds\Hashable::equals' => ['bool', 'obj'=>'mixed'],
'Ds\Sequence::allocate' => ['void', 'capacity'=>'int'],
'Ds\Sequence::apply' => ['void', 'callback'=>'callable'],
'Ds\Sequence::capacity' => ['int'],
'Ds\Sequence::contains' => ['bool', '...values='=>'mixed'],
'Ds\Sequence::filter' => ['Ds\Sequence', 'callback='=>'callable'],
'Ds\Sequence::find' => ['mixed', 'value'=>'mixed'],
'Ds\Sequence::first' => ['mixed'],
'Ds\Sequence::get' => ['mixed', 'index'=>'int'],
'Ds\Sequence::insert' => ['void', 'index'=>'int', '...values='=>'mixed'],
'Ds\Sequence::join' => ['string', 'glue='=>'string'],
'Ds\Sequence::last' => ['void'],
'Ds\Sequence::map' => ['Ds\Sequence', 'callback'=>'callable'],
'Ds\Sequence::merge' => ['Ds\Sequence', 'values'=>'mixed'],
'Ds\Sequence::pop' => ['mixed'],
'Ds\Sequence::push' => ['void', '...values='=>'mixed'],
'Ds\Sequence::reduce' => ['mixed', 'callback'=>'callable', 'initial='=>'mixed'],
'Ds\Sequence::remove' => ['mixed', 'index'=>'int'],
'Ds\Sequence::reverse' => ['void'],
'Ds\Sequence::reversed' => ['Ds\Sequence'],
'Ds\Sequence::rotate' => ['void', 'rotations'=>'int'],
'Ds\Sequence::set' => ['void', 'index'=>'int', 'value'=>'mixed'],
'Ds\Sequence::shift' => ['mixed'],
'Ds\Sequence::slice' => ['Ds\Sequence', 'index'=>'int', 'length='=>'?int'],
'Ds\Sequence::sort' => ['void', 'comparator='=>'callable'],
'Ds\Sequence::sorted' => ['Ds\Sequence', 'comparator='=>'callable'],
'Ds\Sequence::sum' => ['int|float'],
'Ds\Sequence::unshift' => ['void', '...values='=>'mixed'],
'Ds\Vector::__construct' => ['void', 'values='=>'mixed'],
'Ds\Vector::allocate' => ['void', 'capacity'=>'int'],
'Ds\Vector::apply' => ['void', 'callback'=>'callable'],
'Ds\Vector::capacity' => ['int'],
'Ds\Vector::contains' => ['bool', '...values='=>'mixed'],
'Ds\Vector::filter' => ['Ds\Vector', 'callback='=>'callable'],
'Ds\Vector::find' => ['mixed', 'value'=>'mixed'],
'Ds\Vector::first' => ['mixed'],
'Ds\Vector::get' => ['mixed', 'index'=>'int'],
'Ds\Vector::insert' => ['void', 'index'=>'int', '...values='=>'mixed'],
'Ds\Vector::join' => ['string', 'glue='=>'string'],
'Ds\Vector::last' => ['mixed'],
'Ds\Vector::map' => ['Ds\Vector', 'callback'=>'callable'],
'Ds\Vector::merge' => ['Ds\Vector', 'values'=>'mixed'],
'Ds\Vector::pop' => ['mixed'],
'Ds\Vector::push' => ['void', '...values='=>'mixed'],
'Ds\Vector::reduce' => ['mixed', 'callback'=>'callable', 'initial='=>'mixed'],
'Ds\Vector::remove' => ['mixed', 'index'=>'int'],
'Ds\Vector::reverse' => ['void'],
'Ds\Vector::reversed' => ['Ds\Vector'],
'Ds\Vector::rotate' => ['void', 'rotations'=>'int'],
'Ds\Vector::set' => ['void', 'index'=>'int', 'value'=>'mixed'],
'Ds\Vector::shift' => ['mixed'],
'Ds\Vector::slice' => ['Ds\Vector', 'index'=>'int', 'length='=>'?int'],
'Ds\Vector::sort' => ['void', 'comparator='=>'callable'],
'Ds\Vector::sorted' => ['Ds\Vector', 'comparator='=>'callable'],
'Ds\Vector::sum' => ['int|float'],
'Ds\Vector::unshift' => ['void', '...values='=>'mixed'],
'Ds\Vector::clear' => ['void'],
'Ds\Vector::copy' => ['Ds\Vector'],
'Ds\Vector::count' => ['int'],
'Ds\Vector::isEmpty' => ['bool'],
'Ds\Vector::jsonSerialize' => ['array'],
'Ds\Vector::toArray' => ['array'],
'Ds\Deque::__construct' => ['void', 'values='=>'mixed'],
'Ds\Deque::clear' => ['void'],
'Ds\Deque::copy' => ['Ds\Deque'],
'Ds\Deque::count' => ['int'],
'Ds\Deque::isEmpty' => ['bool'],
'Ds\Deque::jsonSerialize' => ['array'],
'Ds\Deque::toArray' => ['array'],
'Ds\Deque::allocate' => ['void', 'capacity'=>'int'],
'Ds\Deque::apply' => ['void', 'callback'=>'callable'],
'Ds\Deque::capacity' => ['int'],
'Ds\Deque::contains' => ['bool', '...values='=>'mixed'],
'Ds\Deque::filter' => ['Ds\Deque', 'callback='=>'callable'],
'Ds\Deque::find' => ['mixed', 'value'=>'mixed'],
'Ds\Deque::first' => ['mixed'],
'Ds\Deque::get' => ['void', 'index'=>'int'],
'Ds\Deque::insert' => ['void', 'index'=>'int', '...values='=>'mixed'],
'Ds\Deque::join' => ['string', 'glue='=>'string'],
'Ds\Deque::last' => ['mixed'],
'Ds\Deque::map' => ['Ds\Deque', 'callback'=>'callable'],
'Ds\Deque::merge' => ['Ds\Deque', 'values'=>'mixed'],
'Ds\Deque::pop' => ['mixed'],
'Ds\Deque::push' => ['void', '...values='=>'mixed'],
'Ds\Deque::reduce' => ['mixed', 'callback'=>'callable', 'initial='=>'mixed'],
'Ds\Deque::remove' => ['mixed', 'index'=>'int'],
'Ds\Deque::reverse' => ['void'],
'Ds\Deque::reversed' => ['Ds\Deque'],
'Ds\Deque::rotate' => ['void', 'rotations'=>'int'],
'Ds\Deque::set' => ['void', 'index'=>'int', 'value'=>'mixed'],
'Ds\Deque::shift' => ['mixed'],
'Ds\Deque::slice' => ['Ds\Deque', 'index'=>'int', 'length='=>'?int'],
'Ds\Deque::sort' => ['void', 'comparator='=>'callable'],
'Ds\Deque::sorted' => ['Ds\Deque', 'comparator='=>'callable'],
'Ds\Deque::sum' => ['int|float'],
'Ds\Deque::unshift' => ['void', '...values='=>'mixed'],
'Ds\Map::__construct' => ['void', 'values='=>'mixed'],
'Ds\Map::allocate' => ['void', 'capacity'=>'int'],
'Ds\Map::apply' => ['void', 'callback'=>'callable'],
'Ds\Map::capacity' => ['int'],
'Ds\Map::diff' => ['Ds\Map', 'map'=>'Ds\Map'],
'Ds\Map::filter' => ['Ds\Map', 'callback='=>'callable'],
'Ds\Map::first' => ['Ds\Pair'],
'Ds\Map::get' => ['mixed', 'key'=>'mixed', 'default='=>'mixed'],
'Ds\Map::hasKey' => ['bool', 'key'=>'mixed'],
'Ds\Map::hasValue' => ['bool', 'value'=>'mixed'],
'Ds\Map::intersect' => ['Ds\Map', 'map'=>'Ds\Map'],
'Ds\Map::keys' => ['Ds\Set'],
'Ds\Map::ksort' => ['void', 'comparator='=>'callable'],
'Ds\Map::ksorted' => ['Ds\Map', 'comparator='=>'callable'],
'Ds\Map::last' => ['Ds\Pair'],
'Ds\Map::map' => ['Ds\Map', 'callback'=>'callable'],
'Ds\Map::merge' => ['Ds\Map', 'values'=>'mixed'],
'Ds\Map::pairs' => ['Ds\Sequence'],
'Ds\Map::put' => ['void', 'key'=>'mixed', 'value'=>'mixed'],
'Ds\Map::putAll' => ['void', 'values'=>'mixed'],
'Ds\Map::reduce' => ['mixed', 'callback'=>'callable', 'initial='=>'mixed'],
'Ds\Map::remove' => ['mixed', 'key'=>'mixed', 'default='=>'mixed'],
'Ds\Map::reverse' => ['void'],
'Ds\Map::reversed' => ['Ds\Map'],
'Ds\Map::skip' => ['Ds\Pair', 'position'=>'int'],
'Ds\Map::slice' => ['Ds\Map', 'index'=>'int', 'length='=>'?int'],
'Ds\Map::sort' => ['void', 'comparator='=>'callable'],
'Ds\Map::sorted' => ['Ds\Map', 'comparator='=>'callable'],
'Ds\Map::sum' => ['int|float'],
'Ds\Map::union' => ['Ds\Map', 'map'=>'mixed'],
'Ds\Map::values' => ['Ds\Sequence'],
'Ds\Map::xor' => ['Ds\Map', 'map'=>'Ds\Map'],
'Ds\Map::clear' => ['void'],
'Ds\Map::copy' => ['Ds\Map'],
'Ds\Map::count' => ['int'],
'Ds\Map::isEmpty' => ['bool'],
'Ds\Map::jsonSerialize' => ['array'],
'Ds\Map::toArray' => ['array'],
'Ds\Pair::__construct' => ['void', 'key='=>'mixed', 'value='=>'mixed'],
'Ds\Pair::copy' => ['Ds\Pair'],
'Ds\Pair::jsonSerialize' => ['array'],
'Ds\Pair::toArray' => ['array'],
'Ds\Set::__construct' => ['void', 'values='=>'mixed'],
'Ds\Set::add' => ['void', '...values='=>'mixed'],
'Ds\Set::allocate' => ['void', 'capacity'=>'int'],
'Ds\Set::capacity' => ['int'],
'Ds\Set::contains' => ['bool', '...values='=>'mixed'],
'Ds\Set::diff' => ['Ds\Set', 'set'=>'Ds\Set'],
'Ds\Set::filter' => ['Ds\Set', 'callback='=>'callable'],
'Ds\Set::first' => ['void'],
'Ds\Set::get' => ['mixed', 'index'=>'int'],
'Ds\Set::intersect' => ['Ds\Set', 'set'=>'Ds\Set'],
'Ds\Set::join' => ['void', 'glue='=>'string'],
'Ds\Set::last' => ['void'],
'Ds\Set::merge' => ['Ds\Set', 'values'=>'mixed'],
'Ds\Set::reduce' => ['mixed', 'callback'=>'callable', 'initial='=>'mixed'],
'Ds\Set::remove' => ['void', '...values='=>'mixed'],
'Ds\Set::reverse' => ['void'],
'Ds\Set::reversed' => ['Ds\Set'],
'Ds\Set::slice' => ['Ds\Set', 'index'=>'int', 'length='=>'?int'],
'Ds\Set::sort' => ['void', 'comparator='=>'callable'],
'Ds\Set::sorted' => ['Ds\Set', 'comparator='=>'callable'],
'Ds\Set::sum' => ['int|float'],
'Ds\Set::union' => ['?Ds\Set', 'set'=>'Ds\Set'],
'Ds\Set::xor' => ['Ds\Set', 'set'=>'Ds\Set'],
'Ds\Set::clear' => ['void'],
'Ds\Set::copy' => ['Ds\Set'],
'Ds\Set::count' => ['int'],
'Ds\Set::isEmpty' => ['bool'],
'Ds\Set::jsonSerialize' => ['array'],
'Ds\Set::toArray' => ['array'],
'Ds\Stack::__construct' => ['void', 'values='=>'mixed'],
'Ds\Stack::allocate' => ['void', 'capacity'=>'int'],
'Ds\Stack::capacity' => ['int'],
'Ds\Stack::peek' => ['mixed'],
'Ds\Stack::pop' => ['mixed'],
'Ds\Stack::push' => ['void', '...values='=>'mixed'],
'Ds\Stack::clear' => ['void'],
'Ds\Stack::copy' => ['Ds\Stack'],
'Ds\Stack::count' => ['int'],
'Ds\Stack::isEmpty' => ['bool'],
'Ds\Stack::jsonSerialize' => ['array'],
'Ds\Stack::toArray' => ['array'],
'Ds\Queue::__construct' => ['void', 'values='=>'mixed'],
'Ds\Queue::allocate' => ['void', 'capacity'=>'int'],
'Ds\Queue::capacity' => ['int'],
'Ds\Queue::peek' => ['mixed'],
'Ds\Queue::pop' => ['mixed'],
'Ds\Queue::push' => ['void', '...values='=>'mixed'],
'Ds\Queue::clear' => ['void'],
'Ds\Queue::copy' => ['Ds\Queue'],
'Ds\Queue::count' => ['int'],
'Ds\Queue::isEmpty' => ['bool'],
'Ds\Queue::jsonSerialize' => ['array'],
'Ds\Queue::toArray' => ['array'],
'Ds\PriorityQueue::__construct' => ['void'],
'Ds\PriorityQueue::allocate' => ['void', 'capacity'=>'int'],
'Ds\PriorityQueue::capacity' => ['int'],
'Ds\PriorityQueue::peek' => ['mixed'],
'Ds\PriorityQueue::pop' => ['mixed'],
'Ds\PriorityQueue::push' => ['void', 'value'=>'mixed', 'priority'=>'int'],
'Ds\PriorityQueue::clear' => ['void'],
'Ds\PriorityQueue::copy' => ['Ds\PriorityQueue'],
'Ds\PriorityQueue::count' => ['int'],
'Ds\PriorityQueue::isEmpty' => ['bool'],
'Ds\PriorityQueue::jsonSerialize' => ['array'],
'Ds\PriorityQueue::toArray' => ['array'],
'each' => ['array', '&rw_arr'=>'array'],
'easter_date' => ['int', 'year='=>'int'],
'easter_days' => ['int', 'year='=>'int', 'method='=>'int'],
'echo' => ['void', 'arg1'=>'string', '...args='=>'string'],
'eio_busy' => ['resource', 'delay'=>'int', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_cancel' => ['void', 'req'=>'resource'],
'eio_chmod' => ['resource', 'path'=>'string', 'mode'=>'int', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_chown' => ['resource', 'path'=>'string', 'uid'=>'int', 'gid='=>'int', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_close' => ['resource', 'fd'=>'mixed', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_custom' => ['resource', 'execute'=>'callable', 'pri'=>'int', 'callback'=>'callable', 'data='=>'mixed'],
'eio_dup2' => ['resource', 'fd'=>'mixed', 'fd2'=>'mixed', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_event_loop' => ['bool'],
'eio_fallocate' => ['resource', 'fd'=>'mixed', 'mode'=>'int', 'offset'=>'int', 'length'=>'int', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_fchmod' => ['resource', 'fd'=>'mixed', 'mode'=>'int', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_fchown' => ['resource', 'fd'=>'mixed', 'uid'=>'int', 'gid='=>'int', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_fdatasync' => ['resource', 'fd'=>'mixed', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_fstat' => ['resource', 'fd'=>'mixed', 'pri'=>'int', 'callback'=>'callable', 'data='=>'mixed'],
'eio_fstatvfs' => ['resource', 'fd'=>'mixed', 'pri'=>'int', 'callback'=>'callable', 'data='=>'mixed'],
'eio_fsync' => ['resource', 'fd'=>'mixed', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_ftruncate' => ['resource', 'fd'=>'mixed', 'offset='=>'int', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_futime' => ['resource', 'fd'=>'mixed', 'atime'=>'float', 'mtime'=>'float', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_get_event_stream' => ['mixed'],
'eio_get_last_error' => ['string', 'req'=>'resource'],
'eio_grp' => ['resource', 'callback'=>'callable', 'data='=>'string'],
'eio_grp_add' => ['void', 'grp'=>'resource', 'req'=>'resource'],
'eio_grp_cancel' => ['void', 'grp'=>'resource'],
'eio_grp_limit' => ['void', 'grp'=>'resource', 'limit'=>'int'],
'eio_init' => ['void'],
'eio_link' => ['resource', 'path'=>'string', 'new_path'=>'string', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_lstat' => ['resource', 'path'=>'string', 'pri'=>'int', 'callback'=>'callable', 'data='=>'mixed'],
'eio_mkdir' => ['resource', 'path'=>'string', 'mode'=>'int', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_mknod' => ['resource', 'path'=>'string', 'mode'=>'int', 'dev'=>'int', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_nop' => ['resource', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_npending' => ['int'],
'eio_nready' => ['int'],
'eio_nreqs' => ['int'],
'eio_nthreads' => ['int'],
'eio_open' => ['resource', 'path'=>'string', 'flags'=>'int', 'mode'=>'int', 'pri'=>'int', 'callback'=>'callable', 'data='=>'mixed'],
'eio_poll' => ['int'],
'eio_read' => ['resource', 'fd'=>'mixed', 'length'=>'int', 'offset'=>'int', 'pri'=>'int', 'callback'=>'callable', 'data='=>'mixed'],
'eio_readahead' => ['resource', 'fd'=>'mixed', 'offset'=>'int', 'length'=>'int', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_readdir' => ['resource', 'path'=>'string', 'flags'=>'int', 'pri'=>'int', 'callback'=>'callable', 'data='=>'string'],
'eio_readlink' => ['resource', 'path'=>'string', 'pri'=>'int', 'callback'=>'callable', 'data='=>'string'],
'eio_realpath' => ['resource', 'path'=>'string', 'pri'=>'int', 'callback'=>'callable', 'data='=>'string'],
'eio_rename' => ['resource', 'path'=>'string', 'new_path'=>'string', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_rmdir' => ['resource', 'path'=>'string', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_seek' => ['resource', 'fd'=>'mixed', 'offset'=>'int', 'whence'=>'int', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_sendfile' => ['resource', 'out_fd'=>'mixed', 'in_fd'=>'mixed', 'offset'=>'int', 'length'=>'int', 'pri='=>'int', 'callback='=>'callable', 'data='=>'string'],
'eio_set_max_idle' => ['void', 'nthreads'=>'int'],
'eio_set_max_parallel' => ['void', 'nthreads'=>'int'],
'eio_set_max_poll_reqs' => ['void', 'nreqs'=>'int'],
'eio_set_max_poll_time' => ['void', 'nseconds'=>'float'],
'eio_set_min_parallel' => ['void', 'nthreads'=>'string'],
'eio_stat' => ['resource', 'path'=>'string', 'pri'=>'int', 'callback'=>'callable', 'data='=>'mixed'],
'eio_statvfs' => ['resource', 'path'=>'string', 'pri'=>'int', 'callback'=>'callable', 'data='=>'mixed'],
'eio_symlink' => ['resource', 'path'=>'string', 'new_path'=>'string', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_sync' => ['resource', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_sync_file_range' => ['resource', 'fd'=>'mixed', 'offset'=>'int', 'nbytes'=>'int', 'flags'=>'int', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_syncfs' => ['resource', 'fd'=>'mixed', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_truncate' => ['resource', 'path'=>'string', 'offset='=>'int', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_unlink' => ['resource', 'path'=>'string', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_utime' => ['resource', 'path'=>'string', 'atime'=>'float', 'mtime'=>'float', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'eio_write' => ['resource', 'fd'=>'mixed', 'str'=>'string', 'length='=>'int', 'offset='=>'int', 'pri='=>'int', 'callback='=>'callable', 'data='=>'mixed'],
'empty' => ['bool', 'var'=>'mixed'],
'EmptyIterator::current' => ['mixed'],
'EmptyIterator::key' => ['mixed'],
'EmptyIterator::next' => ['void'],
'EmptyIterator::rewind' => ['void'],
'EmptyIterator::valid' => ['bool'],
'enchant_broker_describe' => ['array', 'broker'=>'resource'],
'enchant_broker_dict_exists' => ['bool', 'broker'=>'resource', 'tag'=>'string'],
'enchant_broker_free' => ['bool', 'broker'=>'resource'],
'enchant_broker_free_dict' => ['resource', 'dict'=>'resource'],
'enchant_broker_get_dict_path' => ['string', 'broker'=>'resource', 'dict_type'=>'int'],
'enchant_broker_get_error' => ['string', 'broker'=>'resource'],
'enchant_broker_init' => ['resource'],
'enchant_broker_list_dicts' => ['string', 'broker'=>'resource'],
'enchant_broker_request_dict' => ['resource', 'broker'=>'resource', 'tag'=>'string'],
'enchant_broker_request_pwl_dict' => ['resource', 'broker'=>'resource', 'filename'=>'string'],
'enchant_broker_set_dict_path' => ['bool', 'broker'=>'resource', 'dict_type'=>'int', 'value'=>'string'],
'enchant_broker_set_ordering' => ['bool', 'broker'=>'resource', 'tag'=>'string', 'ordering'=>'string'],
'enchant_dict_add_to_personal' => ['void', 'dict'=>'resource', 'word'=>'string'],
'enchant_dict_add_to_session' => ['void', 'dict'=>'resource', 'word'=>'string'],
'enchant_dict_check' => ['bool', 'dict'=>'resource', 'word'=>'string'],
'enchant_dict_describe' => ['array', 'dict'=>'resource'],
'enchant_dict_get_error' => ['string', 'dict'=>'resource'],
'enchant_dict_is_in_session' => ['bool', 'dict'=>'resource', 'word'=>'string'],
'enchant_dict_quick_check' => ['bool', 'dict'=>'resource', 'word'=>'string', 'suggestions='=>'array'],
'enchant_dict_store_replacement' => ['void', 'dict'=>'resource', 'mis'=>'string', 'cor'=>'string'],
'enchant_dict_suggest' => ['array', 'dict'=>'resource', 'word'=>'string'],
'end' => ['mixed', '&rw_array_arg'=>'array|object'],
'ereg' => ['int', 'pattern'=>'string', 'string'=>'string', 'regs='=>'array'],
'ereg_replace' => ['string', 'pattern'=>'string', 'replacement'=>'string', 'string'=>'string'],
'eregi' => ['int', 'pattern'=>'string', 'string'=>'string', 'regs='=>'array'],
'eregi_replace' => ['string', 'pattern'=>'string', 'replacement'=>'string', 'string'=>'string'],
'Error::__clone' => ['void'],
'Error::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?Error'],
'Error::__toString' => ['string'],
'Error::getCode' => ['int'],
'Error::getFile' => ['string'],
'Error::getLine' => ['int'],
'Error::getMessage' => ['string'],
'Error::getPrevious' => ['Throwable|Error|null'],
'Error::getTrace' => ['array'],
'Error::getTraceAsString' => ['string'],
'error_clear_last' => ['void'],
'error_get_last' => ['?array'],
'error_log' => ['bool', 'message'=>'string', 'message_type='=>'int', 'destination='=>'string', 'extra_headers='=>'string'],
'error_reporting' => ['int', 'new_error_level='=>'int'],
'ErrorException::__clone' => ['void'],
'ErrorException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'severity='=>'int', 'filename='=>'string', 'lineno='=>'int', 'previous='=>'?Throwable|?ErrorException'],
'ErrorException::__toString' => ['string'],
'ErrorException::getCode' => ['int'],
'ErrorException::getFile' => ['string'],
'ErrorException::getLine' => ['int'],
'ErrorException::getMessage' => ['string'],
'ErrorException::getPrevious' => ['Throwable|ErrorException|null'],
'ErrorException::getSeverity' => ['int'],
'ErrorException::getTrace' => ['array'],
'ErrorException::getTraceAsString' => ['string'],
'escapeshellarg' => ['string', 'arg'=>'string'],
'escapeshellcmd' => ['string', 'command'=>'string'],
'Ev::backend' => ['int'],
'Ev::depth' => ['int'],
'Ev::embeddableBackends' => ['void'],
'Ev::feedSignal' => ['void', 'signum'=>'int'],
'Ev::feedSignalEvent' => ['void', 'signum'=>'int'],
'Ev::iteration' => ['int'],
'Ev::now' => ['float'],
'Ev::nowUpdate' => ['void'],
'Ev::recommendedBackends' => ['void'],
'Ev::resume' => ['void'],
'Ev::run' => ['void', 'flags='=>'int'],
'Ev::sleep' => ['void', 'seconds'=>'float'],
'Ev::stop' => ['void', 'how='=>'int'],
'Ev::supportedBackends' => ['void'],
'Ev::suspend' => ['void'],
'Ev::time' => ['float'],
'Ev::verify' => ['void'],
'eval' => ['mixed', 'code_str'=>'string'],
'EvCheck::__construct' => ['void', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvCheck::createStopped' => ['object', 'callback'=>'string', 'data='=>'string', 'priority='=>'string'],
'EvChild::__construct' => ['void', 'pid'=>'int', 'trace'=>'bool', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvChild::createStopped' => ['object', 'pid'=>'int', 'trace'=>'bool', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvChild::set' => ['void', 'pid'=>'int', 'trace'=>'bool'],
'EvEmbed::__construct' => ['void', 'other'=>'object', 'callback='=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvEmbed::createStopped' => ['void', 'other'=>'object', 'callback='=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvEmbed::set' => ['void', 'other'=>'object'],
'EvEmbed::sweep' => ['void'],
'Event::__construct' => ['void', 'base'=>'EventBase', 'fd'=>'mixed', 'what'=>'int', 'cb'=>'callable', 'arg='=>'mixed'],
'Event::add' => ['bool', 'timeout='=>'float'],
'Event::addSignal' => ['bool', 'timeout='=>'float'],
'Event::addTimer' => ['bool', 'timeout='=>'float'],
'Event::del' => ['bool'],
'Event::delSignal' => ['bool'],
'Event::delTimer' => ['bool'],
'Event::free' => ['void'],
'Event::getSupportedMethods' => ['array'],
'Event::pending' => ['bool', 'flags'=>'int'],
'Event::set' => ['bool', 'base'=>'EventBase', 'fd'=>'mixed', 'what='=>'int', 'cb='=>'callable', 'arg='=>'mixed'],
'Event::setPriority' => ['bool', 'priority'=>'int'],
'Event::setTimer' => ['bool', 'base'=>'EventBase', 'cb'=>'callable', 'arg='=>'mixed'],
'Event::signal' => ['Event', 'base'=>'EventBase', 'signum'=>'int', 'cb'=>'callable', 'arg='=>'mixed'],
'Event::timer' => ['Event', 'base'=>'EventBase', 'cb'=>'callable', 'arg='=>'mixed'],
'event_add' => ['bool', 'event'=>'resource', 'timeout='=>'int'],
'event_base_free' => ['void', 'event_base'=>'resource'],
'event_base_loop' => ['int', 'event_base'=>'resource', 'flags='=>'int'],
'event_base_loopbreak' => ['bool', 'event_base'=>'resource'],
'event_base_loopexit' => ['bool', 'event_base'=>'resource', 'timeout='=>'int'],
'event_base_new' => ['resource'],
'event_base_priority_init' => ['bool', 'event_base'=>'resource', 'npriorities'=>'int'],
'event_base_reinit' => ['bool', 'event_base'=>'resource'],
'event_base_set' => ['bool', 'event'=>'resource', 'event_base'=>'resource'],
'event_buffer_base_set' => ['bool', 'bevent'=>'resource', 'event_base'=>'resource'],
'event_buffer_disable' => ['bool', 'bevent'=>'resource', 'events'=>'int'],
'event_buffer_enable' => ['bool', 'bevent'=>'resource', 'events'=>'int'],
'event_buffer_fd_set' => ['void', 'bevent'=>'resource', 'fd'=>'resource'],
'event_buffer_free' => ['void', 'bevent'=>'resource'],
'event_buffer_new' => ['resource', 'stream'=>'resource', 'readcb'=>'mixed', 'writecb'=>'mixed', 'errorcb'=>'mixed', 'arg='=>'mixed'],
'event_buffer_priority_set' => ['bool', 'bevent'=>'resource', 'priority'=>'int'],
'event_buffer_read' => ['string', 'bevent'=>'resource', 'data_size'=>'int'],
'event_buffer_set_callback' => ['bool', 'event'=>'resource', 'readcb'=>'mixed', 'writecb'=>'mixed', 'errorcb'=>'mixed', 'arg='=>'mixed'],
'event_buffer_timeout_set' => ['void', 'bevent'=>'resource', 'read_timeout'=>'int', 'write_timeout'=>'int'],
'event_buffer_watermark_set' => ['void', 'bevent'=>'resource', 'events'=>'int', 'lowmark'=>'int', 'highmark'=>'int'],
'event_buffer_write' => ['bool', 'bevent'=>'resource', 'data'=>'string', 'data_size='=>'int'],
'event_del' => ['bool', 'event'=>'resource'],
'event_free' => ['void', 'event'=>'resource'],
'event_new' => ['resource'],
'event_priority_set' => ['bool', 'event'=>'resource', 'priority'=>'int'],
'event_set' => ['bool', 'event'=>'resource', 'fd'=>'mixed', 'events'=>'int', 'callback'=>'mixed', 'arg='=>'mixed'],
'event_timer_add' => ['bool', 'event'=>'resource', 'timeout='=>'int'],
'event_timer_del' => ['bool', 'event'=>'resource'],
'event_timer_new' => ['bool|resource'],
'event_timer_pending' => ['bool', 'event'=>'resource', 'timeout='=>'int'],
'event_timer_set' => ['bool', 'event'=>'resource', 'callback'=>'callable', 'arg='=>'mixed'],
'EventBase::__construct' => ['void', 'cfg='=>'EventConfig'],
'EventBase::dispatch' => ['void'],
'EventBase::exit' => ['bool', 'timeout='=>'float'],
'EventBase::free' => ['void'],
'EventBase::getFeatures' => ['int'],
'EventBase::getMethod' => ['string', 'cfg='=>'EventConfig'],
'EventBase::getTimeOfDayCached' => ['float'],
'EventBase::gotExit' => ['bool'],
'EventBase::gotStop' => ['bool'],
'EventBase::loop' => ['bool', 'flags='=>'int'],
'EventBase::priorityInit' => ['bool', 'n_priorities'=>'int'],
'EventBase::reInit' => ['bool'],
'EventBase::stop' => ['bool'],
'EventBuffer::__construct' => ['void'],
'EventBuffer::add' => ['bool', 'data'=>'string'],
'EventBuffer::addBuffer' => ['bool', 'buf'=>'EventBuffer'],
'EventBuffer::appendFrom' => ['int', 'buf'=>'EventBuffer', 'len'=>'int'],
'EventBuffer::copyout' => ['int', '&w_data'=>'string', 'max_bytes'=>'int'],
'EventBuffer::drain' => ['bool', 'len'=>'int'],
'EventBuffer::enableLocking' => ['void'],
'EventBuffer::expand' => ['bool', 'len'=>'int'],
'EventBuffer::freeze' => ['bool', 'at_front'=>'bool'],
'EventBuffer::lock' => ['void'],
'EventBuffer::prepend' => ['bool', 'data'=>'string'],
'EventBuffer::prependBuffer' => ['bool', 'buf'=>'EventBuffer'],
'EventBuffer::pullup' => ['string', 'size'=>'int'],
'EventBuffer::read' => ['string', 'max_bytes'=>'int'],
'EventBuffer::readFrom' => ['int', 'fd'=>'mixed', 'howmuch'=>'int'],
'EventBuffer::readLine' => ['string', 'eol_style'=>'int'],
'EventBuffer::search' => ['mixed', 'what'=>'string', 'start='=>'int', 'end='=>'int'],
'EventBuffer::searchEol' => ['mixed', 'start='=>'int', 'eol_style='=>'int'],
'EventBuffer::substr' => ['string', 'start'=>'int', 'length='=>'int'],
'EventBuffer::unfreeze' => ['bool', 'at_front'=>'bool'],
'EventBuffer::unlock' => ['bool'],
'EventBuffer::write' => ['int', 'fd'=>'mixed', 'howmuch='=>'int'],
'EventBufferEvent::__construct' => ['void', 'base'=>'EventBase', 'socket='=>'mixed', 'options='=>'int', 'readcb='=>'callable', 'writecb='=>'callable', 'eventcb='=>'callable'],
'EventBufferEvent::close' => ['void'],
'EventBufferEvent::connect' => ['bool', 'addr'=>'string'],
'EventBufferEvent::connectHost' => ['bool', 'dns_base'=>'EventDnsBase', 'hostname'=>'string', 'port'=>'int', 'family='=>'int'],
'EventBufferEvent::createPair' => ['array', 'base'=>'EventBase', 'options='=>'int'],
'EventBufferEvent::disable' => ['bool', 'events'=>'int'],
'EventBufferEvent::enable' => ['bool', 'events'=>'int'],
'EventBufferEvent::free' => ['void'],
'EventBufferEvent::getDnsErrorString' => ['string'],
'EventBufferEvent::getEnabled' => ['int'],
'EventBufferEvent::getInput' => ['EventBuffer'],
'EventBufferEvent::getOutput' => ['EventBuffer'],
'EventBufferEvent::read' => ['string', 'size'=>'int'],
'EventBufferEvent::readBuffer' => ['bool', 'buf'=>'EventBuffer'],
'EventBufferEvent::setCallbacks' => ['void', 'readcb'=>'callable', 'writecb'=>'callable', 'eventcb'=>'callable', 'arg='=>'string'],
'EventBufferEvent::setPriority' => ['bool', 'priority'=>'int'],
'EventBufferEvent::setTimeouts' => ['bool', 'timeout_read'=>'float', 'timeout_write'=>'float'],
'EventBufferEvent::setWatermark' => ['void', 'events'=>'int', 'lowmark'=>'int', 'highmark'=>'int'],
'EventBufferEvent::sslError' => ['string'],
'EventBufferEvent::sslFilter' => ['EventBufferEvent', 'base'=>'EventBase', 'underlying'=>'EventBufferEvent', 'ctx'=>'EventSslContext', 'state'=>'int', 'options='=>'int'],
'EventBufferEvent::sslGetCipherInfo' => ['string'],
'EventBufferEvent::sslGetCipherName' => ['string'],
'EventBufferEvent::sslGetCipherVersion' => ['string'],
'EventBufferEvent::sslGetProtocol' => ['string'],
'EventBufferEvent::sslRenegotiate' => ['void'],
'EventBufferEvent::sslSocket' => ['EventBufferEvent', 'base'=>'EventBase', 'socket'=>'mixed', 'ctx'=>'EventSslContext', 'state'=>'int', 'options='=>'int'],
'EventBufferEvent::write' => ['bool', 'data'=>'string'],
'EventBufferEvent::writeBuffer' => ['bool', 'buf'=>'EventBuffer'],
'EventConfig::__construct' => ['void'],
'EventConfig::avoidMethod' => ['bool', 'method'=>'int'],
'EventConfig::requireFeatures' => ['bool', 'feature'=>'int'],
'EventConfig::setMaxDispatchInterval' => ['void', 'max_interval'=>'int', 'max_callbacks'=>'int', 'min_priority'=>'int'],
'EventDnsBase::__construct' => ['void', 'base'=>'EventBase', 'initialize'=>'bool'],
'EventDnsBase::addNameserverIp' => ['bool', 'ip'=>'string'],
'EventDnsBase::addSearch' => ['void', 'domain'=>'string'],
'EventDnsBase::clearSearch' => ['void'],
'EventDnsBase::countNameservers' => ['int'],
'EventDnsBase::loadHosts' => ['bool', 'hosts'=>'string'],
'EventDnsBase::parseResolvConf' => ['bool', 'flags'=>'int', 'filename'=>'string'],
'EventDnsBase::setOption' => ['bool', 'option'=>'string', 'value'=>'string'],
'EventDnsBase::setSearchNdots' => ['bool', 'ndots'=>'int'],
'EventHttp::__construct' => ['void', 'base'=>'EventBase', 'ctx='=>'EventSslContext'],
'EventHttp::accept' => ['bool', 'socket'=>'mixed'],
'EventHttp::addServerAlias' => ['bool', 'alias'=>'string'],
'EventHttp::bind' => ['void', 'address'=>'string', 'port'=>'int'],
'EventHttp::removeServerAlias' => ['bool', 'alias'=>'string'],
'EventHttp::setAllowedMethods' => ['void', 'methods'=>'int'],
'EventHttp::setCallback' => ['void', 'path'=>'string', 'cb'=>'string', 'arg='=>'string'],
'EventHttp::setDefaultCallback' => ['void', 'cb'=>'string', 'arg='=>'string'],
'EventHttp::setMaxBodySize' => ['void', 'value'=>'int'],
'EventHttp::setMaxHeadersSize' => ['void', 'value'=>'int'],
'EventHttp::setTimeout' => ['void', 'value'=>'int'],
'EventHttpConnection::__construct' => ['void', 'base'=>'EventBase', 'dns_base'=>'EventDnsBase', 'address'=>'string', 'port'=>'int', 'ctx='=>'EventSslContext'],
'EventHttpConnection::getBase' => ['EventBase'],
'EventHttpConnection::getPeer' => ['void', '&w_address'=>'string', '&w_port'=>'int'],
'EventHttpConnection::makeRequest' => ['bool', 'req'=>'EventHttpRequest', 'type'=>'int', 'uri'=>'string'],
'EventHttpConnection::setCloseCallback' => ['void', 'callback'=>'callable', 'data='=>'mixed'],
'EventHttpConnection::setLocalAddress' => ['void', 'address'=>'string'],
'EventHttpConnection::setLocalPort' => ['void', 'port'=>'int'],
'EventHttpConnection::setMaxBodySize' => ['void', 'max_size'=>'string'],
'EventHttpConnection::setMaxHeadersSize' => ['void', 'max_size'=>'string'],
'EventHttpConnection::setRetries' => ['void', 'retries'=>'int'],
'EventHttpConnection::setTimeout' => ['void', 'timeout'=>'int'],
'EventHttpRequest::__construct' => ['void', 'callback'=>'callable', 'data='=>'mixed'],
'EventHttpRequest::addHeader' => ['bool', 'key'=>'string', 'value'=>'string', 'type'=>'int'],
'EventHttpRequest::cancel' => ['void'],
'EventHttpRequest::clearHeaders' => ['void'],
'EventHttpRequest::closeConnection' => ['void'],
'EventHttpRequest::findHeader' => ['void', 'key'=>'string', 'type'=>'string'],
'EventHttpRequest::free' => ['void'],
'EventHttpRequest::getBufferEvent' => ['EventBufferEvent'],
'EventHttpRequest::getCommand' => ['void'],
'EventHttpRequest::getConnection' => ['EventHttpConnection'],
'EventHttpRequest::getHost' => ['string'],
'EventHttpRequest::getInputBuffer' => ['EventBuffer'],
'EventHttpRequest::getInputHeaders' => ['array'],
'EventHttpRequest::getOutputBuffer' => ['EventBuffer'],
'EventHttpRequest::getOutputHeaders' => ['void'],
'EventHttpRequest::getResponseCode' => ['int'],
'EventHttpRequest::getUri' => ['string'],
'EventHttpRequest::removeHeader' => ['void', 'key'=>'string', 'type'=>'string'],
'EventHttpRequest::sendError' => ['void', 'error'=>'int', 'reason='=>'string'],
'EventHttpRequest::sendReply' => ['void', 'code'=>'int', 'reason'=>'string', 'buf='=>'EventBuffer'],
'EventHttpRequest::sendReplyChunk' => ['void', 'buf'=>'EventBuffer'],
'EventHttpRequest::sendReplyEnd' => ['void'],
'EventHttpRequest::sendReplyStart' => ['void', 'code'=>'int', 'reason'=>'string'],
'EventListener::__construct' => ['void', 'base'=>'EventBase', 'cb'=>'callable', 'data'=>'mixed', 'flags'=>'int', 'backlog'=>'int', 'target'=>'mixed'],
'EventListener::disable' => ['bool'],
'EventListener::enable' => ['bool'],
'EventListener::getBase' => ['void'],
'EventListener::getSocketName' => ['bool', '&w_address'=>'string', '&w_port='=>'mixed'],
'EventListener::setCallback' => ['void', 'cb'=>'callable', 'arg='=>'mixed'],
'EventListener::setErrorCallback' => ['void', 'cb'=>'string'],
'EventSslContext::__construct' => ['void', 'method'=>'string', 'options'=>'string'],
'EventUtil::__construct' => ['void'],
'EventUtil::getLastSocketErrno' => ['int', 'socket='=>'mixed'],
'EventUtil::getLastSocketError' => ['string', 'socket='=>'mixed'],
'EventUtil::getSocketFd' => ['int', 'socket'=>'mixed'],
'EventUtil::getSocketName' => ['bool', 'socket'=>'mixed', '&w_address'=>'string', '&w_port='=>'mixed'],
'EventUtil::setSocketOption' => ['bool', 'socket'=>'mixed', 'level'=>'int', 'optname'=>'int', 'optval'=>'mixed'],
'EventUtil::sslRandPoll' => ['void'],
'EvFork::__construct' => ['void', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvFork::createStopped' => ['object', 'callback'=>'string', 'data='=>'string', 'priority='=>'string'],
'EvIdle::__construct' => ['void', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvIdle::createStopped' => ['object', 'callback'=>'string', 'data='=>'mixed', 'priority='=>'int'],
'EvIo::__construct' => ['void', 'fd'=>'mixed', 'events'=>'int', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvIo::createStopped' => ['EvIo', 'fd'=>'mixed', 'events'=>'int', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvIo::set' => ['void', 'fd'=>'mixed', 'events'=>'int'],
'EvLoop::__construct' => ['void', 'flags='=>'int', 'data='=>'mixed', 'io_interval='=>'float', 'timeout_interval='=>'float'],
'EvLoop::backend' => ['int'],
'EvLoop::check' => ['EvCheck', 'callback'=>'string', 'data='=>'string', 'priority='=>'string'],
'EvLoop::child' => ['EvChild', 'pid'=>'string', 'trace'=>'string', 'callback'=>'string', 'data='=>'string', 'priority='=>'string'],
'EvLoop::defaultLoop' => ['EvLoop', 'flags='=>'int', 'data='=>'mixed', 'io_interval='=>'float', 'timeout_interval='=>'float'],
'EvLoop::embed' => ['EvEmbed', 'other'=>'string', 'callback='=>'string', 'data='=>'string', 'priority='=>'string'],
'EvLoop::fork' => ['EvFork', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvLoop::idle' => ['EvIdle', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvLoop::invokePending' => ['void'],
'EvLoop::io' => ['EvIo', 'fd'=>'mixed', 'events'=>'int', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvLoop::loopFork' => ['void'],
'EvLoop::now' => ['float'],
'EvLoop::nowUpdate' => ['void'],
'EvLoop::periodic' => ['EvPeriodic', 'offset'=>'float', 'interval'=>'float', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvLoop::prepare' => ['EvPrepare', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvLoop::resume' => ['void'],
'EvLoop::run' => ['void', 'flags='=>'int'],
'EvLoop::signal' => ['EvSignal', 'signum'=>'int', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvLoop::stat' => ['EvStat', 'path'=>'string', 'interval'=>'float', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvLoop::stop' => ['void', 'how='=>'int'],
'EvLoop::suspend' => ['void'],
'EvLoop::timer' => ['EvTimer', 'after'=>'float', 'repeat'=>'float', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvLoop::verify' => ['void'],
'EvPeriodic::__construct' => ['void', 'offset'=>'float', 'interval'=>'string', 'reschedule_cb'=>'callable', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvPeriodic::again' => ['void'],
'EvPeriodic::at' => ['float'],
'EvPeriodic::createStopped' => ['EvPeriodic', 'offset'=>'float', 'interval'=>'float', 'reschedule_cb'=>'callable', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvPeriodic::set' => ['void', 'offset'=>'float', 'interval'=>'float'],
'EvPrepare::__construct' => ['void', 'callback'=>'string', 'data='=>'string', 'priority='=>'string'],
'EvPrepare::createStopped' => ['EvPrepare', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvSignal::__construct' => ['void', 'signum'=>'int', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvSignal::createStopped' => ['EvSignal', 'signum'=>'int', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvSignal::set' => ['void', 'signum'=>'int'],
'EvStat::__construct' => ['void', 'path'=>'string', 'interval'=>'float', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvStat::attr' => ['array'],
'EvStat::createStopped' => ['void', 'path'=>'string', 'interval'=>'float', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvStat::prev' => ['void'],
'EvStat::set' => ['void', 'path'=>'string', 'interval'=>'float'],
'EvStat::stat' => ['bool'],
'EvTimer::__construct' => ['void', 'after'=>'float', 'repeat'=>'float', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvTimer::again' => ['void'],
'EvTimer::createStopped' => ['EvTimer', 'after'=>'float', 'repeat'=>'float', 'callback'=>'callable', 'data='=>'mixed', 'priority='=>'int'],
'EvTimer::set' => ['void', 'after'=>'float', 'repeat'=>'float'],
'EvWatcher::__construct' => ['void'],
'EvWatcher::clear' => ['int'],
'EvWatcher::feed' => ['void', 'revents'=>'int'],
'EvWatcher::getLoop' => ['EvLoop'],
'EvWatcher::invoke' => ['void', 'revents'=>'int'],
'EvWatcher::keepalive' => ['bool', 'value='=>'bool'],
'EvWatcher::setCallback' => ['void', 'callback'=>'callable'],
'EvWatcher::start' => ['void'],
'EvWatcher::stop' => ['void'],
'Exception::__clone' => ['void'],
'Exception::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?Exception'],
'Exception::__toString' => ['string'],
'Exception::getCode' => ['mixed'],
'Exception::getFile' => ['string'],
'Exception::getLine' => ['int'],
'Exception::getMessage' => ['string'],
'Exception::getPrevious' => ['?Throwable|?Exception'],
'Exception::getTrace' => ['array'],
'Exception::getTraceAsString' => ['string'],
'exec' => ['string', 'command'=>'string', '&w_output='=>'array', '&w_return_value='=>'int'],
'exif_imagetype' => ['int|false', 'imagefile'=>'string'],
'exif_read_data' => ['array|false', 'filename'=>'string', 'sections_needed='=>'string', 'sub_arrays='=>'bool', 'read_thumbnail='=>'bool'],
'exif_tagname' => ['string', 'index'=>'int'],
'exif_thumbnail' => ['string', 'filename'=>'string', '&w_width='=>'int', '&w_height='=>'int', '&w_imagetype='=>'int'],
'exit' => ['', 'status'=>'string|int'],
'exp' => ['float', 'number'=>'float'],
'expect_expectl' => ['int', 'expect'=>'resource', 'cases'=>'array', 'match='=>'array'],
'expect_popen' => ['resource', 'command'=>'string'],
'explode' => ['array|false', 'separator'=>'string', 'str'=>'string', 'limit='=>'int'],
'expm1' => ['float', 'number'=>'float'],
'extension_loaded' => ['bool', 'extension_name'=>'string'],
'extract' => ['int', '&rw_var_array'=>'array', 'extract_type='=>'int', 'prefix='=>'string'],
'ezmlm_hash' => ['int', 'addr'=>'string'],
'fam_cancel_monitor' => ['bool', 'fam'=>'resource', 'fam_monitor'=>'resource'],
'fam_close' => ['void', 'fam'=>'resource'],
'fam_monitor_collection' => ['resource', 'fam'=>'resource', 'dirname'=>'string', 'depth'=>'int', 'mask'=>'string'],
'fam_monitor_directory' => ['resource', 'fam'=>'resource', 'dirname'=>'string'],
'fam_monitor_file' => ['resource', 'fam'=>'resource', 'filename'=>'string'],
'fam_next_event' => ['array', 'fam'=>'resource'],
'fam_open' => ['resource', 'appname='=>'string'],
'fam_pending' => ['int', 'fam'=>'resource'],
'fam_resume_monitor' => ['bool', 'fam'=>'resource', 'fam_monitor'=>'resource'],
'fam_suspend_monitor' => ['bool', 'fam'=>'resource', 'fam_monitor'=>'resource'],
'fann_cascadetrain_on_data' => ['bool', 'ann'=>'resource', 'data'=>'resource', 'max_neurons'=>'int', 'neurons_between_reports'=>'int', 'desired_error'=>'float'],
'fann_cascadetrain_on_file' => ['bool', 'ann'=>'resource', 'filename'=>'string', 'max_neurons'=>'int', 'neurons_between_reports'=>'int', 'desired_error'=>'float'],
'fann_clear_scaling_params' => ['bool', 'ann'=>'resource'],
'fann_copy' => ['resource', 'ann'=>'resource'],
'fann_create_from_file' => ['resource', 'configuration_file'=>'string'],
'fann_create_shortcut' => ['reference', 'num_layers'=>'int', 'num_neurons1'=>'int', 'num_neurons2'=>'int', '...args='=>'int'],
'fann_create_shortcut_array' => ['resource', 'num_layers'=>'int', 'layers'=>'array'],
'fann_create_sparse' => ['resource|false', 'connection_rate'=>'float', 'num_layers'=>'int', 'num_neurons1'=>'int', 'num_neurons2'=>'int', '...args='=>'int'],
'fann_create_sparse_array' => ['resource|false', 'connection_rate'=>'float', 'num_layers'=>'int', 'layers'=>'array'],
'fann_create_standard' => ['resource', 'num_layers'=>'int', 'num_neurons1'=>'int', 'num_neurons2'=>'int', '...args='=>'int'],
'fann_create_standard_array' => ['resource', 'num_layers'=>'int', 'layers'=>'array'],
'fann_create_train' => ['resource', 'num_data'=>'int', 'num_input'=>'int', 'num_output'=>'int'],
'fann_create_train_from_callback' => ['resource', 'num_data'=>'int', 'num_input'=>'int', 'num_output'=>'int', 'user_function'=>'collable'],
'fann_descale_input' => ['bool', 'ann'=>'resource', 'input_vector'=>'array'],
'fann_descale_output' => ['bool', 'ann'=>'resource', 'output_vector'=>'array'],
'fann_descale_train' => ['bool', 'ann'=>'resource', 'train_data'=>'resource'],
'fann_destroy' => ['bool', 'ann'=>'resource'],
'fann_destroy_train' => ['bool', 'train_data'=>'resource'],
'fann_duplicate_train_data' => ['resource', 'data'=>'resource'],
'fann_get_activation_function' => ['int', 'ann'=>'resource', 'layer'=>'int', 'neuron'=>'int'],
'fann_get_activation_steepness' => ['float', 'ann'=>'resource', 'layer'=>'int', 'neuron'=>'int'],
'fann_get_bias_array' => ['array', 'ann'=>'resource'],
'fann_get_bit_fail' => ['int', 'ann'=>'resource'],
'fann_get_bit_fail_limit' => ['float', 'ann'=>'resource'],
'fann_get_cascade_activation_functions' => ['array', 'ann'=>'resource'],
'fann_get_cascade_activation_functions_count' => ['int', 'ann'=>'resource'],
'fann_get_cascade_activation_steepnesses' => ['array', 'ann'=>'resource'],
'fann_get_cascade_activation_steepnesses_count' => ['int', 'ann'=>'resource'],
'fann_get_cascade_candidate_change_fraction' => ['float', 'ann'=>'resource'],
'fann_get_cascade_candidate_limit' => ['float', 'ann'=>'resource'],
'fann_get_cascade_candidate_stagnation_epochs' => ['float', 'ann'=>'resource'],
'fann_get_cascade_max_cand_epochs' => ['int', 'ann'=>'resource'],
'fann_get_cascade_max_out_epochs' => ['int', 'ann'=>'resource'],
'fann_get_cascade_min_cand_epochs' => ['int', 'ann'=>'resource'],
'fann_get_cascade_min_out_epochs' => ['int', 'ann'=>'resource'],
'fann_get_cascade_num_candidate_groups' => ['int', 'ann'=>'resource'],
'fann_get_cascade_num_candidates' => ['int', 'ann'=>'resource'],
'fann_get_cascade_output_change_fraction' => ['float', 'ann'=>'resource'],
'fann_get_cascade_output_stagnation_epochs' => ['int', 'ann'=>'resource'],
'fann_get_cascade_weight_multiplier' => ['float', 'ann'=>'resource'],
'fann_get_connection_array' => ['array', 'ann'=>'resource'],
'fann_get_connection_rate' => ['float', 'ann'=>'resource'],
'fann_get_errno' => ['int', 'errdat'=>'resource'],
'fann_get_errstr' => ['string', 'errdat'=>'resource'],
'fann_get_layer_array' => ['array', 'ann'=>'resource'],
'fann_get_learning_momentum' => ['float', 'ann'=>'resource'],
'fann_get_learning_rate' => ['float', 'ann'=>'resource'],
'fann_get_MSE' => ['float', 'ann'=>'resource'],
'fann_get_network_type' => ['int', 'ann'=>'resource'],
'fann_get_num_input' => ['int', 'ann'=>'resource'],
'fann_get_num_layers' => ['int', 'ann'=>'resource'],
'fann_get_num_output' => ['int', 'ann'=>'resource'],
'fann_get_quickprop_decay' => ['float', 'ann'=>'resource'],
'fann_get_quickprop_mu' => ['float', 'ann'=>'resource'],
'fann_get_rprop_decrease_factor' => ['float', 'ann'=>'resource'],
'fann_get_rprop_delta_max' => ['float', 'ann'=>'resource'],
'fann_get_rprop_delta_min' => ['float', 'ann'=>'resource'],
'fann_get_rprop_delta_zero' => ['float|false', 'ann'=>'resource'],
'fann_get_rprop_increase_factor' => ['float', 'ann'=>'resource'],
'fann_get_sarprop_step_error_shift' => ['float', 'ann'=>'resource'],
'fann_get_sarprop_step_error_threshold_factor' => ['float', 'ann'=>'resource'],
'fann_get_sarprop_temperature' => ['float', 'ann'=>'resource'],
'fann_get_sarprop_weight_decay_shift' => ['float', 'ann'=>'resource'],
'fann_get_total_connections' => ['int', 'ann'=>'resource'],
'fann_get_total_neurons' => ['int', 'ann'=>'resource'],
'fann_get_train_error_function' => ['int', 'ann'=>'resource'],
'fann_get_train_stop_function' => ['int', 'ann'=>'resource'],
'fann_get_training_algorithm' => ['int', 'ann'=>'resource'],
'fann_init_weights' => ['bool', 'ann'=>'resource', 'train_data'=>'resource'],
'fann_length_train_data' => ['int', 'data'=>'resource'],
'fann_merge_train_data' => ['resource', 'data1'=>'resource', 'data2'=>'resource'],
'fann_num_input_train_data' => ['int', 'data'=>'resource'],
'fann_num_output_train_data' => ['int', 'data'=>'resource'],
'fann_print_error' => ['void', 'errdat'=>'string'],
'fann_randomize_weights' => ['bool', 'ann'=>'resource', 'min_weight'=>'float', 'max_weight'=>'float'],
'fann_read_train_from_file' => ['resource', 'filename'=>'string'],
'fann_reset_errno' => ['void', 'errdat'=>'resource'],
'fann_reset_errstr' => ['void', 'errdat'=>'resource'],
'fann_reset_MSE' => ['bool', 'ann'=>'string'],
'fann_run' => ['array', 'ann'=>'resource', 'input'=>'array'],
'fann_save' => ['bool', 'ann'=>'resource', 'configuration_file'=>'string'],
'fann_save_train' => ['bool', 'data'=>'resource', 'file_name'=>'string'],
'fann_scale_input' => ['bool', 'ann'=>'resource', 'input_vector'=>'array'],
'fann_scale_input_train_data' => ['bool', 'train_data'=>'resource', 'new_min'=>'float', 'new_max'=>'float'],
'fann_scale_output' => ['bool', 'ann'=>'resource', 'output_vector'=>'array'],
'fann_scale_output_train_data' => ['bool', 'train_data'=>'resource', 'new_min'=>'float', 'new_max'=>'float'],
'fann_scale_train' => ['bool', 'ann'=>'resource', 'train_data'=>'resource'],
'fann_scale_train_data' => ['bool', 'train_data'=>'resource', 'new_min'=>'float', 'new_max'=>'float'],
'fann_set_activation_function' => ['bool', 'ann'=>'resource', 'activation_function'=>'int', 'layer'=>'int', 'neuron'=>'int'],
'fann_set_activation_function_hidden' => ['bool', 'ann'=>'resource', 'activation_function'=>'int'],
'fann_set_activation_function_layer' => ['bool', 'ann'=>'resource', 'activation_function'=>'int', 'layer'=>'int'],
'fann_set_activation_function_output' => ['bool', 'ann'=>'resource', 'activation_function'=>'int'],
'fann_set_activation_steepness' => ['bool', 'ann'=>'resource', 'activation_steepness'=>'float', 'layer'=>'int', 'neuron'=>'int'],
'fann_set_activation_steepness_hidden' => ['bool', 'ann'=>'resource', 'activation_steepness'=>'float'],
'fann_set_activation_steepness_layer' => ['bool', 'ann'=>'resource', 'activation_steepness'=>'float', 'layer'=>'int'],
'fann_set_activation_steepness_output' => ['bool', 'ann'=>'resource', 'activation_steepness'=>'float'],
'fann_set_bit_fail_limit' => ['bool', 'ann'=>'resource', 'bit_fail_limit'=>'float'],
'fann_set_callback' => ['bool', 'ann'=>'resource', 'callback'=>'collable'],
'fann_set_cascade_activation_functions' => ['bool', 'ann'=>'resource', 'cascade_activation_functions'=>'array'],
'fann_set_cascade_activation_steepnesses' => ['bool', 'ann'=>'resource', 'cascade_activation_steepnesses_count'=>'array'],
'fann_set_cascade_candidate_change_fraction' => ['bool', 'ann'=>'resource', 'cascade_candidate_change_fraction'=>'float'],
'fann_set_cascade_candidate_limit' => ['bool', 'ann'=>'resource', 'cascade_candidate_limit'=>'float'],
'fann_set_cascade_candidate_stagnation_epochs' => ['bool', 'ann'=>'resource', 'cascade_candidate_stagnation_epochs'=>'int'],
'fann_set_cascade_max_cand_epochs' => ['bool', 'ann'=>'resource', 'cascade_max_cand_epochs'=>'int'],
'fann_set_cascade_max_out_epochs' => ['bool', 'ann'=>'resource', 'cascade_max_out_epochs'=>'int'],
'fann_set_cascade_min_cand_epochs' => ['bool', 'ann'=>'resource', 'cascade_min_cand_epochs'=>'int'],
'fann_set_cascade_min_out_epochs' => ['bool', 'ann'=>'resource', 'cascade_min_out_epochs'=>'int'],
'fann_set_cascade_num_candidate_groups' => ['bool', 'ann'=>'resource', 'cascade_num_candidate_groups'=>'int'],
'fann_set_cascade_output_change_fraction' => ['bool', 'ann'=>'resource', 'cascade_output_change_fraction'=>'float'],
'fann_set_cascade_output_stagnation_epochs' => ['bool', 'ann'=>'resource', 'cascade_output_stagnation_epochs'=>'int'],
'fann_set_cascade_weight_multiplier' => ['bool', 'ann'=>'resource', 'cascade_weight_multiplier'=>'float'],
'fann_set_error_log' => ['void', 'errdat'=>'resource', 'log_file'=>'string'],
'fann_set_input_scaling_params' => ['bool', 'ann'=>'resource', 'train_data'=>'resource', 'new_input_min'=>'float', 'new_input_max'=>'float'],
'fann_set_learning_momentum' => ['bool', 'ann'=>'resource', 'learning_momentum'=>'float'],
'fann_set_learning_rate' => ['bool', 'ann'=>'resource', 'learning_rate'=>'float'],
'fann_set_output_scaling_params' => ['bool', 'ann'=>'resource', 'train_data'=>'resource', 'new_output_min'=>'float', 'new_output_max'=>'float'],
'fann_set_quickprop_decay' => ['bool', 'ann'=>'resource', 'quickprop_decay'=>'float'],
'fann_set_quickprop_mu' => ['bool', 'ann'=>'resource', 'quickprop_mu'=>'float'],
'fann_set_rprop_decrease_factor' => ['bool', 'ann'=>'resource', 'rprop_decrease_factor'=>'float'],
'fann_set_rprop_delta_max' => ['bool', 'ann'=>'resource', 'rprop_delta_max'=>'float'],
'fann_set_rprop_delta_min' => ['bool', 'ann'=>'resource', 'rprop_delta_min'=>'float'],
'fann_set_rprop_delta_zero' => ['bool', 'ann'=>'resource', 'rprop_delta_zero'=>'float'],
'fann_set_rprop_increase_factor' => ['bool', 'ann'=>'resource', 'rprop_increase_factor'=>'float'],
'fann_set_sarprop_step_error_shift' => ['bool', 'ann'=>'resource', 'sarprop_step_error_shift'=>'float'],
'fann_set_sarprop_step_error_threshold_factor' => ['bool', 'ann'=>'resource', 'sarprop_step_error_threshold_factor'=>'float'],
'fann_set_sarprop_temperature' => ['bool', 'ann'=>'resource', 'sarprop_temperature'=>'float'],
'fann_set_sarprop_weight_decay_shift' => ['bool', 'ann'=>'resource', 'sarprop_weight_decay_shift'=>'float'],
'fann_set_scaling_params' => ['bool', 'ann'=>'resource', 'train_data'=>'resource', 'new_input_min'=>'float', 'new_input_max'=>'float', 'new_output_min'=>'float', 'new_output_max'=>'float'],
'fann_set_train_error_function' => ['bool', 'ann'=>'resource', 'error_function'=>'int'],
'fann_set_train_stop_function' => ['bool', 'ann'=>'resource', 'stop_function'=>'int'],
'fann_set_training_algorithm' => ['bool', 'ann'=>'resource', 'training_algorithm'=>'int'],
'fann_set_weight' => ['bool', 'ann'=>'resource', 'from_neuron'=>'int', 'to_neuron'=>'int', 'weight'=>'float'],
'fann_set_weight_array' => ['bool', 'ann'=>'resource', 'connections'=>'array'],
'fann_shuffle_train_data' => ['bool', 'train_data'=>'resource'],
'fann_subset_train_data' => ['resource', 'data'=>'resource', 'pos'=>'int', 'length'=>'int'],
'fann_test' => ['bool', 'ann'=>'resource', 'input'=>'array', 'desired_output'=>'array'],
'fann_test_data' => ['float', 'ann'=>'resource', 'data'=>'resource'],
'fann_train' => ['bool', 'ann'=>'resource', 'input'=>'array', 'desired_output'=>'array'],
'fann_train_epoch' => ['float', 'ann'=>'resource', 'data'=>'resource'],
'fann_train_on_data' => ['bool', 'ann'=>'resource', 'data'=>'resource', 'max_epochs'=>'int', 'epochs_between_reports'=>'int', 'desired_error'=>'float'],
'fann_train_on_file' => ['bool', 'ann'=>'resource', 'filename'=>'string', 'max_epochs'=>'int', 'epochs_between_reports'=>'int', 'desired_error'=>'float'],
'FANNConnection::__construct' => ['void', 'from_neuron'=>'int', 'to_neuron'=>'int', 'weight'=>'float'],
'FANNConnection::getFromNeuron' => ['int'],
'FANNConnection::getToNeuron' => ['int'],
'FANNConnection::getWeight' => ['void'],
'FANNConnection::setWeight' => ['bool', 'weight'=>'float'],
'fastcgi_finish_request' => ['bool'],
'fbsql_affected_rows' => ['int', 'link_identifier='=>'?resource'],
'fbsql_autocommit' => ['bool', 'link_identifier'=>'resource', 'onoff='=>'bool'],
'fbsql_blob_size' => ['int', 'blob_handle'=>'string', 'link_identifier='=>'?resource'],
'fbsql_change_user' => ['bool', 'user'=>'string', 'password'=>'string', 'database='=>'string', 'link_identifier='=>'?resource'],
'fbsql_clob_size' => ['int', 'clob_handle'=>'string', 'link_identifier='=>'?resource'],
'fbsql_close' => ['bool', 'link_identifier='=>'?resource'],
'fbsql_commit' => ['bool', 'link_identifier='=>'?resource'],
'fbsql_connect' => ['resource', 'hostname='=>'string', 'username='=>'string', 'password='=>'string'],
'fbsql_create_blob' => ['string', 'blob_data'=>'string', 'link_identifier='=>'?resource'],
'fbsql_create_clob' => ['string', 'clob_data'=>'string', 'link_identifier='=>'?resource'],
'fbsql_create_db' => ['bool', 'database_name'=>'string', 'link_identifier='=>'?resource', 'database_options='=>'string'],
'fbsql_data_seek' => ['bool', 'result'=>'resource', 'row_number'=>'int'],
'fbsql_database' => ['string', 'link_identifier'=>'resource', 'database='=>'string'],
'fbsql_database_password' => ['string', 'link_identifier'=>'resource', 'database_password='=>'string'],
'fbsql_db_query' => ['resource', 'database'=>'string', 'query'=>'string', 'link_identifier='=>'?resource'],
'fbsql_db_status' => ['int', 'database_name'=>'string', 'link_identifier='=>'?resource'],
'fbsql_drop_db' => ['bool', 'database_name'=>'string', 'link_identifier='=>'?resource'],
'fbsql_errno' => ['int', 'link_identifier='=>'?resource'],
'fbsql_error' => ['string', 'link_identifier='=>'?resource'],
'fbsql_fetch_array' => ['array', 'result'=>'resource', 'result_type='=>'int'],
'fbsql_fetch_assoc' => ['array', 'result'=>'resource'],
'fbsql_fetch_field' => ['object', 'result'=>'resource', 'field_offset='=>'int'],
'fbsql_fetch_lengths' => ['array', 'result'=>'resource'],
'fbsql_fetch_object' => ['object', 'result'=>'resource'],
'fbsql_fetch_row' => ['array', 'result'=>'resource'],
'fbsql_field_flags' => ['string', 'result'=>'resource', 'field_offset='=>'int'],
'fbsql_field_len' => ['int', 'result'=>'resource', 'field_offset='=>'int'],
'fbsql_field_name' => ['string', 'result'=>'resource', 'field_index='=>'int'],
'fbsql_field_seek' => ['bool', 'result'=>'resource', 'field_offset='=>'int'],
'fbsql_field_table' => ['string', 'result'=>'resource', 'field_offset='=>'int'],
'fbsql_field_type' => ['string', 'result'=>'resource', 'field_offset='=>'int'],
'fbsql_free_result' => ['bool', 'result'=>'resource'],
'fbsql_get_autostart_info' => ['array', 'link_identifier='=>'?resource'],
'fbsql_hostname' => ['string', 'link_identifier'=>'resource', 'host_name='=>'string'],
'fbsql_insert_id' => ['int', 'link_identifier='=>'?resource'],
'fbsql_list_dbs' => ['resource', 'link_identifier='=>'?resource'],
'fbsql_list_fields' => ['resource', 'database_name'=>'string', 'table_name'=>'string', 'link_identifier='=>'?resource'],
'fbsql_list_tables' => ['resource', 'database'=>'string', 'link_identifier='=>'?resource'],
'fbsql_next_result' => ['bool', 'result'=>'resource'],
'fbsql_num_fields' => ['int', 'result'=>'resource'],
'fbsql_num_rows' => ['int', 'result'=>'resource'],
'fbsql_password' => ['string', 'link_identifier'=>'resource', 'password='=>'string'],
'fbsql_pconnect' => ['resource', 'hostname='=>'string', 'username='=>'string', 'password='=>'string'],
'fbsql_query' => ['resource', 'query'=>'string', 'link_identifier='=>'?resource', 'batch_size='=>'int'],
'fbsql_read_blob' => ['string', 'blob_handle'=>'string', 'link_identifier='=>'?resource'],
'fbsql_read_clob' => ['string', 'clob_handle'=>'string', 'link_identifier='=>'?resource'],
'fbsql_result' => ['mixed', 'result'=>'resource', 'row='=>'int', 'field='=>'mixed'],
'fbsql_rollback' => ['bool', 'link_identifier='=>'?resource'],
'fbsql_rows_fetched' => ['int', 'result'=>'resource'],
'fbsql_select_db' => ['bool', 'database_name='=>'string', 'link_identifier='=>'?resource'],
'fbsql_set_characterset' => ['void', 'link_identifier'=>'resource', 'characterset'=>'int', 'in_out_both='=>'int'],
'fbsql_set_lob_mode' => ['bool', 'result'=>'resource', 'lob_mode'=>'int'],
'fbsql_set_password' => ['bool', 'link_identifier'=>'resource', 'user'=>'string', 'password'=>'string', 'old_password'=>'string'],
'fbsql_set_transaction' => ['void', 'link_identifier'=>'resource', 'locking'=>'int', 'isolation'=>'int'],
'fbsql_start_db' => ['bool', 'database_name'=>'string', 'link_identifier='=>'?resource', 'database_options='=>'string'],
'fbsql_stop_db' => ['bool', 'database_name'=>'string', 'link_identifier='=>'?resource'],
'fbsql_table_name' => ['string', 'result'=>'resource', 'index'=>'int'],
'fbsql_username' => ['string', 'link_identifier'=>'resource', 'username='=>'string'],
'fbsql_warnings' => ['bool', 'onoff='=>'bool'],
'fclose' => ['bool', 'fp'=>'resource'],
'fdf_add_doc_javascript' => ['bool', 'fdf_document'=>'resource', 'script_name'=>'string', 'script_code'=>'string'],
'fdf_add_template' => ['bool', 'fdf_document'=>'resource', 'newpage'=>'int', 'filename'=>'string', 'template'=>'string', 'rename'=>'int'],
'fdf_close' => ['void', 'fdf_document'=>'resource'],
'fdf_create' => ['resource'],
'fdf_enum_values' => ['bool', 'fdf_document'=>'resource', 'function'=>'callable', 'userdata='=>'mixed'],
'fdf_errno' => ['int'],
'fdf_error' => ['string', 'error_code='=>'int'],
'fdf_get_ap' => ['bool', 'fdf_document'=>'resource', 'field'=>'string', 'face'=>'int', 'filename'=>'string'],
'fdf_get_attachment' => ['array', 'fdf_document'=>'resource', 'fieldname'=>'string', 'savepath'=>'string'],
'fdf_get_encoding' => ['string', 'fdf_document'=>'resource'],
'fdf_get_file' => ['string', 'fdf_document'=>'resource'],
'fdf_get_flags' => ['int', 'fdf_document'=>'resource', 'fieldname'=>'string', 'whichflags'=>'int'],
'fdf_get_opt' => ['mixed', 'fdf_document'=>'resource', 'fieldname'=>'string', 'element='=>'int'],
'fdf_get_status' => ['string', 'fdf_document'=>'resource'],
'fdf_get_value' => ['mixed', 'fdf_document'=>'resource', 'fieldname'=>'string', 'which='=>'int'],
'fdf_get_version' => ['string', 'fdf_document='=>'resource'],
'fdf_header' => ['void'],
'fdf_next_field_name' => ['string', 'fdf_document'=>'resource', 'fieldname='=>'string'],
'fdf_open' => ['resource', 'filename'=>'string'],
'fdf_open_string' => ['resource', 'fdf_data'=>'string'],
'fdf_remove_item' => ['bool', 'fdf_document'=>'resource', 'fieldname'=>'string', 'item'=>'int'],
'fdf_save' => ['bool', 'fdf_document'=>'resource', 'filename='=>'string'],
'fdf_save_string' => ['string', 'fdf_document'=>'resource'],
'fdf_set_ap' => ['bool', 'fdf_document'=>'resource', 'field_name'=>'string', 'face'=>'int', 'filename'=>'string', 'page_number'=>'int'],
'fdf_set_encoding' => ['bool', 'fdf_document'=>'resource', 'encoding'=>'string'],
'fdf_set_file' => ['bool', 'fdf_document'=>'resource', 'url'=>'string', 'target_frame='=>'string'],
'fdf_set_flags' => ['bool', 'fdf_document'=>'resource', 'fieldname'=>'string', 'whichflags'=>'int', 'newflags'=>'int'],
'fdf_set_javascript_action' => ['bool', 'fdf_document'=>'resource', 'fieldname'=>'string', 'trigger'=>'int', 'script'=>'string'],
'fdf_set_on_import_javascript' => ['bool', 'fdf_document'=>'resource', 'script'=>'string', 'before_data_import'=>'bool'],
'fdf_set_opt' => ['bool', 'fdf_document'=>'resource', 'fieldname'=>'string', 'element'=>'int', 'str1'=>'string', 'str2'=>'string'],
'fdf_set_status' => ['bool', 'fdf_document'=>'resource', 'status'=>'string'],
'fdf_set_submit_form_action' => ['bool', 'fdf_document'=>'resource', 'fieldname'=>'string', 'trigger'=>'int', 'script'=>'string', 'flags'=>'int'],
'fdf_set_target_frame' => ['bool', 'fdf_document'=>'resource', 'frame_name'=>'string'],
'fdf_set_value' => ['bool', 'fdf_document'=>'resource', 'fieldname'=>'string', 'value'=>'mixed', 'isname='=>'int'],
'fdf_set_version' => ['bool', 'fdf_document'=>'resource', 'version'=>'string'],
'feof' => ['bool', 'fp'=>'resource'],
'fflush' => ['bool', 'fp'=>'resource'],
'ffmpeg_animated_gif::__construct' => ['void', 'output_file_path'=>'string', 'width'=>'int', 'height'=>'int', 'frame_rate'=>'int', 'loop_count='=>'int'],
'ffmpeg_animated_gif::addFrame' => ['', 'frame_to_add'=>'ffmpeg_frame'],
'ffmpeg_frame::__construct' => ['void', 'gd_image'=>'resource'],
'ffmpeg_frame::crop' => ['', 'crop_top'=>'int', 'crop_bottom='=>'int', 'crop_left='=>'int', 'crop_right='=>'int'],
'ffmpeg_frame::getHeight' => ['int'],
'ffmpeg_frame::getPresentationTimestamp' => ['int'],
'ffmpeg_frame::getPTS' => ['int'],
'ffmpeg_frame::getWidth' => ['int'],
'ffmpeg_frame::resize' => ['', 'width'=>'int', 'height'=>'int', 'crop_top='=>'int', 'crop_bottom='=>'int', 'crop_left='=>'int', 'crop_right='=>'int'],
'ffmpeg_frame::toGDImage' => ['resource'],
'ffmpeg_movie::__construct' => ['void', 'path_to_media'=>'string', 'persistent'=>'bool'],
'ffmpeg_movie::getArtist' => ['string'],
'ffmpeg_movie::getAudioBitRate' => ['int'],
'ffmpeg_movie::getAudioChannels' => ['int'],
'ffmpeg_movie::getAudioCodec' => ['string'],
'ffmpeg_movie::getAudioSampleRate' => ['int'],
'ffmpeg_movie::getAuthor' => ['string'],
'ffmpeg_movie::getBitRate' => ['int'],
'ffmpeg_movie::getComment' => ['string'],
'ffmpeg_movie::getCopyright' => ['string'],
'ffmpeg_movie::getDuration' => ['int'],
'ffmpeg_movie::getFilename' => ['string'],
'ffmpeg_movie::getFrame' => ['ffmpeg_frame', 'framenumber'=>'int'],
'ffmpeg_movie::getFrameCount' => ['int'],
'ffmpeg_movie::getFrameHeight' => ['int'],
'ffmpeg_movie::getFrameNumber' => ['int'],
'ffmpeg_movie::getFrameRate' => ['int'],
'ffmpeg_movie::getFrameWidth' => ['int'],
'ffmpeg_movie::getGenre' => ['string'],
'ffmpeg_movie::getNextKeyFrame' => ['ffmpeg_frame'],
'ffmpeg_movie::getPixelFormat' => [''],
'ffmpeg_movie::getTitle' => ['string'],
'ffmpeg_movie::getTrackNumber' => ['int|string'],
'ffmpeg_movie::getVideoBitRate' => ['int'],
'ffmpeg_movie::getVideoCodec' => ['string'],
'ffmpeg_movie::getYear' => ['int|string'],
'ffmpeg_movie::hasAudio' => ['bool'],
'ffmpeg_movie::hasVideo' => ['bool'],
'fgetc' => ['string|false', 'fp'=>'resource'],
'fgetcsv' => ['?array|?false', 'fp'=>'resource', 'length='=>'int', 'delimiter='=>'string', 'enclosure='=>'string', 'escape='=>'string'],
'fgets' => ['string|false', 'fp'=>'resource', 'length='=>'int'],
'fgetss' => ['string|false', 'fp'=>'resource', 'length='=>'int', 'allowable_tags='=>'string'],
'file' => ['array|false', 'filename'=>'string', 'flags='=>'int', 'context='=>'resource'],
'file_exists' => ['bool', 'filename'=>'string'],
'file_get_contents' => ['string|false', 'filename'=>'string', 'use_include_path='=>'bool', 'context='=>'?resource', 'offset='=>'int', 'maxlen='=>'int'],
'file_put_contents' => ['int|false', 'file'=>'string', 'data'=>'mixed', 'flags='=>'int', 'context='=>'resource'],
'fileatime' => ['int|false', 'filename'=>'string'],
'filectime' => ['int|false', 'filename'=>'string'],
'filegroup' => ['int|false', 'filename'=>'string'],
'fileinode' => ['int|false', 'filename'=>'string'],
'filemtime' => ['int|false', 'filename'=>'string'],
'fileowner' => ['int|false', 'filename'=>'string'],
'fileperms' => ['int|false', 'filename'=>'string'],
'filepro' => ['bool', 'directory'=>'string'],
'filepro_fieldcount' => ['int'],
'filepro_fieldname' => ['string', 'field_number'=>'int'],
'filepro_fieldtype' => ['string', 'field_number'=>'int'],
'filepro_fieldwidth' => ['int', 'field_number'=>'int'],
'filepro_retrieve' => ['string', 'row_number'=>'int', 'field_number'=>'int'],
'filepro_rowcount' => ['int'],
'filesize' => ['int|false', 'filename'=>'string'],
'FilesystemIterator::__construct' => ['void', 'path'=>'string', 'flags='=>'int'],
'FilesystemIterator::current' => ['string|SplFileInfo'],
'FilesystemIterator::getFlags' => ['int'],
'FilesystemIterator::key' => ['string'],
'FilesystemIterator::next' => ['void'],
'FilesystemIterator::rewind' => ['void'],
'FilesystemIterator::setFlags' => ['void', 'flags='=>'int'],
'filetype' => ['string|false', 'filename'=>'string'],
'filter_has_var' => ['bool', 'type'=>'int', 'variable_name'=>'string'],
'filter_id' => ['int|false', 'filtername'=>'string'],
'filter_input' => ['mixed', 'type'=>'int', 'variable_name'=>'string', 'filter='=>'int', 'options='=>'array|int'],
'filter_input_array' => ['mixed', 'type'=>'int', 'definition='=>'int|array', 'add_empty='=>'bool'],
'filter_list' => ['array'],
'filter_var' => ['mixed', 'variable'=>'mixed', 'filter='=>'int', 'options='=>'mixed'],
'filter_var_array' => ['mixed', 'data'=>'array', 'definition='=>'mixed', 'add_empty='=>'bool'],
'FilterIterator::__construct' => ['void', 'it'=>'iterator'],
'FilterIterator::accept' => ['bool'],
'FilterIterator::current' => ['mixed'],
'FilterIterator::getInnerIterator' => ['Iterator'],
'FilterIterator::key' => ['mixed'],
'FilterIterator::next' => ['void'],
'FilterIterator::rewind' => ['void'],
'FilterIterator::valid' => ['bool'],
'finfo::__construct' => ['void', 'options='=>'int', 'magic_file='=>'string'],
'finfo::buffer' => ['string', 'string'=>'string', 'options='=>'int', 'context='=>'resource'],
'finfo::file' => ['string', 'file_name'=>'string', 'options='=>'int', 'context='=>'resource'],
'finfo::set_flags' => ['bool', 'options'=>'int'],
'finfo_buffer' => ['string', 'finfo'=>'resource', 'string'=>'string', 'options='=>'int', 'context='=>'resource'],
'finfo_close' => ['bool', 'finfo'=>'resource'],
'finfo_file' => ['string', 'finfo'=>'resource', 'file_name'=>'string', 'options='=>'int', 'context='=>'resource'],
'finfo_open' => ['resource', 'options='=>'int', 'arg='=>'string'],
'finfo_set_flags' => ['bool', 'finfo'=>'resource', 'options'=>'int'],
'floatval' => ['float', 'var'=>'mixed'],
'flock' => ['bool', 'fp'=>'resource', 'operation'=>'int', '&w_wouldblock='=>'int'],
'floor' => ['float', 'number'=>'float'],
'flush' => ['void'],
'fmod' => ['float', 'x'=>'float', 'y'=>'float'],
'fnmatch' => ['bool', 'pattern'=>'string', 'filename'=>'string', 'flags='=>'int'],
'fopen' => ['resource|false', 'filename'=>'string', 'mode'=>'string', 'use_include_path='=>'bool', 'context='=>'resource'],
'forward_static_call' => ['mixed', 'function'=>'callable', '...parameters='=>'mixed'],
'forward_static_call_array' => ['mixed', 'function'=>'callable', 'parameters'=>'array'],
'fpassthru' => ['int', 'fp'=>'resource'],
'fprintf' => ['int', 'stream'=>'resource', 'format'=>'string', '...args='=>'string|int|float'],
'fputcsv' => ['int|false', 'fp'=>'resource', 'fields'=>'array', 'delimiter='=>'string', 'enclosure='=>'string', 'escape_char='=>'string'],
'fputs' => ['int|false', 'fp'=>'resource', 'str'=>'string', 'length='=>'int'],
'fread' => ['string|false', 'fp'=>'resource', 'length'=>'int'],
'frenchtojd' => ['int', 'month'=>'int', 'day'=>'int', 'year'=>'int'],
'fribidi_log2vis' => ['string', 'str'=>'string', 'direction'=>'string', 'charset'=>'int'],
'fscanf' => ['array|int', 'stream'=>'resource', 'format'=>'string', '&...w_vars='=>'string|int|float|null'],
'fseek' => ['int', 'fp'=>'resource', 'offset'=>'int', 'whence='=>'int'],
'fsockopen' => ['resource|false', 'hostname'=>'string', 'port='=>'int', '&w_errno='=>'int', '&w_errstr='=>'string', 'timeout='=>'float'],
'fstat' => ['array|false', 'fp'=>'resource'],
'ftell' => ['int|false', 'fp'=>'resource'],
'ftok' => ['int', 'pathname'=>'string', 'proj'=>'string'],
'ftp_alloc' => ['bool', 'stream'=>'resource', 'size'=>'int', 'response='=>'string'],
'ftp_append' => ['bool', 'ftp'=>'resource', 'remote_file'=>'string', 'local_file'=>'string', 'mode='=>'int'],
'ftp_cdup' => ['bool', 'stream'=>'resource'],
'ftp_chdir' => ['bool', 'stream'=>'resource', 'directory'=>'string'],
'ftp_chmod' => ['int|false', 'stream'=>'resource', 'mode'=>'int', 'filename'=>'string'],
'ftp_close' => ['bool', 'stream'=>'resource'],
'ftp_connect' => ['resource|false', 'host'=>'string', 'port='=>'int', 'timeout='=>'int'],
'ftp_delete' => ['bool', 'stream'=>'resource', 'file'=>'string'],
'ftp_exec' => ['bool', 'stream'=>'resource', 'command'=>'string'],
'ftp_fget' => ['bool', 'stream'=>'resource', 'fp'=>'resource', 'remote_file'=>'string', 'mode'=>'int', 'resumepos='=>'int'],
'ftp_fput' => ['bool', 'stream'=>'resource', 'remote_file'=>'string', 'fp'=>'resource', 'mode'=>'int', 'startpos='=>'int'],
'ftp_get' => ['bool', 'stream'=>'resource', 'local_file'=>'string', 'remote_file'=>'string', 'mode'=>'int', 'resume_pos='=>'int'],
'ftp_get_option' => ['mixed', 'stream'=>'resource', 'option'=>'int'],
'ftp_login' => ['bool', 'stream'=>'resource', 'username'=>'string', 'password'=>'string'],
'ftp_mdtm' => ['int', 'stream'=>'resource', 'filename'=>'string'],
'ftp_mkdir' => ['string|false', 'stream'=>'resource', 'directory'=>'string'],
'ftp_mlsd' => ['array', 'ftp_stream'=>'resource', 'directory'=>'string'],
'ftp_nb_continue' => ['int', 'stream'=>'resource'],
'ftp_nb_fget' => ['int', 'stream'=>'resource', 'fp'=>'resource', 'remote_file'=>'string', 'mode'=>'int', 'resumepos='=>'int'],
'ftp_nb_fput' => ['int', 'stream'=>'resource', 'remote_file'=>'string', 'fp'=>'resource', 'mode'=>'int', 'startpos='=>'int'],
'ftp_nb_get' => ['int', 'stream'=>'resource', 'local_file'=>'string', 'remote_file'=>'string', 'mode'=>'int', 'resume_pos='=>'int'],
'ftp_nb_put' => ['int', 'stream'=>'resource', 'remote_file'=>'string', 'local_file'=>'string', 'mode'=>'int', 'startpos='=>'int'],
'ftp_nlist' => ['array|false', 'stream'=>'resource', 'directory'=>'string'],
'ftp_pasv' => ['bool', 'stream'=>'resource', 'pasv'=>'bool'],
'ftp_put' => ['bool', 'stream'=>'resource', 'remote_file'=>'string', 'local_file'=>'string', 'mode'=>'int', 'startpos='=>'int'],
'ftp_pwd' => ['string|false', 'stream'=>'resource'],
'ftp_raw' => ['array', 'stream'=>'resource', 'command'=>'string'],
'ftp_rawlist' => ['array|false', 'stream'=>'resource', 'directory'=>'string', 'recursive='=>'bool'],
'ftp_rename' => ['bool', 'stream'=>'resource', 'src'=>'string', 'dest'=>'string'],
'ftp_rmdir' => ['bool', 'stream'=>'resource', 'directory'=>'string'],
'ftp_set_option' => ['bool', 'stream'=>'resource', 'option'=>'int', 'value'=>'mixed'],
'ftp_site' => ['bool', 'stream'=>'resource', 'cmd'=>'string'],
'ftp_size' => ['int', 'stream'=>'resource', 'filename'=>'string'],
'ftp_ssl_connect' => ['resource|false', 'host'=>'string', 'port='=>'int', 'timeout='=>'int'],
'ftp_systype' => ['string|false', 'stream'=>'resource'],
'ftruncate' => ['bool', 'fp'=>'resource', 'size'=>'int'],
'func_get_arg' => ['mixed', 'arg_num'=>'int'],
'func_get_args' => ['array'],
'func_num_args' => ['int'],
'function_exists' => ['bool', 'function_name'=>'string'],
'fwrite' => ['int|false', 'fp'=>'resource', 'str'=>'string', 'length='=>'int'],
'gc_collect_cycles' => ['int'],
'gc_disable' => ['void'],
'gc_enable' => ['void'],
'gc_enabled' => ['bool'],
'gc_mem_caches' => ['int'],
'gd_info' => ['array'],
'gearman_bugreport' => [''],
'gearman_client_add_options' => ['', 'client_object'=>'', 'option'=>''],
'gearman_client_add_server' => ['', 'client_object'=>'', 'host'=>'', 'port'=>''],
'gearman_client_add_servers' => ['', 'client_object'=>'', 'servers'=>''],
'gearman_client_add_task' => ['', 'client_object'=>'', 'function_name'=>'', 'workload'=>'', 'context'=>'', 'unique'=>''],
'gearman_client_add_task_background' => ['', 'client_object'=>'', 'function_name'=>'', 'workload'=>'', 'context'=>'', 'unique'=>''],
'gearman_client_add_task_high' => ['', 'client_object'=>'', 'function_name'=>'', 'workload'=>'', 'context'=>'', 'unique'=>''],
'gearman_client_add_task_high_background' => ['', 'client_object'=>'', 'function_name'=>'', 'workload'=>'', 'context'=>'', 'unique'=>''],
'gearman_client_add_task_low' => ['', 'client_object'=>'', 'function_name'=>'', 'workload'=>'', 'context'=>'', 'unique'=>''],
'gearman_client_add_task_low_background' => ['', 'client_object'=>'', 'function_name'=>'', 'workload'=>'', 'context'=>'', 'unique'=>''],
'gearman_client_add_task_status' => ['', 'client_object'=>'', 'job_handle'=>'', 'context'=>''],
'gearman_client_clear_fn' => ['', 'client_object'=>''],
'gearman_client_clone' => ['', 'client_object'=>''],
'gearman_client_context' => ['', 'client_object'=>''],
'gearman_client_create' => ['', 'client_object'=>''],
'gearman_client_do' => ['', 'client_object'=>'', 'function_name'=>'', 'workload'=>'', 'unique'=>''],
'gearman_client_do_background' => ['', 'client_object'=>'', 'function_name'=>'', 'workload'=>'', 'unique'=>''],
'gearman_client_do_high' => ['', 'client_object'=>'', 'function_name'=>'', 'workload'=>'', 'unique'=>''],
'gearman_client_do_high_background' => ['', 'client_object'=>'', 'function_name'=>'', 'workload'=>'', 'unique'=>''],
'gearman_client_do_job_handle' => ['', 'client_object'=>''],
'gearman_client_do_low' => ['', 'client_object'=>'', 'function_name'=>'', 'workload'=>'', 'unique'=>''],
'gearman_client_do_low_background' => ['', 'client_object'=>'', 'function_name'=>'', 'workload'=>'', 'unique'=>''],
'gearman_client_do_normal' => ['', 'client_object'=>'', 'function_name'=>'string', 'workload'=>'string', 'unique'=>'string'],
'gearman_client_do_status' => ['', 'client_object'=>''],
'gearman_client_echo' => ['', 'client_object'=>'', 'workload'=>''],
'gearman_client_errno' => ['', 'client_object'=>''],
'gearman_client_error' => ['', 'client_object'=>''],
'gearman_client_job_status' => ['', 'client_object'=>'', 'job_handle'=>''],
'gearman_client_options' => ['', 'client_object'=>''],
'gearman_client_remove_options' => ['', 'client_object'=>'', 'option'=>''],
'gearman_client_return_code' => ['', 'client_object'=>''],
'gearman_client_run_tasks' => ['', 'data'=>''],
'gearman_client_set_complete_fn' => ['', 'client_object'=>'', 'callback'=>''],
'gearman_client_set_context' => ['', 'client_object'=>'', 'context'=>''],
'gearman_client_set_created_fn' => ['', 'client_object'=>'', 'callback'=>''],
'gearman_client_set_data_fn' => ['', 'client_object'=>'', 'callback'=>''],
'gearman_client_set_exception_fn' => ['', 'client_object'=>'', 'callback'=>''],
'gearman_client_set_fail_fn' => ['', 'client_object'=>'', 'callback'=>''],
'gearman_client_set_options' => ['', 'client_object'=>'', 'option'=>''],
'gearman_client_set_status_fn' => ['', 'client_object'=>'', 'callback'=>''],
'gearman_client_set_timeout' => ['', 'client_object'=>'', 'timeout'=>''],
'gearman_client_set_warning_fn' => ['', 'client_object'=>'', 'callback'=>''],
'gearman_client_set_workload_fn' => ['', 'client_object'=>'', 'callback'=>''],
'gearman_client_timeout' => ['', 'client_object'=>''],
'gearman_client_wait' => ['', 'client_object'=>''],
'gearman_job_function_name' => ['', 'job_object'=>''],
'gearman_job_handle' => ['string'],
'gearman_job_return_code' => ['', 'job_object'=>''],
'gearman_job_send_complete' => ['', 'job_object'=>'', 'result'=>''],
'gearman_job_send_data' => ['', 'job_object'=>'', 'data'=>''],
'gearman_job_send_exception' => ['', 'job_object'=>'', 'exception'=>''],
'gearman_job_send_fail' => ['', 'job_object'=>''],
'gearman_job_send_status' => ['', 'job_object'=>'', 'numerator'=>'', 'denominator'=>''],
'gearman_job_send_warning' => ['', 'job_object'=>'', 'warning'=>''],
'gearman_job_status' => ['array', 'job_handle'=>'string'],
'gearman_job_unique' => ['', 'job_object'=>''],
'gearman_job_workload' => ['', 'job_object'=>''],
'gearman_job_workload_size' => ['', 'job_object'=>''],
'gearman_task_data' => ['', 'task_object'=>''],
'gearman_task_data_size' => ['', 'task_object'=>''],
'gearman_task_denominator' => ['', 'task_object'=>''],
'gearman_task_function_name' => ['', 'task_object'=>''],
'gearman_task_is_known' => ['', 'task_object'=>''],
'gearman_task_is_running' => ['', 'task_object'=>''],
'gearman_task_job_handle' => ['', 'task_object'=>''],
'gearman_task_numerator' => ['', 'task_object'=>''],
'gearman_task_recv_data' => ['', 'task_object'=>'', 'data_len'=>''],
'gearman_task_return_code' => ['', 'task_object'=>''],
'gearman_task_send_workload' => ['', 'task_object'=>'', 'data'=>''],
'gearman_task_unique' => ['', 'task_object'=>''],
'gearman_verbose_name' => ['', 'verbose'=>''],
'gearman_version' => [''],
'gearman_worker_add_function' => ['', 'worker_object'=>'', 'function_name'=>'', 'function'=>'', 'data'=>'', 'timeout'=>''],
'gearman_worker_add_options' => ['', 'worker_object'=>'', 'option'=>''],
'gearman_worker_add_server' => ['', 'worker_object'=>'', 'host'=>'', 'port'=>''],
'gearman_worker_add_servers' => ['', 'worker_object'=>'', 'servers'=>''],
'gearman_worker_clone' => ['', 'worker_object'=>''],
'gearman_worker_create' => [''],
'gearman_worker_echo' => ['', 'worker_object'=>'', 'workload'=>''],
'gearman_worker_errno' => ['', 'worker_object'=>''],
'gearman_worker_error' => ['', 'worker_object'=>''],
'gearman_worker_grab_job' => ['', 'worker_object'=>''],
'gearman_worker_options' => ['', 'worker_object'=>''],
'gearman_worker_register' => ['', 'worker_object'=>'', 'function_name'=>'', 'timeout'=>''],
'gearman_worker_remove_options' => ['', 'worker_object'=>'', 'option'=>''],
'gearman_worker_return_code' => ['', 'worker_object'=>''],
'gearman_worker_set_options' => ['', 'worker_object'=>'', 'option'=>''],
'gearman_worker_set_timeout' => ['', 'worker_object'=>'', 'timeout'=>''],
'gearman_worker_timeout' => ['', 'worker_object'=>''],
'gearman_worker_unregister' => ['', 'worker_object'=>'', 'function_name'=>''],
'gearman_worker_unregister_all' => ['', 'worker_object'=>''],
'gearman_worker_wait' => ['', 'worker_object'=>''],
'gearman_worker_work' => ['', 'worker_object'=>''],
'GearmanClient::__construct' => ['void'],
'GearmanClient::addOptions' => ['bool', 'options'=>'int'],
'GearmanClient::addServer' => ['bool', 'host='=>'string', 'port='=>'int'],
'GearmanClient::addServers' => ['bool', 'servers='=>'string'],
'GearmanClient::addTask' => ['GearmanTask', 'function_name'=>'string', 'workload'=>'string', 'context='=>'mixed', 'unique='=>'string'],
'GearmanClient::addTaskBackground' => ['GearmanTask', 'function_name'=>'string', 'workload'=>'string', 'context='=>'mixed', 'unique='=>'string'],
'GearmanClient::addTaskHigh' => ['GearmanTask', 'function_name'=>'string', 'workload'=>'string', 'context='=>'mixed', 'unique='=>'string'],
'GearmanClient::addTaskHighBackground' => ['GearmanTask', 'function_name'=>'string', 'workload'=>'string', 'context='=>'mixed', 'unique='=>'string'],
'GearmanClient::addTaskLow' => ['GearmanTask', 'function_name'=>'string', 'workload'=>'string', 'context='=>'mixed', 'unique='=>'string'],
'GearmanClient::addTaskLowBackground' => ['GearmanTask', 'function_name'=>'string', 'workload'=>'string', 'context='=>'mixed', 'unique='=>'string'],
'GearmanClient::addTaskStatus' => ['GearmanTask', 'job_handle'=>'string', 'context='=>'string'],
'GearmanClient::clearCallbacks' => ['bool'],
'GearmanClient::clone' => ['GearmanClient'],
'GearmanClient::context' => ['string'],
'GearmanClient::data' => ['string'],
'GearmanClient::do' => ['string', 'function_name'=>'string', 'workload'=>'string', 'unique='=>'string'],
'GearmanClient::doBackground' => ['string', 'function_name'=>'string', 'workload'=>'string', 'unique='=>'string'],
'GearmanClient::doHigh' => ['string', 'function_name'=>'string', 'workload'=>'string', 'unique='=>'string'],
'GearmanClient::doHighBackground' => ['string', 'function_name'=>'string', 'workload'=>'string', 'unique='=>'string'],
'GearmanClient::doJobHandle' => ['string'],
'GearmanClient::doLow' => ['string', 'function_name'=>'string', 'workload'=>'string', 'unique='=>'string'],
'GearmanClient::doLowBackground' => ['string', 'function_name'=>'string', 'workload'=>'string', 'unique='=>'string'],
'GearmanClient::doNormal' => ['string', 'function_name'=>'string', 'workload'=>'string', 'unique='=>'string'],
'GearmanClient::doStatus' => ['array'],
'GearmanClient::echo' => ['bool', 'workload'=>'string'],
'GearmanClient::error' => ['string'],
'GearmanClient::getErrno' => ['int'],
'GearmanClient::jobStatus' => ['array', 'job_handle'=>'string'],
'GearmanClient::options' => [''],
'GearmanClient::ping' => ['bool', 'workload'=>'string'],
'GearmanClient::removeOptions' => ['bool', 'options'=>'int'],
'GearmanClient::returnCode' => ['int'],
'GearmanClient::runTasks' => ['bool'],
'GearmanClient::setClientCallback' => ['void', 'callback'=>'callable'],
'GearmanClient::setCompleteCallback' => ['bool', 'callback'=>'callable'],
'GearmanClient::setContext' => ['bool', 'context'=>'string'],
'GearmanClient::setCreatedCallback' => ['bool', 'callback'=>'string'],
'GearmanClient::setData' => ['bool', 'data'=>'string'],
'GearmanClient::setDataCallback' => ['bool', 'callback'=>'callable'],
'GearmanClient::setExceptionCallback' => ['bool', 'callback'=>'callable'],
'GearmanClient::setFailCallback' => ['bool', 'callback'=>'callable'],
'GearmanClient::setOptions' => ['bool', 'options'=>'int'],
'GearmanClient::setStatusCallback' => ['bool', 'callback'=>'callable'],
'GearmanClient::setTimeout' => ['bool', 'timeout'=>'int'],
'GearmanClient::setWarningCallback' => ['bool', 'callback'=>'callable'],
'GearmanClient::setWorkloadCallback' => ['bool', 'callback'=>'callable'],
'GearmanClient::timeout' => ['int'],
'GearmanClient::wait' => [''],
'GearmanJob::__construct' => ['void'],
'GearmanJob::complete' => ['bool', 'result'=>'string'],
'GearmanJob::data' => ['bool', 'data'=>'string'],
'GearmanJob::exception' => ['bool', 'exception'=>'string'],
'GearmanJob::fail' => ['bool'],
'GearmanJob::functionName' => ['string'],
'GearmanJob::handle' => ['string'],
'GearmanJob::returnCode' => ['int'],
'GearmanJob::sendComplete' => ['bool', 'result'=>'string'],
'GearmanJob::sendData' => ['bool', 'data'=>'string'],
'GearmanJob::sendException' => ['bool', 'exception'=>'string'],
'GearmanJob::sendFail' => ['bool'],
'GearmanJob::sendStatus' => ['bool', 'numerator'=>'int', 'denominator'=>'int'],
'GearmanJob::sendWarning' => ['bool', 'warning'=>'string'],
'GearmanJob::setReturn' => ['bool', 'gearman_return_t'=>'string'],
'GearmanJob::status' => ['bool', 'numerator'=>'int', 'denominator'=>'int'],
'GearmanJob::unique' => ['string'],
'GearmanJob::warning' => ['bool', 'warning'=>'string'],
'GearmanJob::workload' => ['string'],
'GearmanJob::workloadSize' => ['int'],
'GearmanTask::__construct' => ['void'],
'GearmanTask::create' => ['GearmanTask'],
'GearmanTask::data' => ['string'],
'GearmanTask::dataSize' => ['int'],
'GearmanTask::function' => ['string'],
'GearmanTask::functionName' => ['string'],
'GearmanTask::isKnown' => ['bool'],
'GearmanTask::isRunning' => ['bool'],
'GearmanTask::jobHandle' => ['string'],
'GearmanTask::recvData' => ['array', 'data_len'=>'int'],
'GearmanTask::returnCode' => ['int'],
'GearmanTask::sendData' => ['int', 'data'=>'string'],
'GearmanTask::sendWorkload' => ['int', 'data'=>'string'],
'GearmanTask::taskDenominator' => ['int'],
'GearmanTask::taskNumerator' => ['int'],
'GearmanTask::unique' => ['string'],
'GearmanTask::uuid' => ['string'],
'GearmanWorker::__construct' => ['void'],
'GearmanWorker::addFunction' => ['bool', 'function_name'=>'string', 'function'=>'callable', 'context='=>'mixed', 'timeout='=>'int'],
'GearmanWorker::addOptions' => ['bool', 'option'=>'int'],
'GearmanWorker::addServer' => ['bool', 'host='=>'string', 'port='=>'int'],
'GearmanWorker::addServers' => ['bool', 'servers'=>'string'],
'GearmanWorker::clone' => ['void'],
'GearmanWorker::echo' => ['bool', 'workload'=>'string'],
'GearmanWorker::error' => ['string'],
'GearmanWorker::getErrno' => ['int'],
'GearmanWorker::grabJob' => [''],
'GearmanWorker::options' => ['int'],
'GearmanWorker::register' => ['bool', 'function_name'=>'string', 'timeout='=>'int'],
'GearmanWorker::removeOptions' => ['bool', 'option'=>'int'],
'GearmanWorker::returnCode' => ['int'],
'GearmanWorker::setId' => ['bool', 'id'=>'string'],
'GearmanWorker::setOptions' => ['bool', 'option'=>'int'],
'GearmanWorker::setTimeout' => ['bool', 'timeout'=>'int'],
'GearmanWorker::timeout' => ['int'],
'GearmanWorker::unregister' => ['bool', 'function_name'=>'string'],
'GearmanWorker::unregisterAll' => ['bool'],
'GearmanWorker::wait' => ['bool'],
'GearmanWorker::work' => ['bool'],
'Gender\Gender::__construct' => ['void', 'dsn='=>'string'],
'Gender\Gender::connect' => ['bool', 'dsn'=>'string'],
'Gender\Gender::country' => ['array', 'country'=>'int'],
'Gender\Gender::get' => ['int', 'name'=>'string', 'country='=>'int'],
'Gender\Gender::isNick' => ['array', 'name0'=>'string', 'name1'=>'string', 'country='=>'int'],
'Gender\Gender::similarNames' => ['array', 'name'=>'string', 'country='=>'int'],
'Generator::__wakeup' => ['void'],
'Generator::current' => ['mixed'],
'Generator::getReturn' => ['mixed'],
'Generator::key' => ['mixed'],
'Generator::next' => ['void'],
'Generator::rewind' => ['void'],
'Generator::send' => ['mixed', 'value'=>'mixed'],
'Generator::throw' => ['mixed', 'exception'=>'Exception|Throwable'],
'Generator::valid' => ['bool'],
'geoip_asnum_by_name' => ['string', 'hostname'=>'string'],
'geoip_continent_code_by_name' => ['string', 'hostname'=>'string'],
'geoip_country_code3_by_name' => ['string', 'hostname'=>'string'],
'geoip_country_code_by_name' => ['string', 'hostname'=>'string'],
'geoip_country_name_by_name' => ['string', 'hostname'=>'string'],
'geoip_database_info' => ['string', 'database='=>'int'],
'geoip_db_avail' => ['bool', 'database'=>'int'],
'geoip_db_filename' => ['string', 'database'=>'int'],
'geoip_db_get_all_info' => ['array'],
'geoip_domain_by_name' => ['string', 'hostname'=>'string'],
'geoip_id_by_name' => ['int', 'hostname'=>'string'],
'geoip_isp_by_name' => ['string', 'hostname'=>'string'],
'geoip_netspeedcell_by_name' => ['string', 'hostname'=>'string'],
'geoip_org_by_name' => ['string', 'hostname'=>'string'],
'geoip_record_by_name' => ['array', 'hostname'=>'string'],
'geoip_region_by_name' => ['array', 'hostname'=>'string'],
'geoip_region_name_by_code' => ['string', 'country_code'=>'string', 'region_code'=>'string'],
'geoip_setup_custom_directory' => ['void', 'path'=>'string'],
'geoip_time_zone_by_country_and_region' => ['string|false', 'country_code'=>'string', 'region_code='=>'string'],
'get_browser' => ['mixed', 'browser_name='=>'string', 'return_array='=>'bool'],
'get_call_stack' => [''],
'get_called_class' => ['string'],
'get_cfg_var' => ['mixed', 'option_name'=>'string'],
'get_class' => ['string', 'object='=>'object'],
'get_class_methods' => ['array', 'class'=>'mixed'],
'get_class_vars' => ['array', 'class_name'=>'string'],
'get_current_user' => ['string'],
'get_declared_classes' => ['array'],
'get_declared_interfaces' => ['array'],
'get_declared_traits' => ['array'],
'get_defined_constants' => ['array', 'categorize='=>'bool'],
'get_defined_functions' => ['array>', 'exclude_disabled='=>'bool'],
'get_defined_vars' => ['array'],
'get_extension_funcs' => ['array', 'extension_name'=>'string'],
'get_headers' => ['array|false', 'url'=>'string', 'format='=>'int', 'context='=>'resource'],
'get_html_translation_table' => ['array', 'table='=>'int', 'flags='=>'int', 'encoding='=>'string'],
'get_include_path' => ['string'],
'get_included_files' => ['array'],
'get_loaded_extensions' => ['array', 'zend_extensions='=>'bool'],
'get_magic_quotes_gpc' => ['bool'],
'get_magic_quotes_runtime' => ['bool'],
'get_meta_tags' => ['array', 'filename'=>'string', 'use_include_path='=>'bool'],
'get_object_vars' => ['array', 'obj'=>'object'],
'get_parent_class' => ['string|false', 'object='=>'mixed'],
'get_required_files' => ['string[]'],
'get_resource_type' => ['string', 'res'=>'resource'],
'get_resources' => ['resource[]', 'resource_type'=>'string'],
'getallheaders' => ['array'],
'getcwd' => ['string|false'],
'getdate' => ['array', 'timestamp='=>'int'],
'getenv' => ['string|false', 'varname'=>'string', 'local_only='=>'bool'],
'getenv\'1' => ['string[]'],
'gethostbyaddr' => ['string|false', 'ip_address'=>'string'],
'gethostbyname' => ['string', 'hostname'=>'string'],
'gethostbynamel' => ['array|false', 'hostname'=>'string'],
'gethostname' => ['string|false'],
'getimagesize' => ['array|false', 'imagefile'=>'string', '&w_info='=>'array'],
'getimagesizefromstring' => ['array|false', 'data'=>'string', '&w_info='=>'array'],
'getlastmod' => ['int'],
'getmxrr' => ['bool', 'hostname'=>'string', '&w_mxhosts'=>'array', '&w_weight='=>'array'],
'getmygid' => ['int'],
'getmyinode' => ['int'],
'getmypid' => ['int'],
'getmyuid' => ['int'],
'getopt' => ['array|array|array>', 'options'=>'string', 'longopts='=>'array', '&w_optind='=>'int'],
'getprotobyname' => ['int|false', 'name'=>'string'],
'getprotobynumber' => ['string', 'proto'=>'int'],
'getrandmax' => ['int'],
'getrusage' => ['array', 'who='=>'int'],
'getservbyname' => ['int|false', 'service'=>'string', 'protocol'=>'string'],
'getservbyport' => ['string|false', 'port'=>'int', 'protocol'=>'string'],
'gettext' => ['string', 'msgid'=>'string'],
'gettimeofday' => ['array|float', 'get_as_float='=>'bool'],
'gettype' => ['string', 'var'=>'mixed'],
'glob' => ['array', 'pattern'=>'string', 'flags='=>'int'],
'GlobIterator::__construct' => ['void', 'path'=>'string', 'flags='=>'int'],
'GlobIterator::cont' => ['int'],
'GlobIterator::count' => ['int'],
'Gmagick::__construct' => ['void', 'filename='=>'string'],
'Gmagick::addimage' => ['Gmagick', 'gmagick'=>'gmagick'],
'Gmagick::addnoiseimage' => ['Gmagick', 'noise'=>'int'],
'Gmagick::annotateimage' => ['Gmagick', 'gmagickdraw'=>'gmagickdraw', 'x'=>'float', 'y'=>'float', 'angle'=>'float', 'text'=>'string'],
'Gmagick::blurimage' => ['Gmagick', 'radius'=>'float', 'sigma'=>'float', 'channel='=>'int'],
'Gmagick::borderimage' => ['Gmagick', 'color'=>'gmagickpixel', 'width'=>'int', 'height'=>'int'],
'Gmagick::charcoalimage' => ['Gmagick', 'radius'=>'float', 'sigma'=>'float'],
'Gmagick::chopimage' => ['Gmagick', 'width'=>'int', 'height'=>'int', 'x'=>'int', 'y'=>'int'],
'Gmagick::clear' => ['Gmagick'],
'Gmagick::commentimage' => ['Gmagick', 'comment'=>'string'],
'Gmagick::compositeimage' => ['Gmagick', 'source'=>'gmagick', 'compose'=>'int', 'x'=>'int', 'y'=>'int'],
'Gmagick::cropimage' => ['Gmagick', 'width'=>'int', 'height'=>'int', 'x'=>'int', 'y'=>'int'],
'Gmagick::cropthumbnailimage' => ['Gmagick', 'width'=>'int', 'height'=>'int'],
'Gmagick::current' => ['Gmagick'],
'Gmagick::cyclecolormapimage' => ['Gmagick', 'displace'=>'int'],
'Gmagick::deconstructimages' => ['Gmagick'],
'Gmagick::despeckleimage' => ['Gmagick'],
'Gmagick::destroy' => ['Gmagick'],
'Gmagick::drawimage' => ['Gmagick', 'gmagickdraw'=>'gmagickdraw'],
'Gmagick::edgeimage' => ['Gmagick', 'radius'=>'float'],
'Gmagick::embossimage' => ['Gmagick', 'radius'=>'float', 'sigma'=>'float'],
'Gmagick::enhanceimage' => ['Gmagick'],
'Gmagick::equalizeimage' => ['Gmagick'],
'Gmagick::flipimage' => ['Gmagick'],
'Gmagick::flopimage' => ['Gmagick'],
'Gmagick::frameimage' => ['Gmagick', 'color'=>'gmagickpixel', 'width'=>'int', 'height'=>'int', 'inner_bevel'=>'int', 'outer_bevel'=>'int'],
'Gmagick::gammaimage' => ['Gmagick', 'gamma'=>'float'],
'Gmagick::getcopyright' => ['string'],
'Gmagick::getfilename' => ['string'],
'Gmagick::getimagebackgroundcolor' => ['GmagickPixel'],
'Gmagick::getimageblueprimary' => ['array'],
'Gmagick::getimagebordercolor' => ['GmagickPixel'],
'Gmagick::getimagechanneldepth' => ['int', 'channel_type'=>'int'],
'Gmagick::getimagecolors' => ['int'],
'Gmagick::getimagecolorspace' => ['int'],
'Gmagick::getimagecompose' => ['int'],
'Gmagick::getimagedelay' => ['int'],
'Gmagick::getimagedepth' => ['int'],
'Gmagick::getimagedispose' => ['int'],
'Gmagick::getimageextrema' => ['array'],
'Gmagick::getimagefilename' => ['string'],
'Gmagick::getimageformat' => ['string'],
'Gmagick::getimagegamma' => ['float'],
'Gmagick::getimagegreenprimary' => ['array'],
'Gmagick::getimageheight' => ['int'],
'Gmagick::getimagehistogram' => ['array'],
'Gmagick::getimageindex' => ['int'],
'Gmagick::getimageinterlacescheme' => ['int'],
'Gmagick::getimageiterations' => ['int'],
'Gmagick::getimagematte' => ['int'],
'Gmagick::getimagemattecolor' => ['GmagickPixel'],
'Gmagick::getimageprofile' => ['string', 'name'=>'string'],
'Gmagick::getimageredprimary' => ['array'],
'Gmagick::getimagerenderingintent' => ['int'],
'Gmagick::getimageresolution' => ['array'],
'Gmagick::getimagescene' => ['int'],
'Gmagick::getimagesignature' => ['string'],
'Gmagick::getimagetype' => ['int'],
'Gmagick::getimageunits' => ['int'],
'Gmagick::getimagewhitepoint' => ['array'],
'Gmagick::getimagewidth' => ['int'],
'Gmagick::getpackagename' => ['string'],
'Gmagick::getquantumdepth' => ['array'],
'Gmagick::getreleasedate' => ['string'],
'Gmagick::getsamplingfactors' => ['array'],
'Gmagick::getsize' => ['array'],
'Gmagick::getversion' => ['array'],
'Gmagick::hasnextimage' => ['mixed'],
'Gmagick::haspreviousimage' => ['mixed'],
'Gmagick::implodeimage' => ['mixed', 'radius'=>'float'],
'Gmagick::labelimage' => ['mixed', 'label'=>'string'],
'Gmagick::levelimage' => ['mixed', 'blackpoint'=>'float', 'gamma'=>'float', 'whitepoint'=>'float', 'channel='=>'int'],
'Gmagick::magnifyimage' => ['mixed'],
'Gmagick::mapimage' => ['Gmagick', 'gmagick'=>'gmagick', 'dither'=>'bool'],
'Gmagick::medianfilterimage' => ['void', 'radius'=>'float'],
'Gmagick::minifyimage' => ['Gmagick'],
'Gmagick::modulateimage' => ['Gmagick', 'brightness'=>'float', 'saturation'=>'float', 'hue'=>'float'],
'Gmagick::motionblurimage' => ['Gmagick', 'radius'=>'float', 'sigma'=>'float', 'angle'=>'float'],
'Gmagick::newimage' => ['Gmagick', 'width'=>'int', 'height'=>'int', 'background'=>'string', 'format='=>'string'],
'Gmagick::nextimage' => ['bool'],
'Gmagick::normalizeimage' => ['Gmagick', 'channel='=>'int'],
'Gmagick::oilpaintimage' => ['Gmagick', 'radius'=>'float'],
'Gmagick::previousimage' => ['bool'],
'Gmagick::profileimage' => ['Gmagick', 'name'=>'string', 'profile'=>'string'],
'Gmagick::quantizeimage' => ['Gmagick', 'numcolors'=>'int', 'colorspace'=>'int', 'treedepth'=>'int', 'dither'=>'bool', 'measureerror'=>'bool'],
'Gmagick::quantizeimages' => ['Gmagick', 'numcolors'=>'int', 'colorspace'=>'int', 'treedepth'=>'int', 'dither'=>'bool', 'measureerror'=>'bool'],
'Gmagick::queryfontmetrics' => ['array', 'draw'=>'gmagickdraw', 'text'=>'string'],
'Gmagick::queryfonts' => ['array', 'pattern='=>'string'],
'Gmagick::queryformats' => ['array', 'pattern='=>'string'],
'Gmagick::radialblurimage' => ['Gmagick', 'angle'=>'float', 'channel='=>'int'],
'Gmagick::raiseimage' => ['Gmagick', 'width'=>'int', 'height'=>'int', 'x'=>'int', 'y'=>'int', 'raise'=>'bool'],
'Gmagick::read' => ['Gmagick', 'filename'=>'string'],
'Gmagick::readimage' => ['Gmagick', 'filename'=>'string'],
'Gmagick::readimageblob' => ['Gmagick', 'imagecontents'=>'string', 'filename='=>'string'],
'Gmagick::readimagefile' => ['Gmagick', 'fp'=>'resource', 'filename='=>'string'],
'Gmagick::reducenoiseimage' => ['Gmagick', 'radius'=>'float'],
'Gmagick::removeimage' => ['Gmagick'],
'Gmagick::removeimageprofile' => ['string', 'name'=>'string'],
'Gmagick::resampleimage' => ['Gmagick', 'xresolution'=>'float', 'yresolution'=>'float', 'filter'=>'int', 'blur'=>'float'],
'Gmagick::resizeimage' => ['Gmagick', 'width'=>'int', 'height'=>'int', 'filter'=>'int', 'blur'=>'float', 'fit='=>'bool'],
'Gmagick::rollimage' => ['Gmagick', 'x'=>'int', 'y'=>'int'],
'Gmagick::rotateimage' => ['Gmagick', 'color'=>'mixed', 'degrees'=>'float'],
'Gmagick::scaleimage' => ['Gmagick', 'width'=>'int', 'height'=>'int', 'fit='=>'bool'],
'Gmagick::separateimagechannel' => ['Gmagick', 'channel'=>'int'],
'Gmagick::setCompressionQuality' => ['Gmagick', 'quality'=>'int'],
'Gmagick::setfilename' => ['Gmagick', 'filename'=>'string'],
'Gmagick::setimagebackgroundcolor' => ['Gmagick', 'color'=>'gmagickpixel'],
'Gmagick::setimageblueprimary' => ['Gmagick', 'x'=>'float', 'y'=>'float'],
'Gmagick::setimagebordercolor' => ['Gmagick', 'color'=>'gmagickpixel'],
'Gmagick::setimagechanneldepth' => ['Gmagick', 'channel'=>'int', 'depth'=>'int'],
'Gmagick::setimagecolorspace' => ['Gmagick', 'colorspace'=>'int'],
'Gmagick::setimagecompose' => ['Gmagick', 'composite'=>'int'],
'Gmagick::setimagedelay' => ['Gmagick', 'delay'=>'int'],
'Gmagick::setimagedepth' => ['Gmagick', 'depth'=>'int'],
'Gmagick::setimagedispose' => ['Gmagick', 'disposetype'=>'int'],
'Gmagick::setimagefilename' => ['Gmagick', 'filename'=>'string'],
'Gmagick::setimageformat' => ['Gmagick', 'imageformat'=>'string'],
'Gmagick::setimagegamma' => ['Gmagick', 'gamma'=>'float'],
'Gmagick::setimagegreenprimary' => ['Gmagick', 'x'=>'float', 'y'=>'float'],
'Gmagick::setimageindex' => ['Gmagick', 'index'=>'int'],
'Gmagick::setimageinterlacescheme' => ['Gmagick', 'interlace'=>'int'],
'Gmagick::setimageiterations' => ['Gmagick', 'iterations'=>'int'],
'Gmagick::setimageprofile' => ['Gmagick', 'name'=>'string', 'profile'=>'string'],
'Gmagick::setimageredprimary' => ['Gmagick', 'x'=>'float', 'y'=>'float'],
'Gmagick::setimagerenderingintent' => ['Gmagick', 'rendering_intent'=>'int'],
'Gmagick::setimageresolution' => ['Gmagick', 'xresolution'=>'float', 'yresolution'=>'float'],
'Gmagick::setimagescene' => ['Gmagick', 'scene'=>'int'],
'Gmagick::setimagetype' => ['Gmagick', 'imgtype'=>'int'],
'Gmagick::setimageunits' => ['Gmagick', 'resolution'=>'int'],
'Gmagick::setimagewhitepoint' => ['Gmagick', 'x'=>'float', 'y'=>'float'],
'Gmagick::setsamplingfactors' => ['Gmagick', 'factors'=>'array'],
'Gmagick::setsize' => ['Gmagick', 'columns'=>'int', 'rows'=>'int'],
'Gmagick::shearimage' => ['Gmagick', 'color'=>'mixed', 'xshear'=>'float', 'yshear'=>'float'],
'Gmagick::solarizeimage' => ['Gmagick', 'threshold'=>'int'],
'Gmagick::spreadimage' => ['Gmagick', 'radius'=>'float'],
'Gmagick::stripimage' => ['Gmagick'],
'Gmagick::swirlimage' => ['Gmagick', 'degrees'=>'float'],
'Gmagick::thumbnailimage' => ['Gmagick', 'width'=>'int', 'height'=>'int', 'fit='=>'bool'],
'Gmagick::trimimage' => ['Gmagick', 'fuzz'=>'float'],
'Gmagick::write' => ['', 'filename'=>'string'],
'Gmagick::writeimage' => ['Gmagick', 'filename'=>'string', 'all_frames='=>'bool'],
'GmagickDraw::annotate' => ['GmagickDraw', 'x'=>'float', 'y'=>'float', 'text'=>'string'],
'GmagickDraw::arc' => ['GmagickDraw', 'sx'=>'float', 'sy'=>'float', 'ex'=>'float', 'ey'=>'float', 'sd'=>'float', 'ed'=>'float'],
'GmagickDraw::bezier' => ['GmagickDraw', 'coordinate_array'=>'array'],
'GmagickDraw::ellipse' => ['GmagickDraw', 'ox'=>'float', 'oy'=>'float', 'rx'=>'float', 'ry'=>'float', 'start'=>'float', 'end'=>'float'],
'GmagickDraw::getfillcolor' => ['GmagickPixel'],
'GmagickDraw::getfillopacity' => ['float'],
'GmagickDraw::getfont' => ['string'],
'GmagickDraw::getfontsize' => ['float'],
'GmagickDraw::getfontstyle' => ['int'],
'GmagickDraw::getfontweight' => ['int'],
'GmagickDraw::getstrokecolor' => ['GmagickPixel'],
'GmagickDraw::getstrokeopacity' => ['float'],
'GmagickDraw::getstrokewidth' => ['float'],
'GmagickDraw::gettextdecoration' => ['int'],
'GmagickDraw::gettextencoding' => ['string'],
'GmagickDraw::line' => ['GmagickDraw', 'sx'=>'float', 'sy'=>'float', 'ex'=>'float', 'ey'=>'float'],
'GmagickDraw::point' => ['GmagickDraw', 'x'=>'float', 'y'=>'float'],
'GmagickDraw::polygon' => ['GmagickDraw', 'coordinates'=>'array'],
'GmagickDraw::polyline' => ['GmagickDraw', 'coordinate_array'=>'array'],
'GmagickDraw::rectangle' => ['GmagickDraw', 'x1'=>'float', 'y1'=>'float', 'x2'=>'float', 'y2'=>'float'],
'GmagickDraw::rotate' => ['GmagickDraw', 'degrees'=>'float'],
'GmagickDraw::roundrectangle' => ['GmagickDraw', 'x1'=>'float', 'y1'=>'float', 'x2'=>'float', 'y2'=>'float', 'rx'=>'float', 'ry'=>'float'],
'GmagickDraw::scale' => ['GmagickDraw', 'x'=>'float', 'y'=>'float'],
'GmagickDraw::setfillcolor' => ['GmagickDraw', 'color'=>'string'],
'GmagickDraw::setfillopacity' => ['GmagickDraw', 'fill_opacity'=>'float'],
'GmagickDraw::setfont' => ['GmagickDraw', 'font'=>'string'],
'GmagickDraw::setfontsize' => ['GmagickDraw', 'pointsize'=>'float'],
'GmagickDraw::setfontstyle' => ['GmagickDraw', 'style'=>'int'],
'GmagickDraw::setfontweight' => ['GmagickDraw', 'weight'=>'int'],
'GmagickDraw::setstrokecolor' => ['GmagickDraw', 'color'=>'gmagickpixel'],
'GmagickDraw::setstrokeopacity' => ['GmagickDraw', 'stroke_opacity'=>'float'],
'GmagickDraw::setstrokewidth' => ['GmagickDraw', 'width'=>'float'],
'GmagickDraw::settextdecoration' => ['GmagickDraw', 'decoration'=>'int'],
'GmagickDraw::settextencoding' => ['GmagickDraw', 'encoding'=>'string'],
'GmagickPixel::__construct' => ['void', 'color='=>'string'],
'GmagickPixel::getcolor' => ['mixed', 'as_array='=>'bool', 'normalize_array='=>'bool'],
'GmagickPixel::getcolorcount' => ['int'],
'GmagickPixel::getcolorvalue' => ['float', 'color'=>'int'],
'GmagickPixel::setcolor' => ['GmagickPixel', 'color'=>'string'],
'GmagickPixel::setcolorvalue' => ['GmagickPixel', 'color'=>'int', 'value'=>'float'],
'gmdate' => ['string', 'format'=>'string', 'timestamp='=>'int'],
'gmmktime' => ['int', 'hour='=>'int', 'min='=>'int', 'sec='=>'int', 'mon='=>'int', 'day='=>'int', 'year='=>'int'],
'GMP::__construct' => ['void'],
'GMP::serialize' => ['string'],
'GMP::__toString' => ['string'],
'GMP::unserialize' => ['void', 'serialized'=>'string'],
'gmp_abs' => ['GMP', 'a'=>'GMP|string|int'],
'gmp_add' => ['GMP', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmp_and' => ['GMP', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmp_clrbit' => ['void', 'a'=>'GMP|string|int', 'index'=>'int'],
'gmp_cmp' => ['int', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmp_com' => ['GMP', 'a'=>'GMP|string|int'],
'gmp_div' => ['resource', 'a'=>'GMP|resource|string', 'b'=>'GMP|resource|string', 'round='=>'int'],
'gmp_div_q' => ['GMP', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int', 'round='=>'int'],
'gmp_div_qr' => ['array', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int', 'round='=>'int'],
'gmp_div_r' => ['GMP', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int', 'round='=>'int'],
'gmp_divexact' => ['GMP', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmp_export' => ['string', 'gmpnumber'=>'GMP|string|int', 'word_size='=>'int', 'options='=>'int'],
'gmp_fact' => ['GMP', 'a'=>'int'],
'gmp_gcd' => ['GMP', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmp_gcdext' => ['array', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmp_hamdist' => ['int', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmp_import' => ['GMP', 'data'=>'string', 'word_size='=>'int', 'options='=>'int'],
'gmp_init' => ['GMP', 'number'=>'int|string', 'base='=>'int'],
'gmp_intval' => ['int', 'gmpnumber'=>'GMP|string|int'],
'gmp_invert' => ['GMP', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmp_jacobi' => ['int', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmp_legendre' => ['int', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmp_mod' => ['GMP', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmp_mul' => ['GMP', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmp_neg' => ['GMP', 'a'=>'GMP|string|int'],
'gmp_nextprime' => ['GMP', 'a'=>'GMP|string|int'],
'gmp_or' => ['GMP', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmp_perfect_square' => ['bool', 'a'=>'GMP|string|int'],
'gmp_popcount' => ['int', 'a'=>'GMP|string|int'],
'gmp_pow' => ['GMP', 'base'=>'GMP|string|int', 'exp'=>'int'],
'gmp_powm' => ['GMP', 'base'=>'GMP|string|int', 'exp'=>'GMP|string|int', 'mod'=>'GMP|string|int'],
'gmp_prob_prime' => ['int', 'a'=>'GMP|string|int', 'reps='=>'int'],
'gmp_random' => ['GMP', 'limiter='=>'int'],
'gmp_random_bits' => ['GMP', 'bits'=>'int'],
'gmp_random_range' => ['GMP', 'min'=>'GMP|string|int', 'max'=>'GMP|string|int'],
'gmp_random_seed' => ['GMP', 'seed'=>'GMP|string|int'],
'gmp_root' => ['GMP', 'a'=>'GMP|string|int', 'nth'=>'int'],
'gmp_rootrem' => ['array', 'a'=>'GMP|string|int', 'nth'=>'int'],
'gmp_scan0' => ['int', 'a'=>'GMP|string|int', 'start'=>'int'],
'gmp_scan1' => ['int', 'a'=>'GMP|string|int', 'start'=>'int'],
'gmp_setbit' => ['void', 'a'=>'GMP|string|int', 'index'=>'int', 'set_clear='=>'bool'],
'gmp_sign' => ['int', 'a'=>'GMP|string|int'],
'gmp_sqrt' => ['GMP', 'a'=>'GMP|string|int'],
'gmp_sqrtrem' => ['array', 'a'=>'GMP|string|int'],
'gmp_strval' => ['string', 'gmpnumber'=>'GMP|string|int', 'base='=>'int'],
'gmp_sub' => ['GMP', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmp_testbit' => ['bool', 'a'=>'GMP|string|int', 'index'=>'int'],
'gmp_xor' => ['GMP', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmstrftime' => ['string', 'format'=>'string', 'timestamp='=>'int'],
'gnupg::adddecryptkey' => ['bool', 'fingerprint'=>'string', 'passphrase'=>'string'],
'gnupg::addencryptkey' => ['bool', 'fingerprint'=>'string'],
'gnupg::addsignkey' => ['bool', 'fingerprint'=>'string', 'passphrase='=>'string'],
'gnupg::cleardecryptkeys' => ['bool'],
'gnupg::clearencryptkeys' => ['bool'],
'gnupg::clearsignkeys' => ['bool'],
'gnupg::decrypt' => ['string', 'text'=>'string'],
'gnupg::decryptverify' => ['array', 'text'=>'string', '&plaintext'=>'string'],
'gnupg::encrypt' => ['string', 'plaintext'=>'string'],
'gnupg::encryptsign' => ['string', 'plaintext'=>'string'],
'gnupg::export' => ['string', 'fingerprint'=>'string'],
'gnupg::geterror' => ['string'],
'gnupg::getprotocol' => ['int'],
'gnupg::import' => ['array', 'keydata'=>'string'],
'gnupg::init' => ['resource'],
'gnupg::keyinfo' => ['array', 'pattern'=>'string'],
'gnupg::setarmor' => ['bool', 'armor'=>'int'],
'gnupg::seterrormode' => ['void', 'errormode'=>'int'],
'gnupg::setsignmode' => ['bool', 'signmode'=>'int'],
'gnupg::sign' => ['string', 'plaintext'=>'string'],
'gnupg::verify' => ['array', 'signed_text'=>'string', 'signature'=>'string', '&plaintext='=>'string'],
'gnupg_adddecryptkey' => ['bool', 'identifier'=>'resource', 'fingerprint'=>'string', 'passphrase'=>'string'],
'gnupg_addencryptkey' => ['bool', 'identifier'=>'resource', 'fingerprint'=>'string'],
'gnupg_addsignkey' => ['bool', 'identifier'=>'resource', 'fingerprint'=>'string', 'passphrase='=>'string'],
'gnupg_cleardecryptkeys' => ['bool', 'identifier'=>'resource'],
'gnupg_clearencryptkeys' => ['bool', 'identifier'=>'resource'],
'gnupg_clearsignkeys' => ['bool', 'identifier'=>'resource'],
'gnupg_decrypt' => ['string', 'identifier'=>'resource', 'text'=>'string'],
'gnupg_decryptverify' => ['array', 'identifier'=>'resource', 'text'=>'string', 'plaintext'=>'string'],
'gnupg_encrypt' => ['string', 'identifier'=>'resource', 'plaintext'=>'string'],
'gnupg_encryptsign' => ['string', 'identifier'=>'resource', 'plaintext'=>'string'],
'gnupg_export' => ['string', 'identifier'=>'resource', 'fingerprint'=>'string'],
'gnupg_geterror' => ['string', 'identifier'=>'resource'],
'gnupg_getprotocol' => ['int', 'identifier'=>'resource'],
'gnupg_import' => ['array', 'identifier'=>'resource', 'keydata'=>'string'],
'gnupg_init' => ['resource'],
'gnupg_keyinfo' => ['array', 'identifier'=>'resource', 'pattern'=>'string'],
'gnupg_setarmor' => ['bool', 'identifier'=>'resource', 'armor'=>'int'],
'gnupg_seterrormode' => ['void', 'identifier'=>'resource', 'errormode'=>'int'],
'gnupg_setsignmode' => ['bool', 'identifier'=>'resource', 'signmode'=>'int'],
'gnupg_sign' => ['string', 'identifier'=>'resource', 'plaintext'=>'string'],
'gnupg_verify' => ['array', 'identifier'=>'resource', 'signed_text'=>'string', 'signature'=>'string', 'plaintext='=>'string'],
'gopher_parsedir' => ['array', 'dirent'=>'string'],
'grapheme_extract' => ['string|false', 'str'=>'string', 'size'=>'int', 'extract_type='=>'int', 'start='=>'int', '&w_next='=>'int'],
'grapheme_stripos' => ['int|false', 'haystack'=>'string', 'needle'=>'string', 'offset='=>'int'],
'grapheme_stristr' => ['string|false', 'haystack'=>'string', 'needle'=>'string', 'part='=>'bool'],
'grapheme_strlen' => ['int|false', 'str'=>'string'],
'grapheme_strpos' => ['int|false', 'haystack'=>'string', 'needle'=>'string', 'offset='=>'int'],
'grapheme_strripos' => ['int|false', 'haystack'=>'string', 'needle'=>'string', 'offset='=>'int'],
'grapheme_strrpos' => ['int|false', 'haystack'=>'string', 'needle'=>'string', 'offset='=>'int'],
'grapheme_strstr' => ['string|false', 'haystack'=>'string', 'needle'=>'string', 'part='=>'bool'],
'grapheme_substr' => ['string|false', 'str'=>'string', 'start'=>'int', 'length='=>'int'],
'gregoriantojd' => ['int', 'month'=>'int', 'day'=>'int', 'year'=>'int'],
'gridObj::set' => ['int', 'property_name'=>'string', 'new_value'=>''],
'Grpc\Call::__construct' => ['void', 'channel'=>'Grpc\Channel', 'method'=>'string', 'absolute_deadline'=>'Grpc\Timeval', 'host_override='=>'mixed'],
'Grpc\Call::cancel' => [''],
'Grpc\Call::getPeer' => ['string'],
'Grpc\Call::setCredentials' => ['int', 'creds_obj'=>'Grpc\CallCredentials'],
'Grpc\Call::startBatch' => ['object', 'batch'=>'array'],
'Grpc\CallCredentials::createComposite' => ['Grpc\CallCredentials', 'cred1'=>'Grpc\CallCredentials', 'cred2'=>'Grpc\CallCredentials'],
'Grpc\CallCredentials::createFromPlugin' => ['Grpc\CallCredentials', 'callback'=>'Closure'],
'Grpc\Channel::__construct' => ['void', 'target'=>'string', 'args='=>'array'],
'Grpc\Channel::close' => [''],
'Grpc\Channel::getConnectivityState' => ['int', 'try_to_connect='=>'bool|false'],
'Grpc\Channel::getTarget' => ['string'],
'Grpc\Channel::watchConnectivityState' => ['bool', 'last_state'=>'int', 'deadline_obj'=>'Grpc\Timeval'],
'Grpc\ChannelCredentials::createComposite' => ['Grpc\ChannelCredentials', 'cred1'=>'Grpc\ChannelCredentials', 'cred2'=>'Grpc\CallCredentials'],
'Grpc\ChannelCredentials::createDefault' => ['Grpc\ChannelCredentials'],
'Grpc\ChannelCredentials::createInsecure' => ['null'],
'Grpc\ChannelCredentials::createSsl' => ['Grpc\ChannelCredentials', 'pem_root_certs'=>'string', 'pem_private_key='=>'string', 'pem_cert_chain='=>'string'],
'Grpc\ChannelCredentials::setDefaultRootsPem' => ['', 'pem_roots'=>'string'],
'Grpc\Server::__construct' => ['void', 'args'=>'array'],
'Grpc\Server::addHttp2Port' => ['bool', 'addr'=>'string'],
'Grpc\Server::addSecureHttp2Port' => ['bool', 'addr'=>'string', 'creds_obj'=>'Grpc\ServerCredentials'],
'Grpc\Server::requestCall' => ['', 'tag_new'=>'int', 'tag_cancel'=>'int'],
'Grpc\Server::start' => [''],
'Grpc\ServerCredentials::createSsl' => ['object', 'pem_root_certs'=>'string', 'pem_private_key'=>'string', 'pem_cert_chain'=>'string'],
'Grpc\Timeval::__construct' => ['void', 'usec'=>'int'],
'Grpc\Timeval::add' => ['Grpc\Timeval', 'other'=>'Grpc\Timeval'],
'Grpc\Timeval::compare' => ['int', 'a'=>'Grpc\Timeval', 'b'=>'Grpc\Timeval'],
'Grpc\Timeval::infFuture' => ['Grpc\Timeval'],
'Grpc\Timeval::infPast' => ['Grpc\Timeval'],
'Grpc\Timeval::now' => ['Grpc\Timeval'],
'Grpc\Timeval::similar' => ['bool', 'a'=>'Grpc\Timeval', 'b'=>'Grpc\Timeval', 'threshold'=>'Grpc\Timeval'],
'Grpc\Timeval::sleepUntil' => [''],
'Grpc\Timeval::subtract' => ['Grpc\Timeval', 'other'=>'Grpc\Timeval'],
'Grpc\Timeval::zero' => ['Grpc\Timeval'],
'gupnp_context_get_host_ip' => ['string', 'context'=>'resource'],
'gupnp_context_get_port' => ['int', 'context'=>'resource'],
'gupnp_context_get_subscription_timeout' => ['int', 'context'=>'resource'],
'gupnp_context_host_path' => ['bool', 'context'=>'resource', 'local_path'=>'string', 'server_path'=>'string'],
'gupnp_context_new' => ['resource', 'host_ip='=>'string', 'port='=>'int'],
'gupnp_context_set_subscription_timeout' => ['void', 'context'=>'resource', 'timeout'=>'int'],
'gupnp_context_timeout_add' => ['bool', 'context'=>'resource', 'timeout'=>'int', 'callback'=>'mixed', 'arg='=>'mixed'],
'gupnp_context_unhost_path' => ['bool', 'context'=>'resource', 'server_path'=>'string'],
'gupnp_control_point_browse_start' => ['bool', 'cpoint'=>'resource'],
'gupnp_control_point_browse_stop' => ['bool', 'cpoint'=>'resource'],
'gupnp_control_point_callback_set' => ['bool', 'cpoint'=>'resource', 'signal'=>'int', 'callback'=>'mixed', 'arg='=>'mixed'],
'gupnp_control_point_new' => ['resource', 'context'=>'resource', 'target'=>'string'],
'gupnp_device_action_callback_set' => ['bool', 'root_device'=>'resource', 'signal'=>'int', 'action_name'=>'string', 'callback'=>'mixed', 'arg='=>'mixed'],
'gupnp_device_info_get' => ['array', 'root_device'=>'resource'],
'gupnp_device_info_get_service' => ['resource', 'root_device'=>'resource', 'type'=>'string'],
'gupnp_root_device_get_available' => ['bool', 'root_device'=>'resource'],
'gupnp_root_device_get_relative_location' => ['string', 'root_device'=>'resource'],
'gupnp_root_device_new' => ['resource', 'context'=>'resource', 'location'=>'string', 'description_dir'=>'string'],
'gupnp_root_device_set_available' => ['bool', 'root_device'=>'resource', 'available'=>'bool'],
'gupnp_root_device_start' => ['bool', 'root_device'=>'resource'],
'gupnp_root_device_stop' => ['bool', 'root_device'=>'resource'],
'gupnp_service_action_get' => ['mixed', 'action'=>'resource', 'name'=>'string', 'type'=>'int'],
'gupnp_service_action_return' => ['bool', 'action'=>'resource'],
'gupnp_service_action_return_error' => ['bool', 'action'=>'resource', 'error_code'=>'int', 'error_description='=>'string'],
'gupnp_service_action_set' => ['bool', 'action'=>'resource', 'name'=>'string', 'type'=>'int', 'value'=>'mixed'],
'gupnp_service_freeze_notify' => ['bool', 'service'=>'resource'],
'gupnp_service_info_get' => ['array', 'proxy'=>'resource'],
'gupnp_service_info_get_introspection' => ['mixed', 'proxy'=>'resource', 'callback='=>'mixed', 'arg='=>'mixed'],
'gupnp_service_introspection_get_state_variable' => ['array', 'introspection'=>'resource', 'variable_name'=>'string'],
'gupnp_service_notify' => ['bool', 'service'=>'resource', 'name'=>'string', 'type'=>'int', 'value'=>'mixed'],
'gupnp_service_proxy_action_get' => ['mixed', 'proxy'=>'resource', 'action'=>'string', 'name'=>'string', 'type'=>'int'],
'gupnp_service_proxy_action_set' => ['bool', 'proxy'=>'resource', 'action'=>'string', 'name'=>'string', 'value'=>'mixed', 'type'=>'int'],
'gupnp_service_proxy_add_notify' => ['bool', 'proxy'=>'resource', 'value'=>'string', 'type'=>'int', 'callback'=>'mixed', 'arg='=>'mixed'],
'gupnp_service_proxy_callback_set' => ['bool', 'proxy'=>'resource', 'signal'=>'int', 'callback'=>'mixed', 'arg='=>'mixed'],
'gupnp_service_proxy_get_subscribed' => ['bool', 'proxy'=>'resource'],
'gupnp_service_proxy_remove_notify' => ['bool', 'proxy'=>'resource', 'value'=>'string'],
'gupnp_service_proxy_send_action' => ['array', 'proxy'=>'resource', 'action'=>'string', 'in_params'=>'array', 'out_params'=>'array'],
'gupnp_service_proxy_set_subscribed' => ['bool', 'proxy'=>'resource', 'subscribed'=>'bool'],
'gupnp_service_thaw_notify' => ['bool', 'service'=>'resource'],
'gzclose' => ['bool', 'zp'=>'resource'],
'gzcompress' => ['string|false', 'data'=>'string', 'level='=>'int', 'encoding='=>'int'],
'gzdecode' => ['string|false', 'data'=>'string', 'length='=>'int'],
'gzdeflate' => ['string|false', 'data'=>'string', 'level='=>'int', 'encoding='=>'int'],
'gzencode' => ['string|false', 'data'=>'string', 'level='=>'int', 'encoding_mode='=>'int'],
'gzeof' => ['int', 'zp'=>'resource'],
'gzfile' => ['array', 'filename'=>'string', 'use_include_path='=>'int'],
'gzgetc' => ['string|false', 'zp'=>'resource'],
'gzgets' => ['string|false', 'zp'=>'resource', 'length='=>'int'],
'gzgetss' => ['string|false', 'zp'=>'resource', 'length'=>'int', 'allowable_tags='=>'string'],
'gzinflate' => ['string|false', 'data'=>'string', 'length='=>'int'],
'gzopen' => ['resource|false', 'filename'=>'string', 'mode'=>'string', 'use_include_path='=>'int'],
'gzpassthru' => ['int|false', 'zp'=>'resource'],
'gzputs' => ['int', 'zp'=>'resource', 'string'=>'string', 'length='=>'int'],
'gzread' => ['string', 'zp'=>'resource', 'length'=>'int'],
'gzrewind' => ['bool', 'zp'=>'resource'],
'gzseek' => ['int', 'zp'=>'resource', 'offset'=>'int', 'whence='=>'int'],
'gztell' => ['int|false', 'zp'=>'resource'],
'gzuncompress' => ['string|false', 'data'=>'string', 'length='=>'int'],
'gzwrite' => ['int', 'zp'=>'resource', 'string'=>'string', 'length='=>'int'],
'HaruAnnotation::setBorderStyle' => ['bool', 'width'=>'float', 'dash_on'=>'int', 'dash_off'=>'int'],
'HaruAnnotation::setHighlightMode' => ['bool', 'mode'=>'int'],
'HaruAnnotation::setIcon' => ['bool', 'icon'=>'int'],
'HaruAnnotation::setOpened' => ['bool', 'opened'=>'bool'],
'HaruDestination::setFit' => ['bool'],
'HaruDestination::setFitB' => ['bool'],
'HaruDestination::setFitBH' => ['bool', 'top'=>'float'],
'HaruDestination::setFitBV' => ['bool', 'left'=>'float'],
'HaruDestination::setFitH' => ['bool', 'top'=>'float'],
'HaruDestination::setFitR' => ['bool', 'left'=>'float', 'bottom'=>'float', 'right'=>'float', 'top'=>'float'],
'HaruDestination::setFitV' => ['bool', 'left'=>'float'],
'HaruDestination::setXYZ' => ['bool', 'left'=>'float', 'top'=>'float', 'zoom'=>'float'],
'HaruDoc::__construct' => ['void'],
'HaruDoc::addPage' => ['object'],
'HaruDoc::addPageLabel' => ['bool', 'first_page'=>'int', 'style'=>'int', 'first_num'=>'int', 'prefix='=>'string'],
'HaruDoc::createOutline' => ['object', 'title'=>'string', 'parent_outline='=>'object', 'encoder='=>'object'],
'HaruDoc::getCurrentEncoder' => ['object'],
'HaruDoc::getCurrentPage' => ['object'],
'HaruDoc::getEncoder' => ['object', 'encoding'=>'string'],
'HaruDoc::getFont' => ['object', 'fontname'=>'string', 'encoding='=>'string'],
'HaruDoc::getInfoAttr' => ['string', 'type'=>'int'],
'HaruDoc::getPageLayout' => ['int'],
'HaruDoc::getPageMode' => ['int'],
'HaruDoc::getStreamSize' => ['int'],
'HaruDoc::insertPage' => ['object', 'page'=>'object'],
'HaruDoc::loadJPEG' => ['object', 'filename'=>'string'],
'HaruDoc::loadPNG' => ['object', 'filename'=>'string', 'deferred='=>'bool'],
'HaruDoc::loadRaw' => ['object', 'filename'=>'string', 'width'=>'int', 'height'=>'int', 'color_space'=>'int'],
'HaruDoc::loadTTC' => ['string', 'fontfile'=>'string', 'index'=>'int', 'embed='=>'bool'],
'HaruDoc::loadTTF' => ['string', 'fontfile'=>'string', 'embed='=>'bool'],
'HaruDoc::loadType1' => ['string', 'afmfile'=>'string', 'pfmfile='=>'string'],
'HaruDoc::output' => ['bool'],
'HaruDoc::readFromStream' => ['string', 'bytes'=>'int'],
'HaruDoc::resetError' => ['bool'],
'HaruDoc::resetStream' => ['bool'],
'HaruDoc::save' => ['bool', 'file'=>'string'],
'HaruDoc::saveToStream' => ['bool'],
'HaruDoc::setCompressionMode' => ['bool', 'mode'=>'int'],
'HaruDoc::setCurrentEncoder' => ['bool', 'encoding'=>'string'],
'HaruDoc::setEncryptionMode' => ['bool', 'mode'=>'int', 'key_len='=>'int'],
'HaruDoc::setInfoAttr' => ['bool', 'type'=>'int', 'info'=>'string'],
'HaruDoc::setInfoDateAttr' => ['bool', 'type'=>'int', 'year'=>'int', 'month'=>'int', 'day'=>'int', 'hour'=>'int', 'min'=>'int', 'sec'=>'int', 'ind'=>'string', 'off_hour'=>'int', 'off_min'=>'int'],
'HaruDoc::setOpenAction' => ['bool', 'destination'=>'object'],
'HaruDoc::setPageLayout' => ['bool', 'layout'=>'int'],
'HaruDoc::setPageMode' => ['bool', 'mode'=>'int'],
'HaruDoc::setPagesConfiguration' => ['bool', 'page_per_pages'=>'int'],
'HaruDoc::setPassword' => ['bool', 'owner_password'=>'string', 'user_password'=>'string'],
'HaruDoc::setPermission' => ['bool', 'permission'=>'int'],
'HaruDoc::useCNSEncodings' => ['bool'],
'HaruDoc::useCNSFonts' => ['bool'],
'HaruDoc::useCNTEncodings' => ['bool'],
'HaruDoc::useCNTFonts' => ['bool'],
'HaruDoc::useJPEncodings' => ['bool'],
'HaruDoc::useJPFonts' => ['bool'],
'HaruDoc::useKREncodings' => ['bool'],
'HaruDoc::useKRFonts' => ['bool'],
'HaruEncoder::getByteType' => ['int', 'text'=>'string', 'index'=>'int'],
'HaruEncoder::getType' => ['int'],
'HaruEncoder::getUnicode' => ['int', 'character'=>'int'],
'HaruEncoder::getWritingMode' => ['int'],
'HaruFont::getAscent' => ['int'],
'HaruFont::getCapHeight' => ['int'],
'HaruFont::getDescent' => ['int'],
'HaruFont::getEncodingName' => ['string'],
'HaruFont::getFontName' => ['string'],
'HaruFont::getTextWidth' => ['array', 'text'=>'string'],
'HaruFont::getUnicodeWidth' => ['int', 'character'=>'int'],
'HaruFont::getXHeight' => ['int'],
'HaruFont::measureText' => ['int', 'text'=>'string', 'width'=>'float', 'font_size'=>'float', 'char_space'=>'float', 'word_space'=>'float', 'word_wrap='=>'bool'],
'HaruImage::getBitsPerComponent' => ['int'],
'HaruImage::getColorSpace' => ['string'],
'HaruImage::getHeight' => ['int'],
'HaruImage::getSize' => ['array'],
'HaruImage::getWidth' => ['int'],
'HaruImage::setColorMask' => ['bool', 'rmin'=>'int', 'rmax'=>'int', 'gmin'=>'int', 'gmax'=>'int', 'bmin'=>'int', 'bmax'=>'int'],
'HaruImage::setMaskImage' => ['bool', 'mask_image'=>'object'],
'HaruOutline::setDestination' => ['bool', 'destination'=>'object'],
'HaruOutline::setOpened' => ['bool', 'opened'=>'bool'],
'HaruPage::arc' => ['bool', 'x'=>'float', 'y'=>'float', 'ray'=>'float', 'ang1'=>'float', 'ang2'=>'float'],
'HaruPage::beginText' => ['bool'],
'HaruPage::circle' => ['bool', 'x'=>'float', 'y'=>'float', 'ray'=>'float'],
'HaruPage::closePath' => ['bool'],
'HaruPage::concat' => ['bool', 'a'=>'float', 'b'=>'float', 'c'=>'float', 'd'=>'float', 'x'=>'float', 'y'=>'float'],
'HaruPage::createDestination' => ['object'],
'HaruPage::createLinkAnnotation' => ['object', 'rectangle'=>'array', 'destination'=>'object'],
'HaruPage::createTextAnnotation' => ['object', 'rectangle'=>'array', 'text'=>'string', 'encoder='=>'object'],
'HaruPage::createURLAnnotation' => ['object', 'rectangle'=>'array', 'url'=>'string'],
'HaruPage::curveTo' => ['bool', 'x1'=>'float', 'y1'=>'float', 'x2'=>'float', 'y2'=>'float', 'x3'=>'float', 'y3'=>'float'],
'HaruPage::curveTo2' => ['bool', 'x2'=>'float', 'y2'=>'float', 'x3'=>'float', 'y3'=>'float'],
'HaruPage::curveTo3' => ['bool', 'x1'=>'float', 'y1'=>'float', 'x3'=>'float', 'y3'=>'float'],
'HaruPage::drawImage' => ['bool', 'image'=>'object', 'x'=>'float', 'y'=>'float', 'width'=>'float', 'height'=>'float'],
'HaruPage::ellipse' => ['bool', 'x'=>'float', 'y'=>'float', 'xray'=>'float', 'yray'=>'float'],
'HaruPage::endPath' => ['bool'],
'HaruPage::endText' => ['bool'],
'HaruPage::eofill' => ['bool'],
'HaruPage::eoFillStroke' => ['bool', 'close_path='=>'bool'],
'HaruPage::fill' => ['bool'],
'HaruPage::fillStroke' => ['bool', 'close_path='=>'bool'],
'HaruPage::getCharSpace' => ['float'],
'HaruPage::getCMYKFill' => ['array'],
'HaruPage::getCMYKStroke' => ['array'],
'HaruPage::getCurrentFont' => ['object'],
'HaruPage::getCurrentFontSize' => ['float'],
'HaruPage::getCurrentPos' => ['array'],
'HaruPage::getCurrentTextPos' => ['array'],
'HaruPage::getDash' => ['array'],
'HaruPage::getFillingColorSpace' => ['int'],
'HaruPage::getFlatness' => ['float'],
'HaruPage::getGMode' => ['int'],
'HaruPage::getGrayFill' => ['float'],
'HaruPage::getGrayStroke' => ['float'],
'HaruPage::getHeight' => ['float'],
'HaruPage::getHorizontalScaling' => ['float'],
'HaruPage::getLineCap' => ['int'],
'HaruPage::getLineJoin' => ['int'],
'HaruPage::getLineWidth' => ['float'],
'HaruPage::getMiterLimit' => ['float'],
'HaruPage::getRGBFill' => ['array'],
'HaruPage::getRGBStroke' => ['array'],
'HaruPage::getStrokingColorSpace' => ['int'],
'HaruPage::getTextLeading' => ['float'],
'HaruPage::getTextMatrix' => ['array'],
'HaruPage::getTextRenderingMode' => ['int'],
'HaruPage::getTextRise' => ['float'],
'HaruPage::getTextWidth' => ['float', 'text'=>'string'],
'HaruPage::getTransMatrix' => ['array'],
'HaruPage::getWidth' => ['float'],
'HaruPage::getWordSpace' => ['float'],
'HaruPage::lineTo' => ['bool', 'x'=>'float', 'y'=>'float'],
'HaruPage::measureText' => ['int', 'text'=>'string', 'width'=>'float', 'wordwrap='=>'bool'],
'HaruPage::moveTextPos' => ['bool', 'x'=>'float', 'y'=>'float', 'set_leading='=>'bool'],
'HaruPage::moveTo' => ['bool', 'x'=>'float', 'y'=>'float'],
'HaruPage::moveToNextLine' => ['bool'],
'HaruPage::rectangle' => ['bool', 'x'=>'float', 'y'=>'float', 'width'=>'float', 'height'=>'float'],
'HaruPage::setCharSpace' => ['bool', 'char_space'=>'float'],
'HaruPage::setCMYKFill' => ['bool', 'c'=>'float', 'm'=>'float', 'y'=>'float', 'k'=>'float'],
'HaruPage::setCMYKStroke' => ['bool', 'c'=>'float', 'm'=>'float', 'y'=>'float', 'k'=>'float'],
'HaruPage::setDash' => ['bool', 'pattern'=>'array', 'phase'=>'int'],
'HaruPage::setFlatness' => ['bool', 'flatness'=>'float'],
'HaruPage::setFontAndSize' => ['bool', 'font'=>'object', 'size'=>'float'],
'HaruPage::setGrayFill' => ['bool', 'value'=>'float'],
'HaruPage::setGrayStroke' => ['bool', 'value'=>'float'],
'HaruPage::setHeight' => ['bool', 'height'=>'float'],
'HaruPage::setHorizontalScaling' => ['bool', 'scaling'=>'float'],
'HaruPage::setLineCap' => ['bool', 'cap'=>'int'],
'HaruPage::setLineJoin' => ['bool', 'join'=>'int'],
'HaruPage::setLineWidth' => ['bool', 'width'=>'float'],
'HaruPage::setMiterLimit' => ['bool', 'limit'=>'float'],
'HaruPage::setRGBFill' => ['bool', 'r'=>'float', 'g'=>'float', 'b'=>'float'],
'HaruPage::setRGBStroke' => ['bool', 'r'=>'float', 'g'=>'float', 'b'=>'float'],
'HaruPage::setRotate' => ['bool', 'angle'=>'int'],
'HaruPage::setSize' => ['bool', 'size'=>'int', 'direction'=>'int'],
'HaruPage::setSlideShow' => ['bool', 'type'=>'int', 'disp_time'=>'float', 'trans_time'=>'float'],
'HaruPage::setTextLeading' => ['bool', 'text_leading'=>'float'],
'HaruPage::setTextMatrix' => ['bool', 'a'=>'float', 'b'=>'float', 'c'=>'float', 'd'=>'float', 'x'=>'float', 'y'=>'float'],
'HaruPage::setTextRenderingMode' => ['bool', 'mode'=>'int'],
'HaruPage::setTextRise' => ['bool', 'rise'=>'float'],
'HaruPage::setWidth' => ['bool', 'width'=>'float'],
'HaruPage::setWordSpace' => ['bool', 'word_space'=>'float'],
'HaruPage::showText' => ['bool', 'text'=>'string'],
'HaruPage::showTextNextLine' => ['bool', 'text'=>'string', 'word_space='=>'float', 'char_space='=>'float'],
'HaruPage::stroke' => ['bool', 'close_path='=>'bool'],
'HaruPage::textOut' => ['bool', 'x'=>'float', 'y'=>'float', 'text'=>'string'],
'HaruPage::textRect' => ['bool', 'left'=>'float', 'top'=>'float', 'right'=>'float', 'bottom'=>'float', 'text'=>'string', 'align='=>'int'],
'hash' => ['string', 'algo'=>'string', 'data'=>'string', 'raw_output='=>'bool'],
'hash_algos' => ['array'],
'hash_copy' => ['HashContext', 'context'=>'HashContext'],
'hash_equals' => ['bool', 'known_string'=>'string', 'user_string'=>'string'],
'hash_file' => ['string', 'algo'=>'string', 'filename'=>'string', 'raw_output='=>'bool'],
'hash_final' => ['string', 'context'=>'HashContext', 'raw_output='=>'bool'],
'hash_hkdf' => ['string', 'algo'=>'string', 'ikm'=>'string', 'length='=>'int', 'info='=>'string', 'salt='=>'string'],
'hash_hmac' => ['string', 'algo'=>'string', 'data'=>'string', 'key'=>'string', 'raw_output='=>'bool'],
'hash_hmac_algos' => ['array'],
'hash_hmac_file' => ['string', 'algo'=>'string', 'filename'=>'string', 'key'=>'string', 'raw_output='=>'bool'],
'hash_init' => ['HashContext', 'algo'=>'string', 'options='=>'int', 'key='=>'string'],
'hash_pbkdf2' => ['string', 'algo'=>'string', 'password'=>'string', 'salt'=>'string', 'iterations'=>'int', 'length='=>'int', 'raw_output='=>'bool'],
'hash_update' => ['bool', 'context'=>'HashContext', 'data'=>'string'],
'hash_update_file' => ['bool', 'context='=>'HashContext', 'filename'=>'string', 'scontext='=>'?HashContext'],
'hash_update_stream' => ['int', 'context'=>'HashContext', 'handle'=>'resource', 'length='=>'int'],
'hashTableObj::clear' => ['void'],
'hashTableObj::get' => ['string', 'key'=>'string'],
'hashTableObj::nextkey' => ['string', 'previousKey'=>'string'],
'hashTableObj::remove' => ['int', 'key'=>'string'],
'hashTableObj::set' => ['int', 'key'=>'string', 'value'=>'string'],
'header' => ['void', 'header'=>'string', 'replace='=>'bool', 'http_response_code='=>'int'],
'header_register_callback' => ['bool', 'callback'=>'callable'],
'header_remove' => ['void', 'name='=>'string'],
'headers_list' => ['array'],
'headers_sent' => ['bool', '&w_file='=>'string', '&w_line='=>'int'],
'hebrev' => ['string', 'str'=>'string', 'max_chars_per_line='=>'int'],
'hebrevc' => ['string', 'str'=>'string', 'max_chars_per_line='=>'int'],
'hex2bin' => ['string|false', 'data'=>'string'],
'hexdec' => ['int|float', 'hexadecimal_number'=>'string'],
'highlight_file' => ['string|bool', 'file_name'=>'string', 'return='=>'bool'],
'highlight_string' => ['string|bool', 'string'=>'string', 'return='=>'bool'],
'HRTime\PerformanceCounter::getElapsedTicks' => ['int'],
'HRTime\PerformanceCounter::getFrequency' => ['int'],
'HRTime\PerformanceCounter::getLastElapsedTicks' => ['int'],
'HRTime\PerformanceCounter::getTicks' => ['int'],
'HRTime\PerformanceCounter::getTicksSince' => ['int', 'start'=>'int'],
'HRTime\PerformanceCounter::isRunning' => ['bool'],
'HRTime\PerformanceCounter::start' => ['void'],
'HRTime\PerformanceCounter::stop' => ['void'],
'HRTime\StopWatch::getElapsedTicks' => ['int'],
'HRTime\StopWatch::getElapsedTime' => ['float', 'unit='=>'int'],
'HRTime\StopWatch::getLastElapsedTicks' => ['int'],
'HRTime\StopWatch::getLastElapsedTime' => ['float', 'unit='=>'int'],
'HRTime\StopWatch::isRunning' => ['bool'],
'HRTime\StopWatch::start' => ['void'],
'HRTime\StopWatch::stop' => ['void'],
'html_entity_decode' => ['string', 'string'=>'string', 'quote_style='=>'int', 'encoding='=>'string'],
'htmlentities' => ['string', 'string'=>'string', 'quote_style='=>'int', 'encoding='=>'string', 'double_encode='=>'bool'],
'htmlspecialchars' => ['string', 'string'=>'string', 'quote_style='=>'int', 'encoding='=>'string', 'double_encode='=>'bool'],
'htmlspecialchars_decode' => ['string', 'string'=>'string', 'quote_style='=>'int'],
'http\Env\Request::__construct' => ['void'],
'http\Env\Request::getCookie' => ['mixed', 'name='=>'string', 'type='=>'mixed', 'defval='=>'mixed', 'delete='=>'bool|false'],
'http\Env\Request::getFiles' => ['array'],
'http\Env\Request::getForm' => ['mixed', 'name='=>'string', 'type='=>'mixed', 'defval='=>'mixed', 'delete='=>'bool|false'],
'http\Env\Request::getQuery' => ['mixed', 'name='=>'string', 'type='=>'mixed', 'defval='=>'mixed', 'delete='=>'bool|false'],
'http\Env\Response::__construct' => ['void'],
'http\Env\Response::__invoke' => ['bool', 'data'=>'string', 'ob_flags='=>'int'],
'http\Env\Response::isCachedByETag' => ['int', 'header_name='=>'string'],
'http\Env\Response::isCachedByLastModified' => ['int', 'header_name='=>'string'],
'http\Env\Response::send' => ['bool', 'stream='=>'resource'],
'http\Env\Response::setCacheControl' => ['http\Env\Response', 'cache_control'=>'string'],
'http\Env\Response::setContentDisposition' => ['http\Env\Response', 'disposition_params'=>'array'],
'http\Env\Response::setContentEncoding' => ['http\Env\Response', 'content_encoding'=>'int'],
'http\Env\Response::setContentType' => ['http\Env\Response', 'content_type'=>'string'],
'http\Env\Response::setCookie' => ['http\Env\Response', 'cookie'=>'mixed'],
'http\Env\Response::setEnvRequest' => ['http\Env\Response', 'env_request'=>'http\Message'],
'http\Env\Response::setEtag' => ['http\Env\Response', 'etag'=>'string'],
'http\Env\Response::setLastModified' => ['http\Env\Response', 'last_modified'=>'int'],
'http\Env\Response::setThrottleRate' => ['http\Env\Response', 'chunk_size'=>'int', 'delay='=>'float|int'],
'http\QueryString::__construct' => ['void', 'querystring'=>'string'],
'http\QueryString::__toString' => ['string'],
'http\QueryString::get' => ['', 'name='=>'string', 'type='=>'mixed', 'defval='=>'mixed', 'delete='=>'bool|false'],
'http\QueryString::getArray' => ['array', 'name'=>'string', 'defval='=>'mixed', 'delete='=>'bool|false'],
'http\QueryString::getBool' => ['bool', 'name'=>'string', 'defval='=>'mixed', 'delete='=>'bool|false'],
'http\QueryString::getFloat' => ['float', 'name'=>'string', 'defval='=>'mixed', 'delete='=>'bool|false'],
'http\QueryString::getGlobalInstance' => ['http\QueryString'],
'http\QueryString::getInt' => ['int', 'name'=>'string', 'defval='=>'mixed', 'delete='=>'bool|false'],
'http\QueryString::getIterator' => ['IteratorAggregate'],
'http\QueryString::getObject' => ['', 'name'=>'string', 'defval='=>'mixed', 'delete='=>'bool|false'],
'http\QueryString::getString' => ['string', 'name'=>'string', 'defval='=>'mixed', 'delete='=>'bool|false'],
'http\QueryString::mod' => ['http\QueryString', 'params='=>'mixed'],
'http\QueryString::offsetExists' => ['bool', 'offset'=>'mixed'],
'http\QueryString::offsetGet' => ['mixed', 'offset'=>'mixed'],
'http\QueryString::offsetSet' => ['void', 'offset'=>'mixed', 'value'=>'mixed'],
'http\QueryString::offsetUnset' => ['void', 'offset'=>'mixed'],
'http\QueryString::serialize' => ['string'],
'http\QueryString::set' => ['http\QueryString', 'params'=>'mixed'],
'http\QueryString::toArray' => ['mixed[]'],
'http\QueryString::toString' => ['string'],
'http\QueryString::unserialize' => ['void', 'serialized'=>''],
'http\QueryString::xlate' => ['http\QueryString'],
'http\Url::__construct' => ['void', 'old_url='=>'mixed', 'new_url='=>'mixed', 'flags='=>'int'],
'http\Url::__toString' => [''],
'http\Url::mod' => ['http\Url', 'parts'=>'mixed', 'flags='=>'float|int|mixed'],
'http\Url::toArray' => ['string[]'],
'http\Url::toString' => ['string'],
'http_build_cookie' => ['string', 'cookie'=>'array'],
'http_build_query' => ['string', 'querydata'=>'array|object', 'prefix='=>'?string', 'arg_separator='=>'string', 'enc_type='=>'int'],
'http_build_str' => ['string', 'query'=>'array', 'prefix='=>'?string', 'arg_separator='=>'string'],
'http_build_url' => ['string', 'url='=>'string|array', 'parts='=>'string|array', 'flags='=>'int', 'new_url='=>'array'],
'http_cache_etag' => ['bool', 'etag='=>'string'],
'http_cache_last_modified' => ['bool', 'timestamp_or_expires='=>'int'],
'http_chunked_decode' => ['string', 'encoded'=>'string'],
'http_date' => ['string', 'timestamp='=>'int'],
'http_deflate' => ['string', 'data'=>'string', 'flags='=>'int'],
'http_get' => ['string', 'url'=>'string', 'options='=>'array', 'info='=>'array'],
'http_get_request_body' => ['string'],
'http_get_request_body_stream' => ['resource'],
'http_get_request_headers' => ['array'],
'http_head' => ['string', 'url'=>'string', 'options='=>'array', 'info='=>'array'],
'http_inflate' => ['string', 'data'=>'string'],
'http_match_etag' => ['bool', 'etag'=>'string', 'for_range='=>'bool'],
'http_match_modified' => ['bool', 'timestamp='=>'int', 'for_range='=>'bool'],
'http_match_request_header' => ['bool', 'header'=>'string', 'value'=>'string', 'match_case='=>'bool'],
'http_negotiate_charset' => ['string', 'supported'=>'array', 'result='=>'array'],
'http_negotiate_content_type' => ['string', 'supported'=>'array', 'result='=>'array'],
'http_negotiate_language' => ['string', 'supported'=>'array', 'result='=>'array'],
'http_parse_cookie' => ['object', 'cookie'=>'string', 'flags='=>'int', 'allowed_extras='=>'array'],
'http_parse_headers' => ['array', 'header'=>'string'],
'http_parse_message' => ['object', 'message'=>'string'],
'http_parse_params' => ['object', 'param'=>'string', 'flags='=>'int'],
'http_persistent_handles_clean' => ['string', 'ident='=>'string'],
'http_persistent_handles_count' => ['object'],
'http_persistent_handles_ident' => ['string', 'ident='=>'string'],
'http_post_data' => ['string', 'url'=>'string', 'data'=>'string', 'options='=>'array', 'info='=>'array'],
'http_post_fields' => ['string', 'url'=>'string', 'data'=>'array', 'files='=>'array', 'options='=>'array', 'info='=>'array'],
'http_put_data' => ['string', 'url'=>'string', 'data'=>'string', 'options='=>'array', 'info='=>'array'],
'http_put_file' => ['string', 'url'=>'string', 'file'=>'string', 'options='=>'array', 'info='=>'array'],
'http_put_stream' => ['string', 'url'=>'string', 'stream'=>'', 'options='=>'array', 'info='=>'array'],
'http_redirect' => ['bool', 'url='=>'string', 'params='=>'array', 'session='=>'bool', 'status='=>'int'],
'http_request' => ['string', 'method'=>'int', 'url'=>'string', 'body='=>'string', 'options='=>'array', 'info='=>'array'],
'http_request_body_encode' => ['string', 'fields'=>'array', 'files'=>'array'],
'http_request_method_exists' => ['int', 'method'=>''],
'http_request_method_name' => ['string', 'method'=>'int'],
'http_request_method_register' => ['int', 'method'=>'string'],
'http_request_method_unregister' => ['bool', 'method'=>''],
'http_response_code' => ['int|bool', 'response_code='=>'int'],
'http_send_content_disposition' => ['bool', 'filename'=>'string', 'inline='=>'bool'],
'http_send_content_type' => ['bool', 'content_type='=>'string'],
'http_send_data' => ['bool', 'data'=>'string'],
'http_send_file' => ['bool', 'file'=>'string'],
'http_send_last_modified' => ['bool', 'timestamp='=>'int'],
'http_send_status' => ['bool', 'status'=>'int'],
'http_send_stream' => ['bool', 'stream'=>''],
'http_support' => ['int', 'feature='=>'int'],
'http_throttle' => ['', 'sec'=>'float', 'bytes='=>'int'],
'HttpDeflateStream::__construct' => ['void', 'flags='=>'int'],
'HttpDeflateStream::factory' => ['HttpDeflateStream', 'flags='=>'int', 'class_name='=>'string'],
'HttpDeflateStream::finish' => ['string', 'data='=>'string'],
'HttpDeflateStream::flush' => ['string', 'data='=>'string'],
'HttpDeflateStream::update' => ['string', 'data'=>'string'],
'HttpInflateStream::__construct' => ['void', 'flags='=>'int'],
'HttpInflateStream::factory' => ['HttpInflateStream', 'flags='=>'int', 'class_name='=>'string'],
'HttpInflateStream::finish' => ['string', 'data='=>'string'],
'HttpInflateStream::flush' => ['string', 'data='=>'string'],
'HttpInflateStream::update' => ['string', 'data'=>'string'],
'HttpMessage::__construct' => ['void', 'message='=>'string'],
'HttpMessage::__toString' => ['string'],
'HttpMessage::addHeaders' => ['', 'headers'=>'array', 'append='=>'bool'],
'HttpMessage::count' => ['int'],
'HttpMessage::current' => ['mixed'],
'HttpMessage::detach' => ['HttpMessage'],
'HttpMessage::factory' => ['HttpMessage', 'raw_message='=>'string', 'class_name='=>'string'],
'HttpMessage::fromEnv' => ['HttpMessage', 'message_type'=>'int', 'class_name='=>'string'],
'HttpMessage::fromString' => ['HttpMessage', 'raw_message='=>'string', 'class_name='=>'string'],
'HttpMessage::getBody' => ['string'],
'HttpMessage::getHeader' => ['string', 'header'=>'string'],
'HttpMessage::getHeaders' => ['array'],
'HttpMessage::getHttpVersion' => ['string'],
'HttpMessage::getInfo' => [''],
'HttpMessage::getParentMessage' => ['HttpMessage'],
'HttpMessage::getRequestMethod' => ['string'],
'HttpMessage::getRequestUrl' => ['string'],
'HttpMessage::getResponseCode' => ['int'],
'HttpMessage::getResponseStatus' => ['string'],
'HttpMessage::getType' => ['int'],
'HttpMessage::guessContentType' => ['string', 'magic_file'=>'string', 'magic_mode='=>'int'],
'HttpMessage::key' => ['int|string'],
'HttpMessage::next' => ['void'],
'HttpMessage::prepend' => ['', 'message'=>'httpmessage', 'top='=>'bool'],
'HttpMessage::reverse' => ['HttpMessage'],
'HttpMessage::rewind' => ['void'],
'HttpMessage::send' => ['bool'],
'HttpMessage::serialize' => ['string'],
'HttpMessage::setBody' => ['', 'body'=>'string'],
'HttpMessage::setHeaders' => ['', 'headers'=>'array'],
'HttpMessage::setHttpVersion' => ['bool', 'version'=>'string'],
'HttpMessage::setInfo' => ['', 'http_info'=>''],
'HttpMessage::setRequestMethod' => ['bool', 'method'=>'string'],
'HttpMessage::setRequestUrl' => ['bool', 'url'=>'string'],
'HttpMessage::setResponseCode' => ['bool', 'code'=>'int'],
'HttpMessage::setResponseStatus' => ['bool', 'status'=>'string'],
'HttpMessage::setType' => ['', 'type'=>'int'],
'HttpMessage::toMessageTypeObject' => ['HttpRequest|HttpResponse'],
'HttpMessage::toString' => ['string', 'include_parent='=>'bool'],
'HttpMessage::unserialize' => ['void', 'serialized'=>''],
'HttpMessage::valid' => ['bool'],
'HttpQueryString::__construct' => ['void', 'global='=>'bool', 'add='=>''],
'HttpQueryString::__toString' => ['string'],
'HttpQueryString::factory' => ['', 'global'=>'', 'params'=>'', 'class_name'=>''],
'HttpQueryString::get' => ['', 'key='=>'string', 'type='=>'', 'defval='=>'', 'delete='=>'bool'],
'HttpQueryString::getArray' => ['', 'name'=>'', 'defval'=>'', 'delete'=>''],
'HttpQueryString::getBool' => ['', 'name'=>'', 'defval'=>'', 'delete'=>''],
'HttpQueryString::getFloat' => ['', 'name'=>'', 'defval'=>'', 'delete'=>''],
'HttpQueryString::getInt' => ['', 'name'=>'', 'defval'=>'', 'delete'=>''],
'HttpQueryString::getObject' => ['', 'name'=>'', 'defval'=>'', 'delete'=>''],
'HttpQueryString::getString' => ['', 'name'=>'', 'defval'=>'', 'delete'=>''],
'HttpQueryString::mod' => ['HttpQueryString', 'params'=>''],
'HttpQueryString::offsetExists' => ['bool', 'offset'=>'mixed'],
'HttpQueryString::offsetGet' => ['mixed', 'offset'=>'mixed'],
'HttpQueryString::offsetSet' => ['void', 'offset'=>'mixed', 'value'=>'mixed'],
'HttpQueryString::offsetUnset' => ['void', 'offset'=>'mixed'],
'HttpQueryString::serialize' => ['string'],
'HttpQueryString::set' => ['string', 'params'=>''],
'HttpQueryString::singleton' => ['HttpQueryString', 'global='=>'bool'],
'HttpQueryString::toArray' => ['array'],
'HttpQueryString::toString' => ['string'],
'HttpQueryString::unserialize' => ['void', 'serialized'=>'string'],
'HttpQueryString::xlate' => ['bool', 'ie'=>'string', 'oe'=>'string'],
'HttpRequest::__construct' => ['void', 'url='=>'string', 'request_method='=>'int', 'options='=>'array'],
'HttpRequest::addBody' => ['', 'request_body_data'=>''],
'HttpRequest::addCookies' => ['bool', 'cookies'=>'array'],
'HttpRequest::addHeaders' => ['bool', 'headers'=>'array'],
'HttpRequest::addPostFields' => ['bool', 'post_data'=>'array'],
'HttpRequest::addPostFile' => ['bool', 'name'=>'string', 'file'=>'string', 'content_type='=>'string'],
'HttpRequest::addPutData' => ['bool', 'put_data'=>'string'],
'HttpRequest::addQueryData' => ['bool', 'query_params'=>'array'],
'HttpRequest::addRawPostData' => ['bool', 'raw_post_data'=>'string'],
'HttpRequest::addSslOptions' => ['bool', 'options'=>'array'],
'HttpRequest::clearHistory' => [''],
'HttpRequest::enableCookies' => ['bool'],
'HttpRequest::encodeBody' => ['', 'fields'=>'', 'files'=>''],
'HttpRequest::factory' => ['', 'url'=>'', 'method'=>'', 'options'=>'', 'class_name'=>''],
'HttpRequest::flushCookies' => [''],
'HttpRequest::get' => ['', 'url'=>'', 'options'=>'', '&info'=>''],
'HttpRequest::getBody' => [''],
'HttpRequest::getContentType' => ['string'],
'HttpRequest::getCookies' => ['array'],
'HttpRequest::getHeaders' => ['array'],
'HttpRequest::getHistory' => ['HttpMessage'],
'HttpRequest::getMethod' => ['int'],
'HttpRequest::getOptions' => ['array'],
'HttpRequest::getPostFields' => ['array'],
'HttpRequest::getPostFiles' => ['array'],
'HttpRequest::getPutData' => ['string'],
'HttpRequest::getPutFile' => ['string'],
'HttpRequest::getQueryData' => ['string'],
'HttpRequest::getRawPostData' => ['string'],
'HttpRequest::getRawRequestMessage' => ['string'],
'HttpRequest::getRawResponseMessage' => ['string'],
'HttpRequest::getRequestMessage' => ['HttpMessage'],
'HttpRequest::getResponseBody' => ['string'],
'HttpRequest::getResponseCode' => ['int'],
'HttpRequest::getResponseCookies' => ['array', 'flags='=>'int', 'allowed_extras='=>'array'],
'HttpRequest::getResponseData' => ['array'],
'HttpRequest::getResponseHeader' => ['', 'name='=>'string'],
'HttpRequest::getResponseInfo' => ['', 'name='=>'string'],
'HttpRequest::getResponseMessage' => ['HttpMessage'],
'HttpRequest::getResponseStatus' => ['string'],
'HttpRequest::getSslOptions' => ['array'],
'HttpRequest::getUrl' => ['string'],
'HttpRequest::head' => ['', 'url'=>'', 'options'=>'', '&info'=>''],
'HttpRequest::methodExists' => ['', 'method'=>''],
'HttpRequest::methodName' => ['', 'method_id'=>''],
'HttpRequest::methodRegister' => ['', 'method_name'=>''],
'HttpRequest::methodUnregister' => ['', 'method'=>''],
'HttpRequest::postData' => ['', 'url'=>'', 'data'=>'', 'options'=>'', '&info'=>''],
'HttpRequest::postFields' => ['', 'url'=>'', 'data'=>'', 'options'=>'', '&info'=>''],
'HttpRequest::putData' => ['', 'url'=>'', 'data'=>'', 'options'=>'', '&info'=>''],
'HttpRequest::putFile' => ['', 'url'=>'', 'file'=>'', 'options'=>'', '&info'=>''],
'HttpRequest::putStream' => ['', 'url'=>'', 'stream'=>'', 'options'=>'', '&info'=>''],
'HttpRequest::resetCookies' => ['bool', 'session_only='=>'bool'],
'HttpRequest::send' => ['HttpMessage'],
'HttpRequest::setBody' => ['bool', 'request_body_data='=>'string'],
'HttpRequest::setContentType' => ['bool', 'content_type'=>'string'],
'HttpRequest::setCookies' => ['bool', 'cookies='=>'array'],
'HttpRequest::setHeaders' => ['bool', 'headers='=>'array'],
'HttpRequest::setMethod' => ['bool', 'request_method'=>'int'],
'HttpRequest::setOptions' => ['bool', 'options='=>'array'],
'HttpRequest::setPostFields' => ['bool', 'post_data'=>'array'],
'HttpRequest::setPostFiles' => ['bool', 'post_files'=>'array'],
'HttpRequest::setPutData' => ['bool', 'put_data='=>'string'],
'HttpRequest::setPutFile' => ['bool', 'file='=>'string'],
'HttpRequest::setQueryData' => ['bool', 'query_data'=>''],
'HttpRequest::setRawPostData' => ['bool', 'raw_post_data='=>'string'],
'HttpRequest::setSslOptions' => ['bool', 'options='=>'array'],
'HttpRequest::setUrl' => ['bool', 'url'=>'string'],
'HttpRequestDataShare::__construct' => ['void'],
'HttpRequestDataShare::__destruct' => [''],
'HttpRequestDataShare::attach' => ['', 'request'=>'HttpRequest'],
'HttpRequestDataShare::count' => ['int'],
'HttpRequestDataShare::detach' => ['', 'request'=>'HttpRequest'],
'HttpRequestDataShare::factory' => ['', 'global'=>'', 'class_name'=>''],
'HttpRequestDataShare::reset' => [''],
'HttpRequestDataShare::singleton' => ['', 'global'=>''],
'HttpRequestPool::__construct' => ['void', 'request='=>'httprequest'],
'HttpRequestPool::__destruct' => [''],
'HttpRequestPool::attach' => ['bool', 'request'=>'httprequest'],
'HttpRequestPool::count' => ['int'],
'HttpRequestPool::current' => ['mixed'],
'HttpRequestPool::detach' => ['bool', 'request'=>'httprequest'],
'HttpRequestPool::enableEvents' => ['', 'enable'=>''],
'HttpRequestPool::enablePipelining' => ['', 'enable'=>''],
'HttpRequestPool::getAttachedRequests' => ['array'],
'HttpRequestPool::getFinishedRequests' => ['array'],
'HttpRequestPool::key' => ['int|string'],
'HttpRequestPool::next' => ['void'],
'HttpRequestPool::reset' => [''],
'HttpRequestPool::rewind' => ['void'],
'HttpRequestPool::send' => ['bool'],
'HttpRequestPool::socketPerform' => ['bool'],
'HttpRequestPool::socketSelect' => ['bool', 'timeout='=>'float'],
'HttpRequestPool::valid' => ['bool'],
'HttpResponse::capture' => [''],
'HttpResponse::getBufferSize' => ['int'],
'HttpResponse::getCache' => ['bool'],
'HttpResponse::getCacheControl' => ['string'],
'HttpResponse::getContentDisposition' => ['string'],
'HttpResponse::getContentType' => ['string'],
'HttpResponse::getData' => ['string'],
'HttpResponse::getETag' => ['string'],
'HttpResponse::getFile' => ['string'],
'HttpResponse::getGzip' => ['bool'],
'HttpResponse::getHeader' => ['', 'name='=>'string'],
'HttpResponse::getLastModified' => ['int'],
'HttpResponse::getRequestBody' => ['string'],
'HttpResponse::getRequestBodyStream' => ['resource'],
'HttpResponse::getRequestHeaders' => ['array'],
'HttpResponse::getStream' => ['resource'],
'HttpResponse::getThrottleDelay' => ['float'],
'HttpResponse::guessContentType' => ['string', 'magic_file'=>'string', 'magic_mode='=>'int'],
'HttpResponse::redirect' => ['', 'url='=>'string', 'params='=>'array', 'session='=>'bool', 'status='=>'int'],
'HttpResponse::send' => ['bool', 'clean_ob='=>'bool'],
'HttpResponse::setBufferSize' => ['bool', 'bytes'=>'int'],
'HttpResponse::setCache' => ['bool', 'cache'=>'bool'],
'HttpResponse::setCacheControl' => ['bool', 'control'=>'string', 'max_age='=>'int', 'must_revalidate='=>'bool'],
'HttpResponse::setContentDisposition' => ['bool', 'filename'=>'string', 'inline='=>'bool'],
'HttpResponse::setContentType' => ['bool', 'content_type'=>'string'],
'HttpResponse::setData' => ['bool', 'data'=>''],
'HttpResponse::setETag' => ['bool', 'etag'=>'string'],
'HttpResponse::setFile' => ['bool', 'file'=>'string'],
'HttpResponse::setGzip' => ['bool', 'gzip'=>'bool'],
'HttpResponse::setHeader' => ['bool', 'name'=>'string', 'value='=>'', 'replace='=>'bool'],
'HttpResponse::setLastModified' => ['bool', 'timestamp'=>'int'],
'HttpResponse::setStream' => ['bool', 'stream'=>''],
'HttpResponse::setThrottleDelay' => ['bool', 'seconds'=>'float'],
'HttpResponse::status' => ['bool', 'status'=>'int'],
'HttpUtil::buildCookie' => ['', 'cookie_array'=>''],
'HttpUtil::buildStr' => ['', 'query'=>'', 'prefix'=>'', 'arg_sep'=>''],
'HttpUtil::buildUrl' => ['', 'url'=>'', 'parts'=>'', 'flags'=>'', '&composed'=>''],
'HttpUtil::chunkedDecode' => ['', 'encoded_string'=>''],
'HttpUtil::date' => ['', 'timestamp'=>''],
'HttpUtil::deflate' => ['', 'plain'=>'', 'flags'=>''],
'HttpUtil::inflate' => ['', 'encoded'=>''],
'HttpUtil::matchEtag' => ['', 'plain_etag'=>'', 'for_range'=>''],
'HttpUtil::matchModified' => ['', 'last_modified'=>'', 'for_range'=>''],
'HttpUtil::matchRequestHeader' => ['', 'header_name'=>'', 'header_value'=>'', 'case_sensitive'=>''],
'HttpUtil::negotiateCharset' => ['', 'supported'=>'', '&result'=>''],
'HttpUtil::negotiateContentType' => ['', 'supported'=>'', '&result'=>''],
'HttpUtil::negotiateLanguage' => ['', 'supported'=>'', '&result'=>''],
'HttpUtil::parseCookie' => ['', 'cookie_string'=>''],
'HttpUtil::parseHeaders' => ['', 'headers_string'=>''],
'HttpUtil::parseMessage' => ['', 'message_string'=>''],
'HttpUtil::parseParams' => ['', 'param_string'=>'', 'flags'=>''],
'HttpUtil::support' => ['', 'feature'=>''],
'hw_api::checkin' => ['bool', 'parameter'=>'array'],
'hw_api::checkout' => ['bool', 'parameter'=>'array'],
'hw_api::children' => ['array', 'parameter'=>'array'],
'hw_api::content' => ['HW_API_Content', 'parameter'=>'array'],
'hw_api::copy' => ['hw_api_content', 'parameter'=>'array'],
'hw_api::dbstat' => ['hw_api_object', 'parameter'=>'array'],
'hw_api::dcstat' => ['hw_api_object', 'parameter'=>'array'],
'hw_api::dstanchors' => ['array', 'parameter'=>'array'],
'hw_api::dstofsrcanchor' => ['hw_api_object', 'parameter'=>'array'],
'hw_api::find' => ['array', 'parameter'=>'array'],
'hw_api::ftstat' => ['hw_api_object', 'parameter'=>'array'],
'hw_api::hwstat' => ['hw_api_object', 'parameter'=>'array'],
'hw_api::identify' => ['bool', 'parameter'=>'array'],
'hw_api::info' => ['array', 'parameter'=>'array'],
'hw_api::insert' => ['hw_api_object', 'parameter'=>'array'],
'hw_api::insertanchor' => ['hw_api_object', 'parameter'=>'array'],
'hw_api::insertcollection' => ['hw_api_object', 'parameter'=>'array'],
'hw_api::insertdocument' => ['hw_api_object', 'parameter'=>'array'],
'hw_api::link' => ['bool', 'parameter'=>'array'],
'hw_api::lock' => ['bool', 'parameter'=>'array'],
'hw_api::move' => ['bool', 'parameter'=>'array'],
'hw_api::object' => ['hw_api_object', 'parameter'=>'array'],
'hw_api::objectbyanchor' => ['hw_api_object', 'parameter'=>'array'],
'hw_api::parents' => ['array', 'parameter'=>'array'],
'hw_api::remove' => ['bool', 'parameter'=>'array'],
'hw_api::replace' => ['hw_api_object', 'parameter'=>'array'],
'hw_api::setcommittedversion' => ['hw_api_object', 'parameter'=>'array'],
'hw_api::srcanchors' => ['array', 'parameter'=>'array'],
'hw_api::srcsofdst' => ['array', 'parameter'=>'array'],
'hw_api::unlock' => ['bool', 'parameter'=>'array'],
'hw_api::user' => ['hw_api_object', 'parameter'=>'array'],
'hw_api::userlist' => ['array', 'parameter'=>'array'],
'hw_api_attribute' => ['HW_API_Attribute', 'name='=>'string', 'value='=>'string'],
'hw_api_attribute::key' => ['string'],
'hw_api_attribute::langdepvalue' => ['string', 'language'=>'string'],
'hw_api_attribute::value' => ['string'],
'hw_api_attribute::values' => ['array'],
'hw_api_content' => ['HW_API_Content', 'content'=>'string', 'mimetype'=>'string'],
'hw_api_content::mimetype' => ['string'],
'hw_api_content::read' => ['string', 'buffer'=>'string', 'len'=>'int'],
'hw_api_error::count' => ['int'],
'hw_api_error::reason' => ['HW_API_Reason'],
'hw_api_object' => ['hw_api_object', 'parameter'=>'array'],
'hw_api_object::assign' => ['bool', 'parameter'=>'array'],
'hw_api_object::attreditable' => ['bool', 'parameter'=>'array'],
'hw_api_object::count' => ['int', 'parameter'=>'array'],
'hw_api_object::insert' => ['bool', 'attribute'=>'hw_api_attribute'],
'hw_api_object::remove' => ['bool', 'name'=>'string'],
'hw_api_object::title' => ['string', 'parameter'=>'array'],
'hw_api_object::value' => ['string', 'name'=>'string'],
'hw_api_reason::description' => ['string'],
'hw_api_reason::type' => ['HW_API_Reason'],
'hw_Array2Objrec' => ['string', 'object_array'=>'array'],
'hw_changeobject' => ['bool', 'link'=>'int', 'objid'=>'int', 'attributes'=>'array'],
'hw_Children' => ['array', 'connection'=>'int', 'objectid'=>'int'],
'hw_ChildrenObj' => ['array', 'connection'=>'int', 'objectid'=>'int'],
'hw_Close' => ['bool', 'connection'=>'int'],
'hw_Connect' => ['int', 'host'=>'string', 'port'=>'int', 'username='=>'string', 'password='=>'string'],
'hw_connection_info' => ['', 'link'=>'int'],
'hw_cp' => ['int', 'connection'=>'int', 'object_id_array'=>'array', 'destination_id'=>'int'],
'hw_Deleteobject' => ['bool', 'connection'=>'int', 'object_to_delete'=>'int'],
'hw_DocByAnchor' => ['int', 'connection'=>'int', 'anchorid'=>'int'],
'hw_DocByAnchorObj' => ['string', 'connection'=>'int', 'anchorid'=>'int'],
'hw_Document_Attributes' => ['string', 'hw_document'=>'int'],
'hw_Document_BodyTag' => ['string', 'hw_document'=>'int', 'prefix='=>'string'],
'hw_Document_Content' => ['string', 'hw_document'=>'int'],
'hw_Document_SetContent' => ['bool', 'hw_document'=>'int', 'content'=>'string'],
'hw_Document_Size' => ['int', 'hw_document'=>'int'],
'hw_dummy' => ['string', 'link'=>'int', 'id'=>'int', 'msgid'=>'int'],
'hw_EditText' => ['bool', 'connection'=>'int', 'hw_document'=>'int'],
'hw_Error' => ['int', 'connection'=>'int'],
'hw_ErrorMsg' => ['string', 'connection'=>'int'],
'hw_Free_Document' => ['bool', 'hw_document'=>'int'],
'hw_GetAnchors' => ['array', 'connection'=>'int', 'objectid'=>'int'],
'hw_GetAnchorsObj' => ['array', 'connection'=>'int', 'objectid'=>'int'],
'hw_GetAndLock' => ['string', 'connection'=>'int', 'objectid'=>'int'],
'hw_GetChildColl' => ['array', 'connection'=>'int', 'objectid'=>'int'],
'hw_GetChildCollObj' => ['array', 'connection'=>'int', 'objectid'=>'int'],
'hw_GetChildDocColl' => ['array', 'connection'=>'int', 'objectid'=>'int'],
'hw_GetChildDocCollObj' => ['array', 'connection'=>'int', 'objectid'=>'int'],
'hw_GetObject' => ['', 'connection'=>'int', 'objectid'=>'', 'query='=>'string'],
'hw_GetObjectByQuery' => ['array', 'connection'=>'int', 'query'=>'string', 'max_hits'=>'int'],
'hw_GetObjectByQueryColl' => ['array', 'connection'=>'int', 'objectid'=>'int', 'query'=>'string', 'max_hits'=>'int'],
'hw_GetObjectByQueryCollObj' => ['array', 'connection'=>'int', 'objectid'=>'int', 'query'=>'string', 'max_hits'=>'int'],
'hw_GetObjectByQueryObj' => ['array', 'connection'=>'int', 'query'=>'string', 'max_hits'=>'int'],
'hw_GetParents' => ['array', 'connection'=>'int', 'objectid'=>'int'],
'hw_GetParentsObj' => ['array', 'connection'=>'int', 'objectid'=>'int'],
'hw_getrellink' => ['string', 'link'=>'int', 'rootid'=>'int', 'sourceid'=>'int', 'destid'=>'int'],
'hw_GetRemote' => ['int', 'connection'=>'int', 'objectid'=>'int'],
'hw_getremotechildren' => ['', 'connection'=>'int', 'object_record'=>'string'],
'hw_GetSrcByDestObj' => ['array', 'connection'=>'int', 'objectid'=>'int'],
'hw_GetText' => ['int', 'connection'=>'int', 'objectid'=>'int', 'prefix='=>''],
'hw_getusername' => ['string', 'connection'=>'int'],
'hw_Identify' => ['string', 'link'=>'int', 'username'=>'string', 'password'=>'string'],
'hw_InCollections' => ['array', 'connection'=>'int', 'object_id_array'=>'array', 'collection_id_array'=>'array', 'return_collections'=>'int'],
'hw_Info' => ['string', 'connection'=>'int'],
'hw_InsColl' => ['int', 'connection'=>'int', 'objectid'=>'int', 'object_array'=>'array'],
'hw_InsDoc' => ['int', 'connection'=>'', 'parentid'=>'int', 'object_record'=>'string', 'text='=>'string'],
'hw_insertanchors' => ['bool', 'hwdoc'=>'int', 'anchorecs'=>'array', 'dest'=>'array', 'urlprefixes='=>'array'],
'hw_InsertDocument' => ['int', 'connection'=>'int', 'parent_id'=>'int', 'hw_document'=>'int'],
'hw_InsertObject' => ['int', 'connection'=>'int', 'object_rec'=>'string', 'parameter'=>'string'],
'hw_mapid' => ['int', 'connection'=>'int', 'server_id'=>'int', 'object_id'=>'int'],
'hw_Modifyobject' => ['bool', 'connection'=>'int', 'object_to_change'=>'int', 'remove'=>'array', 'add'=>'array', 'mode='=>'int'],
'hw_mv' => ['int', 'connection'=>'int', 'object_id_array'=>'array', 'source_id'=>'int', 'destination_id'=>'int'],
'hw_New_Document' => ['int', 'object_record'=>'string', 'document_data'=>'string', 'document_size'=>'int'],
'hw_objrec2array' => ['array', 'object_record'=>'string', 'format='=>'array'],
'hw_Output_Document' => ['bool', 'hw_document'=>'int'],
'hw_pConnect' => ['int', 'host'=>'string', 'port'=>'int', 'username='=>'string', 'password='=>'string'],
'hw_PipeDocument' => ['int', 'connection'=>'int', 'objectid'=>'int', 'url_prefixes='=>'array'],
'hw_Root' => ['int'],
'hw_setlinkroot' => ['int', 'link'=>'int', 'rootid'=>'int'],
'hw_stat' => ['string', 'link'=>'int'],
'hw_Unlock' => ['bool', 'connection'=>'int', 'objectid'=>'int'],
'hw_Who' => ['array', 'connection'=>'int'],
'hwapi_attribute_new' => ['HW_API_Attribute', 'name='=>'string', 'value='=>'string'],
'hwapi_content_new' => ['HW_API_Content', 'content'=>'string', 'mimetype'=>'string'],
'hwapi_hgcsp' => ['HW_API', 'hostname'=>'string', 'port='=>'int'],
'hwapi_object_new' => ['hw_api_object', 'parameter'=>'array'],
'hypot' => ['float', 'num1'=>'float', 'num2'=>'float'],
'ibase_add_user' => ['bool', 'service_handle'=>'resource', 'user_name'=>'string', 'password'=>'string', 'first_name='=>'string', 'middle_name='=>'string', 'last_name='=>'string'],
'ibase_affected_rows' => ['int', 'link_identifier='=>'resource'],
'ibase_backup' => ['mixed', 'service_handle'=>'resource', 'source_db'=>'string', 'dest_file'=>'string', 'options='=>'int', 'verbose='=>'bool'],
'ibase_blob_add' => ['bool', 'blob_handle'=>'resource', 'data'=>'string'],
'ibase_blob_cancel' => ['bool', 'blob_handle'=>'resource'],
'ibase_blob_close' => ['string', 'blob_handle'=>'resource'],
'ibase_blob_create' => ['resource', 'link_identifier='=>'resource'],
'ibase_blob_echo' => ['bool', 'link_identifier'=>'', 'blob_id'=>'string'],
'ibase_blob_echo\'1' => ['bool', 'blob_id'=>'string'],
'ibase_blob_get' => ['string', 'blob_handle'=>'resource', 'len'=>'int'],
'ibase_blob_import' => ['string', 'link_identifier'=>'', 'file_handle'=>''],
'ibase_blob_info' => ['array', 'link_identifier'=>'', 'blob_id'=>'string'],
'ibase_blob_info\'1' => ['array', 'blob_id'=>'string'],
'ibase_blob_open' => ['resource', 'link_identifier'=>'', 'blob_id'=>'string'],
'ibase_blob_open\'1' => ['resource', 'blob_id'=>'string'],
'ibase_close' => ['bool', 'link_identifier='=>'resource'],
'ibase_commit' => ['bool', 'link_identifier='=>'resource'],
'ibase_commit_ret' => ['bool', 'link_identifier='=>'resource'],
'ibase_connect' => ['resource', 'database='=>'string', 'username='=>'string', 'password='=>'string', 'charset='=>'string', 'buffers='=>'int', 'dialect='=>'int', 'role='=>'string'],
'ibase_db_info' => ['string', 'service_handle'=>'resource', 'db'=>'string', 'action'=>'int', 'argument='=>'int'],
'ibase_delete_user' => ['bool', 'service_handle'=>'resource', 'user_name'=>'string', 'password='=>'string', 'first_name='=>'string', 'middle_name='=>'string', 'last_name='=>'string'],
'ibase_drop_db' => ['bool', 'link_identifier='=>'resource'],
'ibase_errcode' => ['int'],
'ibase_errmsg' => ['string'],
'ibase_execute' => ['resource', 'query'=>'resource', 'bind_arg='=>'mixed', '...args='=>'mixed'],
'ibase_fetch_assoc' => ['array', 'result'=>'resource', 'fetch_flags='=>'int'],
'ibase_fetch_object' => ['object', 'result'=>'resource', 'fetch_flags='=>'int'],
'ibase_fetch_row' => ['array', 'result'=>'resource', 'fetch_flags='=>'int'],
'ibase_field_info' => ['array', 'query_result'=>'resource', 'field_number'=>'int'],
'ibase_free_event_handler' => ['bool', 'event'=>'resource'],
'ibase_free_query' => ['bool', 'query'=>'resource'],
'ibase_free_result' => ['bool', 'result'=>'resource'],
'ibase_gen_id' => ['int', 'generator'=>'string', 'increment='=>'int', 'link_identifier='=>'resource'],
'ibase_maintain_db' => ['bool', 'service_handle'=>'resource', 'db'=>'string', 'action'=>'int', 'argument='=>'int'],
'ibase_modify_user' => ['bool', 'service_handle'=>'resource', 'user_name'=>'string', 'password'=>'string', 'first_name='=>'string', 'middle_name='=>'string', 'last_name='=>'string'],
'ibase_name_result' => ['bool', 'result'=>'resource', 'name'=>'string'],
'ibase_num_fields' => ['int', 'query_result'=>'resource'],
'ibase_num_params' => ['int', 'query'=>'resource'],
'ibase_num_rows' => ['int', 'result_identifier'=>''],
'ibase_param_info' => ['array', 'query'=>'resource', 'field_number'=>'int'],
'ibase_pconnect' => ['resource', 'database='=>'string', 'username='=>'string', 'password='=>'string', 'charset='=>'string', 'buffers='=>'int', 'dialect='=>'int', 'role='=>'string'],
'ibase_prepare' => ['resource', 'link_identifier'=>'', 'query'=>'string', 'trans_identifier'=>''],
'ibase_query' => ['resource', 'link_identifier='=>'resource', 'string='=>'string', 'bind_arg='=>'int', '...args='=>''],
'ibase_restore' => ['mixed', 'service_handle'=>'resource', 'source_file'=>'string', 'dest_db'=>'string', 'options='=>'int', 'verbose='=>'bool'],
'ibase_rollback' => ['bool', 'link_identifier='=>'resource'],
'ibase_rollback_ret' => ['bool', 'link_identifier='=>'resource'],
'ibase_server_info' => ['string', 'service_handle'=>'resource', 'action'=>'int'],
'ibase_service_attach' => ['resource', 'host'=>'string', 'dba_username'=>'string', 'dba_password'=>'string'],
'ibase_service_detach' => ['bool', 'service_handle'=>'resource'],
'ibase_set_event_handler' => ['resource', 'link_identifier'=>'', 'callback'=>'callable', 'event='=>'string', '...args='=>''],
'ibase_set_event_handler\'1' => ['resource', 'callback'=>'callable', 'event'=>'string', '...args'=>''],
'ibase_timefmt' => ['bool', 'format'=>'string', 'columntype='=>'int'],
'ibase_trans' => ['resource', 'trans_args='=>'int', 'link_identifier='=>'', '...args='=>''],
'ibase_wait_event' => ['string', 'link_identifier'=>'', 'event='=>'string', '...args='=>''],
'ibase_wait_event\'1' => ['string', 'event'=>'string', '...args'=>''],
'iconv' => ['string|false', 'in_charset'=>'string', 'out_charset'=>'string', 'str'=>'string'],
'iconv_get_encoding' => ['mixed', 'type='=>'string'],
'iconv_mime_decode' => ['string', 'encoded_string'=>'string', 'mode='=>'int', 'charset='=>'string'],
'iconv_mime_decode_headers' => ['array', 'headers'=>'string', 'mode='=>'int', 'charset='=>'string'],
'iconv_mime_encode' => ['string', 'field_name'=>'string', 'field_value'=>'string', 'preference='=>'array'],
'iconv_set_encoding' => ['bool', 'type'=>'string', 'charset'=>'string'],
'iconv_strlen' => ['int', 'str'=>'string', 'charset='=>'string'],
'iconv_strpos' => ['int', 'haystack'=>'string', 'needle'=>'string', 'offset='=>'int', 'charset='=>'string'],
'iconv_strrpos' => ['int', 'haystack'=>'string', 'needle'=>'string', 'charset='=>'string'],
'iconv_substr' => ['string', 'str'=>'string', 'offset'=>'int', 'length='=>'int', 'charset='=>'string'],
'id3_get_frame_long_name' => ['string', 'frameid'=>'string'],
'id3_get_frame_short_name' => ['string', 'frameid'=>'string'],
'id3_get_genre_id' => ['int', 'genre'=>'string'],
'id3_get_genre_list' => ['array'],
'id3_get_genre_name' => ['string', 'genre_id'=>'int'],
'id3_get_tag' => ['array', 'filename'=>'string', 'version='=>'int'],
'id3_get_version' => ['int', 'filename'=>'string'],
'id3_remove_tag' => ['bool', 'filename'=>'string', 'version='=>'int'],
'id3_set_tag' => ['bool', 'filename'=>'string', 'tag'=>'array', 'version='=>'int'],
'idate' => ['int', 'format'=>'string', 'timestamp='=>'int'],
'idn_strerror' => ['string', 'errorcode'=>'int'],
'idn_to_ascii' => ['string|false', 'domain'=>'string', 'options='=>'int', 'variant='=>'int', '&w_idna_info='=>'array'],
'idn_to_utf8' => ['string|false', 'domain'=>'string', 'options='=>'int', 'variant='=>'int', '&w_idna_info='=>'array'],
'ifx_affected_rows' => ['int', 'result_id'=>'resource'],
'ifx_blobinfile_mode' => ['bool', 'mode'=>'int'],
'ifx_byteasvarchar' => ['bool', 'mode'=>'int'],
'ifx_close' => ['bool', 'link_identifier='=>'resource'],
'ifx_connect' => ['resource', 'database='=>'string', 'userid='=>'string', 'password='=>'string'],
'ifx_copy_blob' => ['int', 'bid'=>'int'],
'ifx_create_blob' => ['int', 'type'=>'int', 'mode'=>'int', 'param'=>'string'],
'ifx_create_char' => ['int', 'param'=>'string'],
'ifx_do' => ['bool', 'result_id'=>'resource'],
'ifx_error' => ['string', 'link_identifier='=>'resource'],
'ifx_errormsg' => ['string', 'errorcode='=>'int'],
'ifx_fetch_row' => ['array', 'result_id'=>'resource', 'position='=>'mixed'],
'ifx_fieldproperties' => ['array', 'result_id'=>'resource'],
'ifx_fieldtypes' => ['array', 'result_id'=>'resource'],
'ifx_free_blob' => ['bool', 'bid'=>'int'],
'ifx_free_char' => ['bool', 'bid'=>'int'],
'ifx_free_result' => ['bool', 'result_id'=>'resource'],
'ifx_get_blob' => ['string', 'bid'=>'int'],
'ifx_get_char' => ['string', 'bid'=>'int'],
'ifx_getsqlca' => ['array', 'result_id'=>'resource'],
'ifx_htmltbl_result' => ['int', 'result_id'=>'resource', 'html_table_options='=>'string'],
'ifx_nullformat' => ['bool', 'mode'=>'int'],
'ifx_num_fields' => ['int', 'result_id'=>'resource'],
'ifx_num_rows' => ['int', 'result_id'=>'resource'],
'ifx_pconnect' => ['resource', 'database='=>'string', 'userid='=>'string', 'password='=>'string'],
'ifx_prepare' => ['resource', 'query'=>'string', 'link_identifier'=>'resource', 'cursor_def='=>'int', 'blobidarray='=>'mixed'],
'ifx_query' => ['resource', 'query'=>'string', 'link_identifier'=>'resource', 'cursor_type='=>'int', 'blobidarray='=>'mixed'],
'ifx_textasvarchar' => ['bool', 'mode'=>'int'],
'ifx_update_blob' => ['bool', 'bid'=>'int', 'content'=>'string'],
'ifx_update_char' => ['bool', 'bid'=>'int', 'content'=>'string'],
'ifxus_close_slob' => ['bool', 'bid'=>'int'],
'ifxus_create_slob' => ['int', 'mode'=>'int'],
'ifxus_free_slob' => ['bool', 'bid'=>'int'],
'ifxus_open_slob' => ['int', 'bid'=>'int', 'mode'=>'int'],
'ifxus_read_slob' => ['string', 'bid'=>'int', 'nbytes'=>'int'],
'ifxus_seek_slob' => ['int', 'bid'=>'int', 'mode'=>'int', 'offset'=>'int'],
'ifxus_tell_slob' => ['int', 'bid'=>'int'],
'ifxus_write_slob' => ['int', 'bid'=>'int', 'content'=>'string'],
'igbinary_serialize' => ['string|false', 'value'=>''],
'igbinary_unserialize' => ['', 'str'=>'string'],
'ignore_user_abort' => ['int', 'value='=>'bool'],
'iis_add_server' => ['int', 'path'=>'string', 'comment'=>'string', 'server_ip'=>'string', 'port'=>'int', 'host_name'=>'string', 'rights'=>'int', 'start_server'=>'int'],
'iis_get_dir_security' => ['int', 'server_instance'=>'int', 'virtual_path'=>'string'],
'iis_get_script_map' => ['string', 'server_instance'=>'int', 'virtual_path'=>'string', 'script_extension'=>'string'],
'iis_get_server_by_comment' => ['int', 'comment'=>'string'],
'iis_get_server_by_path' => ['int', 'path'=>'string'],
'iis_get_server_rights' => ['int', 'server_instance'=>'int', 'virtual_path'=>'string'],
'iis_get_service_state' => ['int', 'service_id'=>'string'],
'iis_remove_server' => ['int', 'server_instance'=>'int'],
'iis_set_app_settings' => ['int', 'server_instance'=>'int', 'virtual_path'=>'string', 'application_scope'=>'string'],
'iis_set_dir_security' => ['int', 'server_instance'=>'int', 'virtual_path'=>'string', 'directory_flags'=>'int'],
'iis_set_script_map' => ['int', 'server_instance'=>'int', 'virtual_path'=>'string', 'script_extension'=>'string', 'engine_path'=>'string', 'allow_scripting'=>'int'],
'iis_set_server_rights' => ['int', 'server_instance'=>'int', 'virtual_path'=>'string', 'directory_flags'=>'int'],
'iis_start_server' => ['int', 'server_instance'=>'int'],
'iis_start_service' => ['int', 'service_id'=>'string'],
'iis_stop_server' => ['int', 'server_instance'=>'int'],
'iis_stop_service' => ['int', 'service_id'=>'string'],
'image2wbmp' => ['bool', 'im'=>'resource', 'filename='=>'?string', 'threshold='=>'int'],
'image_type_to_extension' => ['string', 'imagetype'=>'int', 'include_dot='=>'bool'],
'image_type_to_mime_type' => ['string', 'imagetype'=>'int'],
'imageaffine' => ['resource', 'src'=>'resource', 'affine'=>'array', 'clip='=>'array'],
'imageaffineconcat' => ['array', 'm1'=>'array', 'm2'=>'array'],
'imageaffinematrixconcat' => ['array', 'm1'=>'array', 'm2'=>'array'],
'imageaffinematrixget' => ['array', 'type'=>'int', 'options'=>'array'],
'imagealphablending' => ['bool', 'im'=>'resource', 'on'=>'bool'],
'imageantialias' => ['bool', 'im'=>'resource', 'on'=>'bool'],
'imagearc' => ['bool', 'im'=>'resource', 'cx'=>'int', 'cy'=>'int', 'w'=>'int', 'h'=>'int', 's'=>'int', 'e'=>'int', 'col'=>'int'],
'imagebmp' => ['bool', 'image'=>'resource', 'to='=>'mixed', 'compressed='=>'bool'],
'imagechar' => ['bool', 'im'=>'resource', 'font'=>'int', 'x'=>'int', 'y'=>'int', 'c'=>'string', 'col'=>'int'],
'imagecharup' => ['bool', 'im'=>'resource', 'font'=>'int', 'x'=>'int', 'y'=>'int', 'c'=>'string', 'col'=>'int'],
'imagecolorallocate' => ['int', 'im'=>'resource', 'red'=>'int', 'green'=>'int', 'blue'=>'int'],
'imagecolorallocatealpha' => ['int', 'im'=>'resource', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'alpha'=>'int'],
'imagecolorat' => ['int', 'im'=>'resource', 'x'=>'int', 'y'=>'int'],
'imagecolorclosest' => ['int', 'im'=>'resource', 'red'=>'int', 'green'=>'int', 'blue'=>'int'],
'imagecolorclosestalpha' => ['int', 'im'=>'resource', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'alpha'=>'int'],
'imagecolorclosesthwb' => ['int', 'im'=>'resource', 'red'=>'int', 'green'=>'int', 'blue'=>'int'],
'imagecolordeallocate' => ['bool', 'im'=>'resource', 'index'=>'int'],
'imagecolorexact' => ['int', 'im'=>'resource', 'red'=>'int', 'green'=>'int', 'blue'=>'int'],
'imagecolorexactalpha' => ['int', 'im'=>'resource', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'alpha'=>'int'],
'imagecolormatch' => ['bool', 'im1'=>'resource', 'im2'=>'resource'],
'imagecolorresolve' => ['int', 'im'=>'resource', 'red'=>'int', 'green'=>'int', 'blue'=>'int'],
'imagecolorresolvealpha' => ['int', 'im'=>'resource', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'alpha'=>'int'],
'imagecolorset' => ['void', 'im'=>'resource', 'col'=>'int', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'alpha='=>'int'],
'imagecolorsforindex' => ['array', 'im'=>'resource', 'col'=>'int'],
'imagecolorstotal' => ['int', 'im'=>'resource'],
'imagecolortransparent' => ['int', 'im'=>'resource', 'col='=>'int'],
'imageconvolution' => ['resource', 'src_im'=>'resource', 'matrix3x3'=>'array', 'div'=>'float', 'offset'=>'float'],
'imagecopy' => ['bool', 'dst_im'=>'resource', 'src_im'=>'resource', 'dst_x'=>'int', 'dst_y'=>'int', 'src_x'=>'int', 'src_y'=>'int', 'src_w'=>'int', 'src_h'=>'int'],
'imagecopymerge' => ['bool', 'src_im'=>'resource', 'dst_im'=>'resource', 'dst_x'=>'int', 'dst_y'=>'int', 'src_x'=>'int', 'src_y'=>'int', 'src_w'=>'int', 'src_h'=>'int', 'pct'=>'int'],
'imagecopymergegray' => ['bool', 'src_im'=>'resource', 'dst_im'=>'resource', 'dst_x'=>'int', 'dst_y'=>'int', 'src_x'=>'int', 'src_y'=>'int', 'src_w'=>'int', 'src_h'=>'int', 'pct'=>'int'],
'imagecopyresampled' => ['bool', 'dst_im'=>'resource', 'src_im'=>'resource', 'dst_x'=>'int', 'dst_y'=>'int', 'src_x'=>'int', 'src_y'=>'int', 'dst_w'=>'int', 'dst_h'=>'int', 'src_w'=>'int', 'src_h'=>'int'],
'imagecopyresized' => ['bool', 'dst_im'=>'resource', 'src_im'=>'resource', 'dst_x'=>'int', 'dst_y'=>'int', 'src_x'=>'int', 'src_y'=>'int', 'dst_w'=>'int', 'dst_h'=>'int', 'src_w'=>'int', 'src_h'=>'int'],
'imagecreate' => ['resource|false', 'x_size'=>'int', 'y_size'=>'int'],
'imagecreatefrombmp' => ['resource|false', 'filename'=>'string'],
'imagecreatefromgd' => ['resource|false', 'filename'=>'string'],
'imagecreatefromgd2' => ['resource|false', 'filename'=>'string'],
'imagecreatefromgd2part' => ['resource|false', 'filename'=>'string', 'srcx'=>'int', 'srcy'=>'int', 'width'=>'int', 'height'=>'int'],
'imagecreatefromgif' => ['resource|false', 'filename'=>'string'],
'imagecreatefromjpeg' => ['resource|false', 'filename'=>'string'],
'imagecreatefrompng' => ['resource|false', 'filename'=>'string'],
'imagecreatefromstring' => ['resource|false', 'image'=>'string'],
'imagecreatefromwbmp' => ['resource|false', 'filename'=>'string'],
'imagecreatefromwebp' => ['resource|false', 'filename'=>'string'],
'imagecreatefromxbm' => ['resource|false', 'filename'=>'string'],
'imagecreatefromxpm' => ['resource|false', 'filename'=>'string'],
'imagecreatetruecolor' => ['resource|false', 'x_size'=>'int', 'y_size'=>'int'],
'imagecrop' => ['resource', 'im'=>'resource', 'rect'=>'array'],
'imagecropauto' => ['resource', 'im'=>'resource', 'mode'=>'int', 'threshold'=>'float', 'color'=>'int'],
'imagedashedline' => ['bool', 'im'=>'resource', 'x1'=>'int', 'y1'=>'int', 'x2'=>'int', 'y2'=>'int', 'col'=>'int'],
'imagedestroy' => ['bool', 'im'=>'resource'],
'imageellipse' => ['bool', 'im'=>'resource', 'cx'=>'int', 'cy'=>'int', 'w'=>'int', 'h'=>'int', 'color'=>'int'],
'imagefill' => ['bool', 'im'=>'resource', 'x'=>'int', 'y'=>'int', 'col'=>'int'],
'imagefilledarc' => ['bool', 'im'=>'resource', 'cx'=>'int', 'cy'=>'int', 'w'=>'int', 'h'=>'int', 's'=>'int', 'e'=>'int', 'col'=>'int', 'style'=>'int'],
'imagefilledellipse' => ['bool', 'im'=>'resource', 'cx'=>'int', 'cy'=>'int', 'w'=>'int', 'h'=>'int', 'color'=>'int'],
'imagefilledpolygon' => ['bool', 'im'=>'resource', 'point'=>'array', 'num_points'=>'int', 'col'=>'int'],
'imagefilledrectangle' => ['bool', 'im'=>'resource', 'x1'=>'int', 'y1'=>'int', 'x2'=>'int', 'y2'=>'int', 'col'=>'int'],
'imagefilltoborder' => ['bool', 'im'=>'resource', 'x'=>'int', 'y'=>'int', 'border'=>'int', 'col'=>'int'],
'imagefilter' => ['bool', 'src_im'=>'resource', 'filtertype'=>'int', 'arg1='=>'int', 'arg2='=>'int', 'arg3='=>'int', 'arg4='=>'int'],
'imageflip' => ['bool', 'im'=>'resource', 'mode'=>'int'],
'imagefontheight' => ['int', 'font'=>'int'],
'imagefontwidth' => ['int', 'font'=>'int'],
'imageftbbox' => ['array', 'size'=>'float', 'angle'=>'float', 'font_file'=>'string', 'text'=>'string', 'extrainfo='=>'array'],
'imagefttext' => ['array', 'im'=>'resource', 'size'=>'float', 'angle'=>'float', 'x'=>'int', 'y'=>'int', 'col'=>'int', 'font_file'=>'string', 'text'=>'string', 'extrainfo='=>'array'],
'imagegammacorrect' => ['bool', 'im'=>'resource', 'inputgamma'=>'float', 'outputgamma'=>'float'],
'imagegd' => ['bool', 'im'=>'resource', 'filename='=>'?string'],
'imagegd2' => ['bool', 'im'=>'resource', 'filename='=>'?string', 'chunk_size='=>'int', 'type='=>'int'],
'imagegetclip' => ['array', 'im'=>'resource'],
'imagegif' => ['bool', 'im'=>'resource', 'filename='=>'?string'],
'imagegrabscreen' => ['resource'],
'imagegrabwindow' => ['resource', 'window_handle'=>'int', 'client_area='=>'int'],
'imageinterlace' => ['int', 'im'=>'resource', 'interlace='=>'int'],
'imageistruecolor' => ['bool', 'im'=>'resource'],
'imagejpeg' => ['bool', 'im'=>'resource', 'filename='=>'?string', 'quality='=>'int'],
'imagelayereffect' => ['bool', 'im'=>'resource', 'effect'=>'int'],
'imageline' => ['bool', 'im'=>'resource', 'x1'=>'int', 'y1'=>'int', 'x2'=>'int', 'y2'=>'int', 'col'=>'int'],
'imageloadfont' => ['int', 'filename'=>'string'],
'imageObj::pasteImage' => ['void', 'srcImg'=>'imageObj', 'transparentColorHex'=>'int', 'dstX'=>'int', 'dstY'=>'int', 'angle'=>'int'],
'imageObj::saveImage' => ['int', 'filename'=>'string', 'oMap'=>'MapObj'],
'imageObj::saveWebImage' => ['string'],
'imageopenpolygon' => ['bool', 'image'=>'resource', 'points'=>'array', 'num_points'=>'int', 'color'=>'int'],
'imagepalettecopy' => ['void', 'dst'=>'resource', 'src'=>'resource'],
'imagepalettetotruecolor' => ['bool', 'src'=>'resource'],
'imagepng' => ['bool', 'im'=>'resource', 'filename='=>'?string', 'quality='=>'int', 'filters='=>'int'],
'imagepolygon' => ['bool', 'im'=>'resource', 'point'=>'array', 'num_points'=>'int', 'col'=>'int'],
'imagepsbbox' => ['array', 'text'=>'string', 'font'=>'', 'size'=>'int', 'space'=>'int', 'tightness'=>'int', 'angle'=>'float'],
'imagepsencodefont' => ['bool', 'font_index'=>'resource', 'encodingfile'=>'string'],
'imagepsextendfont' => ['bool', 'font_index'=>'resource', 'extend'=>'float'],
'imagepsfreefont' => ['bool', 'font_index'=>'resource'],
'imagepsloadfont' => ['resource', 'filename'=>'string'],
'imagepsslantfont' => ['bool', 'font_index'=>'resource', 'slant'=>'float'],
'imagepstext' => ['array', 'image'=>'resource', 'text'=>'string', 'font_index'=>'resource', 'size'=>'int', 'foreground'=>'int', 'background'=>'int', 'x'=>'int', 'y'=>'int', 'space='=>'int', 'tightness='=>'int', 'angle='=>'float', 'antialias_steps='=>'int'],
'imagerectangle' => ['bool', 'im'=>'resource', 'x1'=>'int', 'y1'=>'int', 'x2'=>'int', 'y2'=>'int', 'col'=>'int'],
'imageresolution' => ['mixed', 'image'=>'resource', 'res_x='=>'int', 'res_y='=>'int'],
'imagerotate' => ['resource', 'src_im'=>'resource', 'angle'=>'float', 'bgdcolor'=>'int', 'ignoretransparent='=>'int'],
'imagesavealpha' => ['bool', 'im'=>'resource', 'on'=>'bool'],
'imagescale' => ['resource', 'im'=>'resource', 'new_width'=>'int', 'new_height='=>'int', 'method='=>'int'],
'imagesetbrush' => ['bool', 'image'=>'resource', 'brush'=>'resource'],
'imagesetclip' => ['bool', 'im'=>'resource', 'x1'=>'int', 'y1'=>'int', 'x2'=>'int', 'y2'=>'int'],
'imagesetinterpolation' => ['bool', 'im'=>'resource', 'method'=>'int'],
'imagesetpixel' => ['bool', 'im'=>'resource', 'x'=>'int', 'y'=>'int', 'col'=>'int'],
'imagesetstyle' => ['bool', 'im'=>'resource', 'styles'=>'array'],
'imagesetthickness' => ['bool', 'im'=>'resource', 'thickness'=>'int'],
'imagesettile' => ['bool', 'image'=>'resource', 'tile'=>'resource'],
'imagestring' => ['bool', 'im'=>'resource', 'font'=>'int', 'x'=>'int', 'y'=>'int', 'str'=>'string', 'col'=>'int'],
'imagestringup' => ['bool', 'im'=>'resource', 'font'=>'int', 'x'=>'int', 'y'=>'int', 'str'=>'string', 'col'=>'int'],
'imagesx' => ['int', 'im'=>'resource'],
'imagesy' => ['int', 'im'=>'resource'],
'imagetruecolortopalette' => ['bool', 'im'=>'resource', 'ditherflag'=>'bool', 'colorswanted'=>'int'],
'imagettfbbox' => ['array', 'size'=>'float', 'angle'=>'float', 'font_file'=>'string', 'text'=>'string'],
'imagettftext' => ['array', 'im'=>'resource', 'size'=>'float', 'angle'=>'float', 'x'=>'int', 'y'=>'int', 'col'=>'int', 'font_file'=>'string', 'text'=>'string'],
'imagetypes' => ['int'],
'imagewbmp' => ['bool', 'im'=>'resource', 'filename='=>'?string', 'foreground='=>'int'],
'imagewebp' => ['bool', 'im'=>'resource', 'filename='=>'?string', 'quality='=>'int'],
'imagexbm' => ['bool', 'im'=>'resource', 'filename'=>'?string', 'foreground='=>'int'],
'Imagick::__construct' => ['void', 'files='=>''],
'Imagick::__toString' => ['string'],
'Imagick::adaptiveBlurImage' => ['bool', 'radius'=>'float', 'sigma'=>'float', 'channel='=>'int'],
'Imagick::adaptiveResizeImage' => ['bool', 'columns'=>'int', 'rows'=>'int', 'bestfit='=>'bool'],
'Imagick::adaptiveSharpenImage' => ['bool', 'radius'=>'float', 'sigma'=>'float', 'channel='=>'int'],
'Imagick::adaptiveThresholdImage' => ['bool', 'width'=>'int', 'height'=>'int', 'offset'=>'int'],
'Imagick::addImage' => ['bool', 'source'=>'imagick'],
'Imagick::addNoiseImage' => ['bool', 'noise_type'=>'int', 'channel='=>'int'],
'Imagick::affineTransformImage' => ['bool', 'matrix'=>'imagickdraw'],
'Imagick::animateImages' => ['bool', 'x_server'=>'string'],
'Imagick::annotateImage' => ['bool', 'draw_settings'=>'imagickdraw', 'x'=>'float', 'y'=>'float', 'angle'=>'float', 'text'=>'string'],
'Imagick::appendImages' => ['Imagick', 'stack'=>'bool'],
'Imagick::autoGammaImage' => ['bool', 'channel='=>'int'],
'Imagick::autoLevelImage' => ['void', 'CHANNEL='=>'string'],
'Imagick::autoOrient' => ['bool'],
'Imagick::averageImages' => ['Imagick'],
'Imagick::blackThresholdImage' => ['bool', 'threshold'=>'mixed'],
'Imagick::blueShiftImage' => ['void', 'factor='=>'float'],
'Imagick::blurImage' => ['bool', 'radius'=>'float', 'sigma'=>'float', 'channel='=>'int'],
'Imagick::borderImage' => ['bool', 'bordercolor'=>'mixed', 'width'=>'int', 'height'=>'int'],
'Imagick::brightnessContrastImage' => ['void', 'brightness'=>'string', 'contrast'=>'string', 'CHANNEL='=>'string'],
'Imagick::charcoalImage' => ['bool', 'radius'=>'float', 'sigma'=>'float'],
'Imagick::chopImage' => ['bool', 'width'=>'int', 'height'=>'int', 'x'=>'int', 'y'=>'int'],
'Imagick::clampImage' => ['void', 'CHANNEL='=>'string'],
'Imagick::clear' => ['bool'],
'Imagick::clipImage' => ['bool'],
'Imagick::clipImagePath' => ['void', 'pathname'=>'string', 'inside'=>'string'],
'Imagick::clipPathImage' => ['bool', 'pathname'=>'string', 'inside'=>'bool'],
'Imagick::clone' => ['Imagick'],
'Imagick::clutImage' => ['bool', 'lookup_table'=>'imagick', 'channel='=>'float'],
'Imagick::coalesceImages' => ['Imagick'],
'Imagick::colorFloodfillImage' => ['bool', 'fill'=>'mixed', 'fuzz'=>'float', 'bordercolor'=>'mixed', 'x'=>'int', 'y'=>'int'],
'Imagick::colorizeImage' => ['bool', 'colorize'=>'mixed', 'opacity'=>'mixed'],
'Imagick::colorMatrixImage' => ['void', 'color_matrix'=>'string'],
'Imagick::combineImages' => ['Imagick', 'channeltype'=>'int'],
'Imagick::commentImage' => ['bool', 'comment'=>'string'],
'Imagick::compareImageChannels' => ['array', 'image'=>'imagick', 'channeltype'=>'int', 'metrictype'=>'int'],
'Imagick::compareImageLayers' => ['Imagick', 'method'=>'int'],
'Imagick::compareImages' => ['array', 'compare'=>'imagick', 'metric'=>'int'],
'Imagick::compositeImage' => ['bool', 'composite_object'=>'imagick', 'composite'=>'int', 'x'=>'int', 'y'=>'int', 'channel='=>'int'],
'Imagick::compositeImageGravity' => ['bool', 'imagick'=>'Imagick', 'COMPOSITE_CONSTANT'=>'int', 'GRAVITY_CONSTANT'=>'int'],
'Imagick::contrastImage' => ['bool', 'sharpen'=>'bool'],
'Imagick::contrastStretchImage' => ['bool', 'black_point'=>'float', 'white_point'=>'float', 'channel='=>'int'],
'Imagick::convolveImage' => ['bool', 'kernel'=>'array', 'channel='=>'int'],
'Imagick::count' => ['void', 'mode='=>'string'],
'Imagick::cropImage' => ['bool', 'width'=>'int', 'height'=>'int', 'x'=>'int', 'y'=>'int'],
'Imagick::cropThumbnailImage' => ['bool', 'width'=>'int', 'height'=>'int'],
'Imagick::current' => ['Imagick'],
'Imagick::cycleColormapImage' => ['bool', 'displace'=>'int'],
'Imagick::decipherImage' => ['bool', 'passphrase'=>'string'],
'Imagick::deconstructImages' => ['Imagick'],
'Imagick::deleteImageArtifact' => ['bool', 'artifact'=>'string'],
'Imagick::deleteImageProperty' => ['void', 'name'=>'string'],
'Imagick::deskewImage' => ['bool', 'threshold'=>'float'],
'Imagick::despeckleImage' => ['bool'],
'Imagick::destroy' => ['bool'],
'Imagick::displayImage' => ['bool', 'servername'=>'string'],
'Imagick::displayImages' => ['bool', 'servername'=>'string'],
'Imagick::distortImage' => ['bool', 'method'=>'int', 'arguments'=>'array', 'bestfit'=>'bool'],
'Imagick::drawImage' => ['bool', 'draw'=>'imagickdraw'],
'Imagick::edgeImage' => ['bool', 'radius'=>'float'],
'Imagick::embossImage' => ['bool', 'radius'=>'float', 'sigma'=>'float'],
'Imagick::encipherImage' => ['bool', 'passphrase'=>'string'],
'Imagick::enhanceImage' => ['bool'],
'Imagick::equalizeImage' => ['bool'],
'Imagick::evaluateImage' => ['bool', 'op'=>'int', 'constant'=>'float', 'channel='=>'int'],
'Imagick::evaluateImages' => ['bool', 'EVALUATE_CONSTANT'=>'int'],
'Imagick::exportImagePixels' => ['array', 'x'=>'int', 'y'=>'int', 'width'=>'int', 'height'=>'int', 'map'=>'string', 'storage'=>'int'],
'Imagick::extentImage' => ['bool', 'width'=>'int', 'height'=>'int', 'x'=>'int', 'y'=>'int'],
'Imagick::filter' => ['void', 'ImagickKernel'=>'ImagickKernel', 'CHANNEL='=>'int'],
'Imagick::flattenImages' => ['Imagick'],
'Imagick::flipImage' => ['bool'],
'Imagick::floodFillPaintImage' => ['bool', 'fill'=>'mixed', 'fuzz'=>'float', 'target'=>'mixed', 'x'=>'int', 'y'=>'int', 'invert'=>'bool', 'channel='=>'int'],
'Imagick::flopImage' => ['bool'],
'Imagick::forwardFourierTransformimage' => ['void', 'magnitude'=>'bool'],
'Imagick::frameImage' => ['bool', 'matte_color'=>'mixed', 'width'=>'int', 'height'=>'int', 'inner_bevel'=>'int', 'outer_bevel'=>'int'],
'Imagick::functionImage' => ['bool', 'function'=>'int', 'arguments'=>'array', 'channel='=>'int'],
'Imagick::fxImage' => ['Imagick', 'expression'=>'string', 'channel='=>'int'],
'Imagick::gammaImage' => ['bool', 'gamma'=>'float', 'channel='=>'int'],
'Imagick::gaussianBlurImage' => ['bool', 'radius'=>'float', 'sigma'=>'float', 'channel='=>'int'],
'Imagick::getColorspace' => ['int'],
'Imagick::getCompression' => ['int'],
'Imagick::getCompressionQuality' => ['int'],
'Imagick::getConfigureOptions' => ['string'],
'Imagick::getCopyright' => ['string'],
'Imagick::getFeatures' => ['string'],
'Imagick::getFilename' => ['string'],
'Imagick::getFont' => ['string'],
'Imagick::getFormat' => ['string'],
'Imagick::getGravity' => ['int'],
'Imagick::getHDRIEnabled' => ['int'],
'Imagick::getHomeURL' => ['string'],
'Imagick::getImage' => ['Imagick'],
'Imagick::getImageAlphaChannel' => ['int'],
'Imagick::getImageArtifact' => ['string', 'artifact'=>'string'],
'Imagick::getImageAttribute' => ['string', 'key'=>'string'],
'Imagick::getImageBackgroundColor' => ['ImagickPixel'],
'Imagick::getImageBlob' => ['string'],
'Imagick::getImageBluePrimary' => ['array'],
'Imagick::getImageBorderColor' => ['ImagickPixel'],
'Imagick::getImageChannelDepth' => ['int', 'channel'=>'int'],
'Imagick::getImageChannelDistortion' => ['float', 'reference'=>'imagick', 'channel'=>'int', 'metric'=>'int'],
'Imagick::getImageChannelDistortions' => ['float', 'reference'=>'imagick', 'metric'=>'int', 'channel='=>'int'],
'Imagick::getImageChannelExtrema' => ['array', 'channel'=>'int'],
'Imagick::getImageChannelKurtosis' => ['array', 'channel='=>'int'],
'Imagick::getImageChannelMean' => ['array', 'channel'=>'int'],
'Imagick::getImageChannelRange' => ['array', 'channel'=>'int'],
'Imagick::getImageChannelStatistics' => ['array'],
'Imagick::getImageClipMask' => ['Imagick'],
'Imagick::getImageColormapColor' => ['ImagickPixel', 'index'=>'int'],
'Imagick::getImageColors' => ['int'],
'Imagick::getImageColorspace' => ['int'],
'Imagick::getImageCompose' => ['int'],
'Imagick::getImageCompression' => ['int'],
'Imagick::getImageCompressionQuality' => ['int'],
'Imagick::getImageDelay' => ['int'],
'Imagick::getImageDepth' => ['int'],
'Imagick::getImageDispose' => ['int'],
'Imagick::getImageDistortion' => ['float', 'reference'=>'magickwand', 'metric'=>'int'],
'Imagick::getImageExtrema' => ['array'],
'Imagick::getImageFilename' => ['string'],
'Imagick::getImageFormat' => ['string'],
'Imagick::getImageGamma' => ['float'],
'Imagick::getImageGeometry' => ['array'],
'Imagick::getImageGravity' => ['int'],
'Imagick::getImageGreenPrimary' => ['array'],
'Imagick::getImageHeight' => ['int'],
'Imagick::getImageHistogram' => ['array'],
'Imagick::getImageIndex' => ['int'],
'Imagick::getImageInterlaceScheme' => ['int'],
'Imagick::getImageInterpolateMethod' => ['int'],
'Imagick::getImageIterations' => ['int'],
'Imagick::getImageLength' => ['int'],
'Imagick::getImageMagickLicense' => ['string'],
'Imagick::getImageMatte' => ['bool'],
'Imagick::getImageMatteColor' => ['ImagickPixel'],
'Imagick::getImageMimeType' => ['string'],
'Imagick::getImageOrientation' => ['int'],
'Imagick::getImagePage' => ['array'],
'Imagick::getImagePixelColor' => ['ImagickPixel', 'x'=>'int', 'y'=>'int'],
'Imagick::getImageProfile' => ['string', 'name'=>'string'],
'Imagick::getImageProfiles' => ['array', 'pattern='=>'string', 'only_names='=>'bool'],
'Imagick::getImageProperties' => ['array', 'pattern='=>'string', 'only_names='=>'bool'],
'Imagick::getImageProperty' => ['string', 'name'=>'string'],
'Imagick::getImageRedPrimary' => ['array'],
'Imagick::getImageRegion' => ['Imagick', 'width'=>'int', 'height'=>'int', 'x'=>'int', 'y'=>'int'],
'Imagick::getImageRenderingIntent' => ['int'],
'Imagick::getImageResolution' => ['array'],
'Imagick::getImagesBlob' => ['string'],
'Imagick::getImageScene' => ['int'],
'Imagick::getImageSignature' => ['string'],
'Imagick::getImageSize' => ['int'],
'Imagick::getImageTicksPerSecond' => ['int'],
'Imagick::getImageTotalInkDensity' => ['float'],
'Imagick::getImageType' => ['int'],
'Imagick::getImageUnits' => ['int'],
'Imagick::getImageVirtualPixelMethod' => ['int'],
'Imagick::getImageWhitePoint' => ['array'],
'Imagick::getImageWidth' => ['int'],
'Imagick::getInterlaceScheme' => ['int'],
'Imagick::getIteratorIndex' => ['int'],
'Imagick::getNumberImages' => ['int'],
'Imagick::getOption' => ['string', 'key'=>'string'],
'Imagick::getPackageName' => ['string'],
'Imagick::getPage' => ['array'],
'Imagick::getPixelIterator' => ['ImagickPixelIterator'],
'Imagick::getPixelRegionIterator' => ['ImagickPixelIterator', 'x'=>'int', 'y'=>'int', 'columns'=>'int', 'rows'=>'int'],
'Imagick::getPointSize' => ['float'],
'Imagick::getQuantum' => ['int'],
'Imagick::getQuantumDepth' => ['array'],
'Imagick::getQuantumRange' => ['array'],
'Imagick::getRegistry' => ['string', 'key'=>'string'],
'Imagick::getReleaseDate' => ['string'],
'Imagick::getResource' => ['int', 'type'=>'int'],
'Imagick::getResourceLimit' => ['int', 'type'=>'int'],
'Imagick::getSamplingFactors' => ['array'],
'Imagick::getSize' => ['array'],
'Imagick::getSizeOffset' => ['int'],
'Imagick::getVersion' => ['array'],
'Imagick::haldClutImage' => ['bool', 'clut'=>'imagick', 'channel='=>'int'],
'Imagick::hasNextImage' => ['bool'],
'Imagick::hasPreviousImage' => ['bool'],
'Imagick::identifyFormat' => ['string|false', 'embedText'=>'string'],
'Imagick::identifyImage' => ['array', 'appendrawoutput='=>'bool'],
'Imagick::identifyImageType' => ['int'],
'Imagick::implodeImage' => ['bool', 'radius'=>'float'],
'Imagick::importImagePixels' => ['bool', 'x'=>'int', 'y'=>'int', 'width'=>'int', 'height'=>'int', 'map'=>'string', 'storage'=>'int', 'pixels'=>'array'],
'Imagick::inverseFourierTransformImage' => ['void', 'complement'=>'string', 'magnitude'=>'string'],
'Imagick::key' => ['int|string'],
'Imagick::labelImage' => ['bool', 'label'=>'string'],
'Imagick::levelImage' => ['bool', 'blackpoint'=>'float', 'gamma'=>'float', 'whitepoint'=>'float', 'channel='=>'int'],
'Imagick::linearStretchImage' => ['bool', 'blackpoint'=>'float', 'whitepoint'=>'float'],
'Imagick::liquidRescaleImage' => ['bool', 'width'=>'int', 'height'=>'int', 'delta_x'=>'float', 'rigidity'=>'float'],
'Imagick::listRegistry' => ['array'],
'Imagick::localContrastImage' => ['bool', 'radius'=>'float', 'strength'=>'float'],
'Imagick::magnifyImage' => ['bool'],
'Imagick::mapImage' => ['bool', 'map'=>'imagick', 'dither'=>'bool'],
'Imagick::matteFloodfillImage' => ['bool', 'alpha'=>'float', 'fuzz'=>'float', 'bordercolor'=>'mixed', 'x'=>'int', 'y'=>'int'],
'Imagick::medianFilterImage' => ['bool', 'radius'=>'float'],
'Imagick::mergeImageLayers' => ['bool', 'layer_method'=>'int'],
'Imagick::minifyImage' => ['bool'],
'Imagick::modulateImage' => ['bool', 'brightness'=>'float', 'saturation'=>'float', 'hue'=>'float'],
'Imagick::montageImage' => ['Imagick', 'draw'=>'imagickdraw', 'tile_geometry'=>'string', 'thumbnail_geometry'=>'string', 'mode'=>'int', 'frame'=>'string'],
'Imagick::morphImages' => ['Imagick', 'number_frames'=>'int'],
'Imagick::morphology' => ['void', 'morphologyMethod'=>'int', 'iterations'=>'int', 'ImagickKernel'=>'ImagickKernel', 'CHANNEL='=>'string'],
'Imagick::mosaicImages' => ['Imagick'],
'Imagick::motionBlurImage' => ['bool', 'radius'=>'float', 'sigma'=>'float', 'angle'=>'float', 'channel='=>'int'],
'Imagick::negateImage' => ['bool', 'gray'=>'bool', 'channel='=>'int'],
'Imagick::newImage' => ['bool', 'cols'=>'int', 'rows'=>'int', 'background'=>'mixed', 'format='=>'string'],
'Imagick::newPseudoImage' => ['bool', 'columns'=>'int', 'rows'=>'int', 'pseudostring'=>'string'],
'Imagick::next' => ['void'],
'Imagick::nextImage' => ['bool'],
'Imagick::normalizeImage' => ['bool', 'channel='=>'int'],
'Imagick::oilPaintImage' => ['bool', 'radius'=>'float'],
'Imagick::opaquePaintImage' => ['bool', 'target'=>'mixed', 'fill'=>'mixed', 'fuzz'=>'float', 'invert'=>'bool', 'channel='=>'int'],
'Imagick::optimizeImageLayers' => ['bool'],
'Imagick::orderedPosterizeImage' => ['bool', 'threshold_map'=>'string', 'channel='=>'int'],
'Imagick::paintFloodfillImage' => ['bool', 'fill'=>'mixed', 'fuzz'=>'float', 'bordercolor'=>'mixed', 'x'=>'int', 'y'=>'int', 'channel='=>'int'],
'Imagick::paintOpaqueImage' => ['bool', 'target'=>'mixed', 'fill'=>'mixed', 'fuzz'=>'float', 'channel='=>'int'],
'Imagick::paintTransparentImage' => ['bool', 'target'=>'mixed', 'alpha'=>'float', 'fuzz'=>'float'],
'Imagick::pingImage' => ['bool', 'filename'=>'string'],
'Imagick::pingImageBlob' => ['bool', 'image'=>'string'],
'Imagick::pingImageFile' => ['bool', 'filehandle'=>'resource', 'filename='=>'string'],
'Imagick::polaroidImage' => ['bool', 'properties'=>'imagickdraw', 'angle'=>'float'],
'Imagick::posterizeImage' => ['bool', 'levels'=>'int', 'dither'=>'bool'],
'Imagick::previewImages' => ['bool', 'preview'=>'int'],
'Imagick::previousImage' => ['bool'],
'Imagick::profileImage' => ['bool', 'name'=>'string', 'profile'=>'string'],
'Imagick::quantizeImage' => ['bool', 'numbercolors'=>'int', 'colorspace'=>'int', 'treedepth'=>'int', 'dither'=>'bool', 'measureerror'=>'bool'],
'Imagick::quantizeImages' => ['bool', 'numbercolors'=>'int', 'colorspace'=>'int', 'treedepth'=>'int', 'dither'=>'bool', 'measureerror'=>'bool'],
'Imagick::queryFontMetrics' => ['array', 'properties'=>'imagickdraw', 'text'=>'string', 'multiline='=>'bool'],
'Imagick::queryFonts' => ['array', 'pattern='=>'string'],
'Imagick::queryFormats' => ['array', 'pattern='=>'string'],
'Imagick::radialBlurImage' => ['bool', 'angle'=>'float', 'channel='=>'int'],
'Imagick::raiseImage' => ['bool', 'width'=>'int', 'height'=>'int', 'x'=>'int', 'y'=>'int', 'raise'=>'bool'],
'Imagick::randomThresholdImage' => ['bool', 'low'=>'float', 'high'=>'float', 'channel='=>'int'],
'Imagick::readImage' => ['bool', 'filename'=>'string'],
'Imagick::readImageBlob' => ['bool', 'image'=>'string', 'filename='=>'string'],
'Imagick::readImageFile' => ['bool', 'filehandle'=>'resource', 'filename='=>'string'],
'Imagick::readImages' => ['Imagick', 'filenames'=>'string'],
'Imagick::recolorImage' => ['bool', 'matrix'=>'array'],
'Imagick::reduceNoiseImage' => ['bool', 'radius'=>'float'],
'Imagick::remapImage' => ['bool', 'replacement'=>'imagick', 'dither'=>'int'],
'Imagick::removeImage' => ['bool'],
'Imagick::removeImageProfile' => ['string', 'name'=>'string'],
'Imagick::render' => ['bool'],
'Imagick::resampleImage' => ['bool', 'x_resolution'=>'float', 'y_resolution'=>'float', 'filter'=>'int', 'blur'=>'float'],
'Imagick::resetImagePage' => ['bool', 'page'=>'string'],
'Imagick::resetIterator' => [''],
'Imagick::resizeImage' => ['bool', 'columns'=>'int', 'rows'=>'int', 'filter'=>'int', 'blur'=>'float', 'bestfit='=>'bool'],
'Imagick::rewind' => ['void'],
'Imagick::rollImage' => ['bool', 'x'=>'int', 'y'=>'int'],
'Imagick::rotateImage' => ['bool', 'background'=>'mixed', 'degrees'=>'float'],
'Imagick::rotationalBlurImage' => ['void', 'angle'=>'string', 'CHANNEL='=>'string'],
'Imagick::roundCorners' => ['bool', 'x_rounding'=>'float', 'y_rounding'=>'float', 'stroke_width='=>'float', 'displace='=>'float', 'size_correction='=>'float'],
'Imagick::roundCornersImage' => ['', 'xRounding'=>'', 'yRounding'=>'', 'strokeWidth'=>'', 'displace'=>'', 'sizeCorrection'=>''],
'Imagick::sampleImage' => ['bool', 'columns'=>'int', 'rows'=>'int'],
'Imagick::scaleImage' => ['bool', 'cols'=>'int', 'rows'=>'int', 'bestfit='=>'bool'],
'Imagick::segmentImage' => ['bool', 'colorspace'=>'int', 'cluster_threshold'=>'float', 'smooth_threshold'=>'float', 'verbose='=>'bool'],
'Imagick::selectiveBlurImage' => ['void', 'radius'=>'float', 'sigma'=>'float', 'threshold'=>'float', 'CHANNEL'=>'int'],
'Imagick::separateImageChannel' => ['bool', 'channel'=>'int'],
'Imagick::sepiaToneImage' => ['bool', 'threshold'=>'float'],
'Imagick::setAntiAlias' => ['int', 'antialias'=>'bool'],
'Imagick::setBackgroundColor' => ['bool', 'background'=>'mixed'],
'Imagick::setColorspace' => ['bool', 'colorspace'=>'int'],
'Imagick::setCompression' => ['bool', 'compression'=>'int'],
'Imagick::setCompressionQuality' => ['bool', 'quality'=>'int'],
'Imagick::setFilename' => ['bool', 'filename'=>'string'],
'Imagick::setFirstIterator' => ['bool'],
'Imagick::setFont' => ['bool', 'font'=>'string'],
'Imagick::setFormat' => ['bool', 'format'=>'string'],
'Imagick::setGravity' => ['bool', 'gravity'=>'int'],
'Imagick::setImage' => ['bool', 'replace'=>'imagick'],
'Imagick::setImageAlpha' => ['bool', 'alpha'=>'float'],
'Imagick::setImageAlphaChannel' => ['bool', 'mode'=>'int'],
'Imagick::setImageArtifact' => ['bool', 'artifact'=>'string', 'value'=>'string'],
'Imagick::setImageAttribute' => ['void', 'key'=>'string', 'value'=>'string'],
'Imagick::setImageBackgroundColor' => ['bool', 'background'=>'mixed'],
'Imagick::setImageBias' => ['bool', 'bias'=>'float'],
'Imagick::setImageBiasQuantum' => ['void', 'bias'=>'string'],
'Imagick::setImageBluePrimary' => ['bool', 'x'=>'float', 'y'=>'float'],
'Imagick::setImageBorderColor' => ['bool', 'border'=>'mixed'],
'Imagick::setImageChannelDepth' => ['bool', 'channel'=>'int', 'depth'=>'int'],
'Imagick::setImageChannelMask' => ['', 'channel'=>'int'],
'Imagick::setImageClipMask' => ['bool', 'clip_mask'=>'imagick'],
'Imagick::setImageColormapColor' => ['bool', 'index'=>'int', 'color'=>'imagickpixel'],
'Imagick::setImageColorspace' => ['bool', 'colorspace'=>'int'],
'Imagick::setImageCompose' => ['bool', 'compose'=>'int'],
'Imagick::setImageCompression' => ['bool', 'compression'=>'int'],
'Imagick::setImageCompressionQuality' => ['bool', 'quality'=>'int'],
'Imagick::setImageDelay' => ['bool', 'delay'=>'int'],
'Imagick::setImageDepth' => ['bool', 'depth'=>'int'],
'Imagick::setImageDispose' => ['bool', 'dispose'=>'int'],
'Imagick::setImageExtent' => ['bool', 'columns'=>'int', 'rows'=>'int'],
'Imagick::setImageFilename' => ['bool', 'filename'=>'string'],
'Imagick::setImageFormat' => ['bool', 'format'=>'string'],
'Imagick::setImageGamma' => ['bool', 'gamma'=>'float'],
'Imagick::setImageGravity' => ['bool', 'gravity'=>'int'],
'Imagick::setImageGreenPrimary' => ['bool', 'x'=>'float', 'y'=>'float'],
'Imagick::setImageIndex' => ['bool', 'index'=>'int'],
'Imagick::setImageInterlaceScheme' => ['bool', 'interlace_scheme'=>'int'],
'Imagick::setImageInterpolateMethod' => ['bool', 'method'=>'int'],
'Imagick::setImageIterations' => ['bool', 'iterations'=>'int'],
'Imagick::setImageMatte' => ['bool', 'matte'=>'bool'],
'Imagick::setImageMatteColor' => ['bool', 'matte'=>'mixed'],
'Imagick::setImageOpacity' => ['bool', 'opacity'=>'float'],
'Imagick::setImageOrientation' => ['bool', 'orientation'=>'int'],
'Imagick::setImagePage' => ['bool', 'width'=>'int', 'height'=>'int', 'x'=>'int', 'y'=>'int'],
'Imagick::setImageProfile' => ['bool', 'name'=>'string', 'profile'=>'string'],
'Imagick::setImageProgressMonitor' => ['', 'filename'=>''],
'Imagick::setImageProperty' => ['bool', 'name'=>'string', 'value'=>'string'],
'Imagick::setImageRedPrimary' => ['bool', 'x'=>'float', 'y'=>'float'],
'Imagick::setImageRenderingIntent' => ['bool', 'rendering_intent'=>'int'],
'Imagick::setImageResolution' => ['bool', 'x_resolution'=>'float', 'y_resolution'=>'float'],
'Imagick::setImageScene' => ['bool', 'scene'=>'int'],
'Imagick::setImageTicksPerSecond' => ['bool', 'ticks_per_second'=>'int'],
'Imagick::setImageType' => ['bool', 'image_type'=>'int'],
'Imagick::setImageUnits' => ['bool', 'units'=>'int'],
'Imagick::setImageVirtualPixelMethod' => ['bool', 'method'=>'int'],
'Imagick::setImageWhitePoint' => ['bool', 'x'=>'float', 'y'=>'float'],
'Imagick::setInterlaceScheme' => ['bool', 'interlace_scheme'=>'int'],
'Imagick::setIteratorIndex' => ['bool', 'index'=>'int'],
'Imagick::setLastIterator' => ['bool'],
'Imagick::setOption' => ['bool', 'key'=>'string', 'value'=>'string'],
'Imagick::setPage' => ['bool', 'width'=>'int', 'height'=>'int', 'x'=>'int', 'y'=>'int'],
'Imagick::setPointSize' => ['bool', 'point_size'=>'float'],
'Imagick::setProgressMonitor' => ['void', 'callback'=>'callable'],
'Imagick::setRegistry' => ['void', 'key'=>'string', 'value'=>'string'],
'Imagick::setResolution' => ['bool', 'x_resolution'=>'float', 'y_resolution'=>'float'],
'Imagick::setResourceLimit' => ['bool', 'type'=>'int', 'limit'=>'int'],
'Imagick::setSamplingFactors' => ['bool', 'factors'=>'array'],
'Imagick::setSize' => ['bool', 'columns'=>'int', 'rows'=>'int'],
'Imagick::setSizeOffset' => ['bool', 'columns'=>'int', 'rows'=>'int', 'offset'=>'int'],
'Imagick::setType' => ['bool', 'image_type'=>'int'],
'Imagick::shadeImage' => ['bool', 'gray'=>'bool', 'azimuth'=>'float', 'elevation'=>'float'],
'Imagick::shadowImage' => ['bool', 'opacity'=>'float', 'sigma'=>'float', 'x'=>'int', 'y'=>'int'],
'Imagick::sharpenImage' => ['bool', 'radius'=>'float', 'sigma'=>'float', 'channel='=>'int'],
'Imagick::shaveImage' => ['bool', 'columns'=>'int', 'rows'=>'int'],
'Imagick::shearImage' => ['bool', 'background'=>'mixed', 'x_shear'=>'float', 'y_shear'=>'float'],
'Imagick::sigmoidalContrastImage' => ['bool', 'sharpen'=>'bool', 'alpha'=>'float', 'beta'=>'float', 'channel='=>'int'],
'Imagick::similarityImage' => ['Imagick', 'imagick'=>'Imagick', '&bestMatch'=>'array', '&similarity'=>'float', 'similarity_threshold'=>'float', 'metric'=>'int'],
'Imagick::sketchImage' => ['bool', 'radius'=>'float', 'sigma'=>'float', 'angle'=>'float'],
'Imagick::smushImages' => ['Imagick', 'stack'=>'string', 'offset'=>'string'],
'Imagick::solarizeImage' => ['bool', 'threshold'=>'int'],
'Imagick::sparseColorImage' => ['bool', 'sparse_method'=>'int', 'arguments'=>'array', 'channel='=>'int'],
'Imagick::spliceImage' => ['bool', 'width'=>'int', 'height'=>'int', 'x'=>'int', 'y'=>'int'],
'Imagick::spreadImage' => ['bool', 'radius'=>'float'],
'Imagick::statisticImage' => ['void', 'type'=>'int', 'width'=>'int', 'height'=>'int', 'CHANNEL='=>'string'],
'Imagick::steganoImage' => ['Imagick', 'watermark_wand'=>'imagick', 'offset'=>'int'],
'Imagick::stereoImage' => ['bool', 'offset_wand'=>'imagick'],
'Imagick::stripImage' => ['bool'],
'Imagick::subImageMatch' => ['Imagick', 'Imagick'=>'Imagick', '&w_offset='=>'array', '&w_similarity='=>'float'],
'Imagick::swirlImage' => ['bool', 'degrees'=>'float'],
'Imagick::textureImage' => ['bool', 'texture_wand'=>'imagick'],
'Imagick::thresholdImage' => ['bool', 'threshold'=>'float', 'channel='=>'int'],
'Imagick::thumbnailImage' => ['bool', 'columns'=>'int', 'rows'=>'int', 'bestfit='=>'bool', 'fill='=>'bool'],
'Imagick::tintImage' => ['bool', 'tint'=>'mixed', 'opacity'=>'mixed'],
'Imagick::transformImage' => ['Imagick', 'crop'=>'string', 'geometry'=>'string'],
'Imagick::transformImageColorspace' => ['bool', 'colorspace'=>'int'],
'Imagick::transparentPaintImage' => ['bool', 'target'=>'mixed', 'alpha'=>'float', 'fuzz'=>'float', 'invert'=>'bool'],
'Imagick::transposeImage' => ['bool'],
'Imagick::transverseImage' => ['bool'],
'Imagick::trimImage' => ['bool', 'fuzz'=>'float'],
'Imagick::uniqueImageColors' => ['bool'],
'Imagick::unsharpMaskImage' => ['bool', 'radius'=>'float', 'sigma'=>'float', 'amount'=>'float', 'threshold'=>'float', 'channel='=>'int'],
'Imagick::valid' => ['bool'],
'Imagick::vignetteImage' => ['bool', 'blackpoint'=>'float', 'whitepoint'=>'float', 'x'=>'int', 'y'=>'int'],
'Imagick::waveImage' => ['bool', 'amplitude'=>'float', 'length'=>'float'],
'Imagick::whiteThresholdImage' => ['bool', 'threshold'=>'mixed'],
'Imagick::writeImage' => ['bool', 'filename='=>'string'],
'Imagick::writeImageFile' => ['bool', 'filehandle'=>'resource'],
'Imagick::writeImages' => ['bool', 'filename'=>'string', 'adjoin'=>'bool'],
'Imagick::writeImagesFile' => ['bool', 'filehandle'=>'resource'],
'ImagickDraw::__construct' => ['void'],
'ImagickDraw::affine' => ['bool', 'affine'=>'array'],
'ImagickDraw::annotation' => ['bool', 'x'=>'float', 'y'=>'float', 'text'=>'string'],
'ImagickDraw::arc' => ['bool', 'sx'=>'float', 'sy'=>'float', 'ex'=>'float', 'ey'=>'float', 'sd'=>'float', 'ed'=>'float'],
'ImagickDraw::bezier' => ['bool', 'coordinates'=>'array'],
'ImagickDraw::circle' => ['bool', 'ox'=>'float', 'oy'=>'float', 'px'=>'float', 'py'=>'float'],
'ImagickDraw::clear' => ['bool'],
'ImagickDraw::clone' => ['ImagickDraw'],
'ImagickDraw::color' => ['bool', 'x'=>'float', 'y'=>'float', 'paintmethod'=>'int'],
'ImagickDraw::comment' => ['bool', 'comment'=>'string'],
'ImagickDraw::composite' => ['bool', 'compose'=>'int', 'x'=>'float', 'y'=>'float', 'width'=>'float', 'height'=>'float', 'compositewand'=>'imagick'],
'ImagickDraw::destroy' => ['bool'],
'ImagickDraw::ellipse' => ['bool', 'ox'=>'float', 'oy'=>'float', 'rx'=>'float', 'ry'=>'float', 'start'=>'float', 'end'=>'float'],
'ImagickDraw::getBorderColor' => ['ImagickPixel'],
'ImagickDraw::getClipPath' => ['string'],
'ImagickDraw::getClipRule' => ['int'],
'ImagickDraw::getClipUnits' => ['int'],
'ImagickDraw::getDensity' => ['null|string'],
'ImagickDraw::getFillColor' => ['ImagickPixel'],
'ImagickDraw::getFillOpacity' => ['float'],
'ImagickDraw::getFillRule' => ['int'],
'ImagickDraw::getFont' => ['string'],
'ImagickDraw::getFontFamily' => ['string'],
'ImagickDraw::getFontResolution' => ['array'],
'ImagickDraw::getFontSize' => ['float'],
'ImagickDraw::getFontStretch' => ['int'],
'ImagickDraw::getFontStyle' => ['int'],
'ImagickDraw::getFontWeight' => ['int'],
'ImagickDraw::getGravity' => ['int'],
'ImagickDraw::getOpacity' => ['float'],
'ImagickDraw::getStrokeAntialias' => ['bool'],
'ImagickDraw::getStrokeColor' => ['ImagickPixel'],
'ImagickDraw::getStrokeDashArray' => ['array'],
'ImagickDraw::getStrokeDashOffset' => ['float'],
'ImagickDraw::getStrokeLineCap' => ['int'],
'ImagickDraw::getStrokeLineJoin' => ['int'],
'ImagickDraw::getStrokeMiterLimit' => ['int'],
'ImagickDraw::getStrokeOpacity' => ['float'],
'ImagickDraw::getStrokeWidth' => ['float'],
'ImagickDraw::getTextAlignment' => ['int'],
'ImagickDraw::getTextAntialias' => ['bool'],
'ImagickDraw::getTextDecoration' => ['int'],
'ImagickDraw::getTextDirection' => ['bool'],
'ImagickDraw::getTextEncoding' => ['string'],
'ImagickDraw::getTextInterlineSpacing' => ['float'],
'ImagickDraw::getTextInterwordSpacing' => ['float'],
'ImagickDraw::getTextKerning' => ['float'],
'ImagickDraw::getTextUnderColor' => ['ImagickPixel'],
'ImagickDraw::getVectorGraphics' => ['string'],
'ImagickDraw::line' => ['bool', 'sx'=>'float', 'sy'=>'float', 'ex'=>'float', 'ey'=>'float'],
'ImagickDraw::matte' => ['bool', 'x'=>'float', 'y'=>'float', 'paintmethod'=>'int'],
'ImagickDraw::pathClose' => ['bool'],
'ImagickDraw::pathCurveToAbsolute' => ['bool', 'x1'=>'float', 'y1'=>'float', 'x2'=>'float', 'y2'=>'float', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::pathCurveToQuadraticBezierAbsolute' => ['bool', 'x1'=>'float', 'y1'=>'float', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::pathCurveToQuadraticBezierRelative' => ['bool', 'x1'=>'float', 'y1'=>'float', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::pathCurveToQuadraticBezierSmoothAbsolute' => ['bool', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::pathCurveToQuadraticBezierSmoothRelative' => ['bool', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::pathCurveToRelative' => ['bool', 'x1'=>'float', 'y1'=>'float', 'x2'=>'float', 'y2'=>'float', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::pathCurveToSmoothAbsolute' => ['bool', 'x2'=>'float', 'y2'=>'float', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::pathCurveToSmoothRelative' => ['bool', 'x2'=>'float', 'y2'=>'float', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::pathEllipticArcAbsolute' => ['bool', 'rx'=>'float', 'ry'=>'float', 'x_axis_rotation'=>'float', 'large_arc_flag'=>'bool', 'sweep_flag'=>'bool', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::pathEllipticArcRelative' => ['bool', 'rx'=>'float', 'ry'=>'float', 'x_axis_rotation'=>'float', 'large_arc_flag'=>'bool', 'sweep_flag'=>'bool', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::pathFinish' => ['bool'],
'ImagickDraw::pathLineToAbsolute' => ['bool', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::pathLineToHorizontalAbsolute' => ['bool', 'x'=>'float'],
'ImagickDraw::pathLineToHorizontalRelative' => ['bool', 'x'=>'float'],
'ImagickDraw::pathLineToRelative' => ['bool', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::pathLineToVerticalAbsolute' => ['bool', 'y'=>'float'],
'ImagickDraw::pathLineToVerticalRelative' => ['bool', 'y'=>'float'],
'ImagickDraw::pathMoveToAbsolute' => ['bool', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::pathMoveToRelative' => ['bool', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::pathStart' => ['bool'],
'ImagickDraw::point' => ['bool', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::polygon' => ['bool', 'coordinates'=>'array'],
'ImagickDraw::polyline' => ['bool', 'coordinates'=>'array'],
'ImagickDraw::pop' => ['bool'],
'ImagickDraw::popClipPath' => ['bool'],
'ImagickDraw::popDefs' => ['bool'],
'ImagickDraw::popPattern' => ['bool'],
'ImagickDraw::push' => ['bool'],
'ImagickDraw::pushClipPath' => ['bool', 'clip_mask_id'=>'string'],
'ImagickDraw::pushDefs' => ['bool'],
'ImagickDraw::pushPattern' => ['bool', 'pattern_id'=>'string', 'x'=>'float', 'y'=>'float', 'width'=>'float', 'height'=>'float'],
'ImagickDraw::rectangle' => ['bool', 'x1'=>'float', 'y1'=>'float', 'x2'=>'float', 'y2'=>'float'],
'ImagickDraw::render' => ['bool'],
'ImagickDraw::resetVectorGraphics' => ['void'],
'ImagickDraw::rotate' => ['bool', 'degrees'=>'float'],
'ImagickDraw::roundRectangle' => ['bool', 'x1'=>'float', 'y1'=>'float', 'x2'=>'float', 'y2'=>'float', 'rx'=>'float', 'ry'=>'float'],
'ImagickDraw::scale' => ['bool', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::setBorderColor' => ['bool', 'color'=>'ImagickPixel'],
'ImagickDraw::setClipPath' => ['bool', 'clip_mask'=>'string'],
'ImagickDraw::setClipRule' => ['bool', 'fill_rule'=>'int'],
'ImagickDraw::setClipUnits' => ['bool', 'clip_units'=>'int'],
'ImagickDraw::setDensity' => ['bool', 'density_string'=>'string'],
'ImagickDraw::setFillAlpha' => ['bool', 'opacity'=>'float'],
'ImagickDraw::setFillColor' => ['bool', 'fill_pixel'=>'imagickpixel'],
'ImagickDraw::setFillOpacity' => ['bool', 'fillopacity'=>'float'],
'ImagickDraw::setFillPatternURL' => ['bool', 'fill_url'=>'string'],
'ImagickDraw::setFillRule' => ['bool', 'fill_rule'=>'int'],
'ImagickDraw::setFont' => ['bool', 'font_name'=>'string'],
'ImagickDraw::setFontFamily' => ['bool', 'font_family'=>'string'],
'ImagickDraw::setFontResolution' => ['bool', 'x'=>'float', 'y'=>'float'],
'ImagickDraw::setFontSize' => ['bool', 'pointsize'=>'float'],
'ImagickDraw::setFontStretch' => ['bool', 'fontstretch'=>'int'],
'ImagickDraw::setFontStyle' => ['bool', 'style'=>'int'],
'ImagickDraw::setFontWeight' => ['bool', 'font_weight'=>'int'],
'ImagickDraw::setGravity' => ['bool', 'gravity'=>'int'],
'ImagickDraw::setOpacity' => ['void', 'opacity'=>'float'],
'ImagickDraw::setResolution' => ['void', 'x_resolution'=>'string', 'y_resolution'=>'string'],
'ImagickDraw::setStrokeAlpha' => ['bool', 'opacity'=>'float'],
'ImagickDraw::setStrokeAntialias' => ['bool', 'stroke_antialias'=>'bool'],
'ImagickDraw::setStrokeColor' => ['bool', 'stroke_pixel'=>'imagickpixel'],
'ImagickDraw::setStrokeDashArray' => ['bool', 'dasharray'=>'array'],
'ImagickDraw::setStrokeDashOffset' => ['bool', 'dash_offset'=>'float'],
'ImagickDraw::setStrokeLineCap' => ['bool', 'linecap'=>'int'],
'ImagickDraw::setStrokeLineJoin' => ['bool', 'linejoin'=>'int'],
'ImagickDraw::setStrokeMiterLimit' => ['bool', 'miterlimit'=>'int'],
'ImagickDraw::setStrokeOpacity' => ['bool', 'stroke_opacity'=>'float'],
'ImagickDraw::setStrokePatternURL' => ['bool', 'stroke_url'=>'string'],
'ImagickDraw::setStrokeWidth' => ['bool', 'stroke_width'=>'float'],
'ImagickDraw::setTextAlignment' => ['bool', 'alignment'=>'int'],
'ImagickDraw::setTextAntialias' => ['bool', 'antialias'=>'bool'],
'ImagickDraw::setTextDecoration' => ['bool', 'decoration'=>'int'],
'ImagickDraw::setTextDirection' => ['bool', 'direction'=>'int'],
'ImagickDraw::setTextEncoding' => ['bool', 'encoding'=>'string'],
'ImagickDraw::setTextInterlineSpacing' => ['void', 'spacing'=>'float'],
'ImagickDraw::setTextInterwordSpacing' => ['void', 'spacing'=>'float'],
'ImagickDraw::setTextKerning' => ['void', 'kerning'=>'float'],
'ImagickDraw::setTextUnderColor' => ['bool', 'under_color'=>'imagickpixel'],
'ImagickDraw::setVectorGraphics' => ['bool', 'xml'=>'string'],
'ImagickDraw::setViewbox' => ['bool', 'x1'=>'int', 'y1'=>'int', 'x2'=>'int', 'y2'=>'int'],
'ImagickDraw::skewX' => ['bool', 'degrees'=>'float'],
'ImagickDraw::skewY' => ['bool', 'degrees'=>'float'],
'ImagickDraw::translate' => ['bool', 'x'=>'float', 'y'=>'float'],
'ImagickKernel::addKernel' => ['void', 'ImagickKernel'=>'ImagickKernel'],
'ImagickKernel::addUnityKernel' => ['void'],
'ImagickKernel::fromBuiltin' => ['ImagickKernel', 'kernelType'=>'string', 'kernelString'=>'string'],
'ImagickKernel::fromMatrix' => ['ImagickKernel', 'matrix'=>'array', 'origin='=>'array'],
'ImagickKernel::getMatrix' => ['array'],
'ImagickKernel::scale' => ['void'],
'ImagickKernel::separate' => ['array'],
'ImagickKernel::seperate' => ['void'],
'ImagickPixel::__construct' => ['void', 'color='=>'string'],
'ImagickPixel::clear' => ['bool'],
'ImagickPixel::clone' => ['void'],
'ImagickPixel::destroy' => ['bool'],
'ImagickPixel::getColor' => ['array', 'normalized='=>'bool'],
'ImagickPixel::getColorAsString' => ['string'],
'ImagickPixel::getColorCount' => ['int'],
'ImagickPixel::getColorQuantum' => ['mixed'],
'ImagickPixel::getColorValue' => ['float', 'color'=>'int'],
'ImagickPixel::getColorValueQuantum' => ['mixed'],
'ImagickPixel::getHSL' => ['array'],
'ImagickPixel::getIndex' => ['int'],
'ImagickPixel::isPixelSimilar' => ['bool', 'color'=>'ImagickPixel', 'fuzz'=>'float'],
'ImagickPixel::isPixelSimilarQuantum' => ['bool', 'color'=>'string', 'fuzz='=>'string'],
'ImagickPixel::isSimilar' => ['bool', 'color'=>'imagickpixel', 'fuzz'=>'float'],
'ImagickPixel::setColor' => ['bool', 'color'=>'string'],
'ImagickPixel::setcolorcount' => ['void', 'colorCount'=>'string'],
'ImagickPixel::setColorFromPixel' => ['bool', 'srcPixel'=>'ImagickPixel'],
'ImagickPixel::setColorValue' => ['bool', 'color'=>'int', 'value'=>'float'],
'ImagickPixel::setColorValueQuantum' => ['void', 'color'=>'int', 'value'=>'mixed'],
'ImagickPixel::setHSL' => ['bool', 'hue'=>'float', 'saturation'=>'float', 'luminosity'=>'float'],
'ImagickPixel::setIndex' => ['void', 'index'=>'int'],
'ImagickPixelIterator::__construct' => ['void', 'wand'=>'imagick'],
'ImagickPixelIterator::clear' => ['bool'],
'ImagickPixelIterator::current' => ['mixed'],
'ImagickPixelIterator::destroy' => ['bool'],
'ImagickPixelIterator::getCurrentIteratorRow' => ['array'],
'ImagickPixelIterator::getIteratorRow' => ['int'],
'ImagickPixelIterator::getNextIteratorRow' => ['array'],
'ImagickPixelIterator::getpixeliterator' => ['', 'Imagick'=>'Imagick'],
'ImagickPixelIterator::getpixelregioniterator' => ['', 'Imagick'=>'Imagick', 'x'=>'', 'y'=>'', 'columns'=>'', 'rows'=>''],
'ImagickPixelIterator::getPreviousIteratorRow' => ['array'],
'ImagickPixelIterator::key' => ['int|string'],
'ImagickPixelIterator::newPixelIterator' => ['bool', 'wand'=>'imagick'],
'ImagickPixelIterator::newPixelRegionIterator' => ['bool', 'wand'=>'imagick', 'x'=>'int', 'y'=>'int', 'columns'=>'int', 'rows'=>'int'],
'ImagickPixelIterator::next' => ['void'],
'ImagickPixelIterator::resetIterator' => ['bool'],
'ImagickPixelIterator::rewind' => ['void'],
'ImagickPixelIterator::setIteratorFirstRow' => ['bool'],
'ImagickPixelIterator::setIteratorLastRow' => ['bool'],
'ImagickPixelIterator::setIteratorRow' => ['bool', 'row'=>'int'],
'ImagickPixelIterator::syncIterator' => ['bool'],
'ImagickPixelIterator::valid' => ['bool'],
'imap_8bit' => ['string', 'text'=>'string'],
'imap_alerts' => ['array|false'],
'imap_append' => ['bool', 'stream_id'=>'resource', 'folder'=>'string', 'message'=>'string', 'options='=>'string', 'internal_date='=>'string'],
'imap_base64' => ['string', 'text'=>'string'],
'imap_binary' => ['string', 'text'=>'string'],
'imap_body' => ['string', 'stream_id'=>'resource', 'msg_no'=>'int', 'options='=>'int'],
'imap_bodystruct' => ['object', 'stream_id'=>'resource', 'msg_no'=>'int', 'section'=>'string'],
'imap_check' => ['object', 'stream_id'=>'resource'],
'imap_clearflag_full' => ['bool', 'stream_id'=>'resource', 'sequence'=>'string', 'flag'=>'string', 'options='=>'int'],
'imap_close' => ['bool', 'stream_id'=>'resource', 'options='=>'int'],
'imap_create' => ['bool', 'stream_id'=>'resource', 'mailbox'=>'string'],
'imap_createmailbox' => ['bool', 'stream_id'=>'resource', 'mailbox'=>'string'],
'imap_delete' => ['bool', 'stream_id'=>'resource', 'msg_no'=>'int', 'options='=>'int'],
'imap_deletemailbox' => ['bool', 'stream_id'=>'resource', 'mailbox'=>'string'],
'imap_errors' => ['array|false'],
'imap_expunge' => ['bool', 'stream_id'=>'resource'],
'imap_fetch_overview' => ['array', 'stream_id'=>'resource', 'sequence'=>'string', 'options='=>'int'],
'imap_fetchbody' => ['string', 'stream_id'=>'resource', 'msg_no'=>'int', 'section'=>'string', 'options='=>'int'],
'imap_fetchheader' => ['string', 'stream_id'=>'resource', 'msg_no'=>'int', 'options='=>'int'],
'imap_fetchmime' => ['string', 'stream_id'=>'resource', 'msg_no'=>'int', 'section'=>'string', 'options='=>'int'],
'imap_fetchstructure' => ['object', 'stream_id'=>'resource', 'msg_no'=>'int', 'options='=>'int'],
'imap_fetchtext' => ['string', 'stream_id'=>'resource', 'msg_no'=>'int', 'options='=>'int'],
'imap_gc' => ['bool', 'stream_id'=>'resource', 'flags'=>'int'],
'imap_get_quota' => ['array', 'stream_id'=>'resource', 'qroot'=>'string'],
'imap_get_quotaroot' => ['array', 'stream_id'=>'resource', 'mbox'=>'string'],
'imap_getacl' => ['array', 'stream_id'=>'resource', 'mailbox'=>'string'],
'imap_getmailboxes' => ['array', 'stream_id'=>'resource', 'ref'=>'string', 'pattern'=>'string'],
'imap_getsubscribed' => ['array', 'stream_id'=>'resource', 'ref'=>'string', 'pattern'=>'string'],
'imap_header' => ['object', 'stream_id'=>'resource', 'msg_no'=>'int', 'from_length='=>'int', 'subject_length='=>'int', 'default_host='=>'string'],
'imap_headerinfo' => ['object', 'stream_id'=>'resource', 'msg_no'=>'int', 'from_length='=>'int', 'subject_length='=>'int', 'default_host='=>'string'],
'imap_headers' => ['array', 'stream_id'=>'resource'],
'imap_last_error' => ['string|false'],
'imap_list' => ['array|false', 'stream_id'=>'resource', 'ref'=>'string', 'pattern'=>'string'],
'imap_listmailbox' => ['array', 'stream_id'=>'resource', 'ref'=>'string', 'pattern'=>'string'],
'imap_listscan' => ['array', 'stream_id'=>'resource', 'ref'=>'string', 'pattern'=>'string', 'content'=>'string'],
'imap_listsubscribed' => ['array', 'stream_id'=>'resource', 'ref'=>'string', 'pattern'=>'string'],
'imap_lsub' => ['array', 'stream_id'=>'resource', 'ref'=>'string', 'pattern'=>'string'],
'imap_mail' => ['bool', 'to'=>'string', 'subject'=>'string', 'message'=>'string', 'additional_headers='=>'string', 'cc='=>'string', 'bcc='=>'string', 'rpath='=>'string'],
'imap_mail_compose' => ['string', 'envelope'=>'array', 'body'=>'array'],
'imap_mail_copy' => ['bool', 'stream_id'=>'resource', 'msglist'=>'string', 'mailbox'=>'string', 'options='=>'int'],
'imap_mail_move' => ['bool', 'stream_id'=>'resource', 'sequence'=>'string', 'mailbox'=>'string', 'options='=>'int'],
'imap_mailboxmsginfo' => ['object', 'stream_id'=>'resource'],
'imap_mime_header_decode' => ['array', 'str'=>'string'],
'imap_msgno' => ['int', 'stream_id'=>'resource', 'unique_msg_id'=>'int'],
'imap_mutf7_to_utf8' => ['string', 'in'=>'string'],
'imap_num_msg' => ['int', 'stream_id'=>'resource'],
'imap_num_recent' => ['int', 'stream_id'=>'resource'],
'imap_open' => ['resource|false', 'mailbox'=>'string', 'user'=>'string', 'password'=>'string', 'options='=>'int', 'n_retries='=>'int', 'params=' => 'array|null'],
'imap_ping' => ['bool', 'stream_id'=>'resource'],
'imap_qprint' => ['string', 'text'=>'string'],
'imap_rename' => ['bool', 'stream_id'=>'resource', 'old_name'=>'string', 'new_name'=>'string'],
'imap_renamemailbox' => ['bool', 'stream_id'=>'resource', 'old_name'=>'string', 'new_name'=>'string'],
'imap_reopen' => ['bool', 'stream_id'=>'resource', 'mailbox'=>'string', 'options='=>'int', 'n_retries='=>'int'],
'imap_rfc822_parse_adrlist' => ['array', 'address_string'=>'string', 'default_host'=>'string'],
'imap_rfc822_parse_headers' => ['object', 'headers'=>'string', 'default_host='=>'string'],
'imap_rfc822_write_address' => ['string', 'mailbox'=>'?string', 'host'=>'?string', 'personal'=>'?string'],
'imap_savebody' => ['bool', 'stream_id'=>'resource', 'file'=>'string|resource', 'msg_no'=>'int', 'section='=>'string', 'options='=>'int'],
'imap_scan' => ['array', 'stream_id'=>'resource', 'ref'=>'string', 'pattern'=>'string', 'content'=>'string'],
'imap_scanmailbox' => ['', 'stream_id'=>'resource', 'ref'=>'', 'pattern'=>'', 'content'=>''],
'imap_search' => ['array', 'stream_id'=>'resource', 'criteria'=>'string', 'options='=>'int', 'charset='=>'string'],
'imap_set_quota' => ['bool', 'stream_id'=>'resource', 'qroot'=>'string', 'mailbox_size'=>'int'],
'imap_setacl' => ['bool', 'stream_id'=>'resource', 'mailbox'=>'string', 'id'=>'string', 'rights'=>'string'],
'imap_setflag_full' => ['bool', 'stream_id'=>'resource', 'sequence'=>'string', 'flag'=>'string', 'options='=>'int'],
'imap_sort' => ['array', 'stream_id'=>'resource', 'criteria'=>'int', 'reverse'=>'int', 'options='=>'int', 'search_criteria='=>'string', 'charset='=>'string'],
'imap_status' => ['object', 'stream_id'=>'resource', 'mailbox'=>'string', 'options'=>'int'],
'imap_subscribe' => ['bool', 'stream_id'=>'resource', 'mailbox'=>'string'],
'imap_thread' => ['array', 'stream_id'=>'resource', 'options='=>'int'],
'imap_timeout' => ['mixed', 'timeout_type'=>'int', 'timeout='=>'int'],
'imap_uid' => ['int', 'stream_id'=>'resource', 'msg_no'=>'int'],
'imap_undelete' => ['bool', 'stream_id'=>'resource', 'msg_no'=>'int', 'flags='=>'int'],
'imap_unsubscribe' => ['bool', 'stream_id'=>'resource', 'mailbox'=>'string'],
'imap_utf7_decode' => ['string', 'buf'=>'string'],
'imap_utf7_encode' => ['string', 'buf'=>'string'],
'imap_utf8' => ['string', 'mime_encoded_text'=>'string'],
'imap_utf8_to_mutf7' => ['string', 'in'=>'string'],
'implode' => ['string', 'glue'=>'string', 'pieces'=>'array'],
'implode\'1' => ['string', 'pieces'=>'array', 'glue='=>'string'],
'import_request_variables' => ['bool', 'types'=>'string', 'prefix='=>'string'],
'in_array' => ['bool', 'needle'=>'mixed', 'haystack'=>'array', 'strict='=>'bool'],
'inclued_get_data' => ['array'],
'inet_ntop' => ['string|false', 'in_addr'=>'string'],
'inet_pton' => ['string|false', 'ip_address'=>'string'],
'InfiniteIterator::__construct' => ['void', 'it'=>'iterator'],
'InfiniteIterator::next' => ['void'],
'inflate_add' => ['string|false', 'context'=>'resource', 'encoded_data'=>'string', 'flush_mode='=>'int'],
'inflate_get_read_len' => ['int|false', 'resource'=>'resource'],
'inflate_get_status' => ['int|false', 'resource'=>'resource'],
'inflate_init' => ['resource|false', 'encoding'=>'int', 'options='=>'array'],
'ingres_autocommit' => ['bool', 'link'=>'resource'],
'ingres_autocommit_state' => ['bool', 'link'=>'resource'],
'ingres_charset' => ['string', 'link'=>'resource'],
'ingres_close' => ['bool', 'link'=>'resource'],
'ingres_commit' => ['bool', 'link'=>'resource'],
'ingres_connect' => ['resource', 'database='=>'string', 'username='=>'string', 'password='=>'string', 'options='=>'array'],
'ingres_cursor' => ['string', 'result'=>'resource'],
'ingres_errno' => ['int', 'link='=>'resource'],
'ingres_error' => ['string', 'link='=>'resource'],
'ingres_errsqlstate' => ['string', 'link='=>'resource'],
'ingres_escape_string' => ['string', 'link'=>'resource', 'source_string'=>'string'],
'ingres_execute' => ['bool', 'result'=>'resource', 'params='=>'array', 'types='=>'string'],
'ingres_fetch_array' => ['array', 'result'=>'resource', 'result_type='=>'int'],
'ingres_fetch_assoc' => ['array', 'result'=>'resource'],
'ingres_fetch_object' => ['object', 'result'=>'resource', 'result_type='=>'int'],
'ingres_fetch_proc_return' => ['int', 'result'=>'resource'],
'ingres_fetch_row' => ['array', 'result'=>'resource'],
'ingres_field_length' => ['int', 'result'=>'resource', 'index'=>'int'],
'ingres_field_name' => ['string', 'result'=>'resource', 'index'=>'int'],
'ingres_field_nullable' => ['bool', 'result'=>'resource', 'index'=>'int'],
'ingres_field_precision' => ['int', 'result'=>'resource', 'index'=>'int'],
'ingres_field_scale' => ['int', 'result'=>'resource', 'index'=>'int'],
'ingres_field_type' => ['string', 'result'=>'resource', 'index'=>'int'],
'ingres_free_result' => ['bool', 'result'=>'resource'],
'ingres_next_error' => ['bool', 'link='=>'resource'],
'ingres_num_fields' => ['int', 'result'=>'resource'],
'ingres_num_rows' => ['int', 'result'=>'resource'],
'ingres_pconnect' => ['resource', 'database='=>'string', 'username='=>'string', 'password='=>'string', 'options='=>'array'],
'ingres_prepare' => ['mixed', 'link'=>'resource', 'query'=>'string'],
'ingres_query' => ['mixed', 'link'=>'resource', 'query'=>'string', 'params='=>'array', 'types='=>'string'],
'ingres_result_seek' => ['bool', 'result'=>'resource', 'position'=>'int'],
'ingres_rollback' => ['bool', 'link'=>'resource'],
'ingres_set_environment' => ['bool', 'link'=>'resource', 'options'=>'array'],
'ingres_unbuffered_query' => ['mixed', 'link'=>'resource', 'query'=>'string', 'params='=>'array', 'types='=>'string'],
'ini_alter' => ['string|false', 'varname'=>'string', 'newvalue'=>'string|int|float|bool'],
'ini_get' => ['string|false', 'varname'=>'string'],
'ini_get_all' => ['array', 'extension='=>'?string', 'details='=>'bool'],
'ini_restore' => ['void', 'varname'=>'string'],
'ini_set' => ['string|false', 'varname'=>'string', 'newvalue'=>'string|int|float|bool'],
'inotify_add_watch' => ['int', 'inotify_instance'=>'resource', 'pathname'=>'string', 'mask'=>'int'],
'inotify_init' => ['resource'],
'inotify_queue_len' => ['int', 'inotify_instance'=>'resource'],
'inotify_read' => ['array', 'inotify_instance'=>'resource'],
'inotify_rm_watch' => ['bool', 'inotify_instance'=>'resource', 'watch_descriptor'=>'int'],
'intdiv' => ['int', 'numerator'=>'int', 'divisor'=>'int'],
'interface_exists' => ['bool', 'classname'=>'string', 'autoload='=>'bool'],
'intl_error_name' => ['string', 'error_code'=>'int'],
'intl_get_error_code' => ['int'],
'intl_get_error_message' => ['string'],
'intl_is_failure' => ['bool', 'error_code'=>'int'],
'IntlBreakIterator::__construct' => ['void'],
'IntlBreakIterator::createCharacterInstance' => ['IntlRuleBasedBreakIterator', 'locale='=>'string'],
'IntlBreakIterator::createCodePointInstance' => ['IntlCodePointBreakIterator'],
'IntlBreakIterator::createLineInstance' => ['IntlRuleBasedBreakIterator', 'locale='=>'string'],
'IntlBreakIterator::createSentenceInstance' => ['IntlRuleBasedBreakIterator', 'locale='=>'string'],
'IntlBreakIterator::createTitleInstance' => ['IntlRuleBasedBreakIterator', 'locale='=>'string'],
'IntlBreakIterator::createWordInstance' => ['IntlRuleBasedBreakIterator', 'locale='=>'string'],
'IntlBreakIterator::current' => ['int'],
'IntlBreakIterator::first' => ['int'],
'IntlBreakIterator::following' => ['int', 'offset'=>'string'],
'IntlBreakIterator::getErrorCode' => ['int'],
'IntlBreakIterator::getErrorMessage' => ['string'],
'IntlBreakIterator::getLocale' => ['string', 'locale_type'=>'string'],
'IntlBreakIterator::getPartsIterator' => ['IntlPartsIterator', 'key_type='=>'string'],
'IntlBreakIterator::getText' => ['string'],
'IntlBreakIterator::isBoundary' => ['bool', 'offset'=>'string'],
'IntlBreakIterator::last' => ['int'],
'IntlBreakIterator::next' => ['int', 'offset='=>'string'],
'IntlBreakIterator::preceding' => ['int', 'offset'=>'string'],
'IntlBreakIterator::previous' => ['int'],
'IntlBreakIterator::setText' => ['bool', 'text'=>'string'],
'intlcal_add' => ['bool', 'cal'=>'IntlCalendar', 'field'=>'int', 'amount'=>'int'],
'intlcal_after' => ['bool', 'cal'=>'IntlCalendar', 'other'=>'IntlCalendar'],
'intlcal_before' => ['bool', 'cal'=>'IntlCalendar', 'other'=>'IntlCalendar'],
'intlcal_clear' => ['bool', 'cal'=>'IntlCalendar', 'field='=>'int'],
'intlcal_create_instance' => ['IntlCalendar', 'timeZone='=>'mixed', 'locale='=>'string'],
'intlcal_equals' => ['bool', 'cal'=>'IntlCalendar', 'other'=>'IntlCalendar'],
'intlcal_field_difference' => ['int', 'cal'=>'IntlCalendar', 'when'=>'float', 'field'=>'int'],
'intlcal_from_date_time' => ['IntlCalendar', 'dateTime'=>'DateTime|string'],
'intlcal_get' => ['int', 'cal'=>'IntlCalendar', 'field'=>'int'],
'intlcal_get_actual_maximum' => ['int', 'cal'=>'IntlCalendar', 'field'=>'int'],
'intlcal_get_actual_minimum' => ['int', 'cal'=>'IntlCalendar', 'field'=>'int'],
'intlcal_get_available_locales' => ['array'],
'intlcal_get_day_of_week_type' => ['int', 'cal'=>'IntlCalendar', 'dayOfWeek'=>'int'],
'intlcal_get_first_day_of_week' => ['int', 'cal'=>'IntlCalendar'],
'intlcal_get_greatest_minimum' => ['int', 'cal'=>'IntlCalendar', 'field'=>'int'],
'intlcal_get_keyword_values_for_locale' => ['Iterator', 'key'=>'string', 'locale'=>'string', 'commonlyUsed'=>'bool'],
'intlcal_get_least_maximum' => ['int', 'cal'=>'IntlCalendar', 'field'=>'int'],
'intlcal_get_locale' => ['string', 'cal'=>'IntlCalendar', 'localeType'=>'int'],
'intlcal_get_maximum' => ['int', 'cal'=>'IntlCalendar', 'field'=>'int'],
'intlcal_get_minimal_days_in_first_week' => ['int', 'cal'=>'IntlCalendar'],
'intlcal_get_minimum' => ['int', 'cal'=>'IntlCalendar', 'field'=>'int'],
'intlcal_get_now' => ['float'],
'intlcal_get_repeated_wall_time_option' => ['int', 'cal'=>'IntlCalendar'],
'intlcal_get_skipped_wall_time_option' => ['int', 'cal'=>'IntlCalendar'],
'intlcal_get_time' => ['float', 'cal'=>'IntlCalendar'],
'intlcal_get_time_zone' => ['IntlTimeZone', 'cal'=>'IntlCalendar'],
'intlcal_get_type' => ['string', 'cal'=>'IntlCalendar'],
'intlcal_get_weekend_transition' => ['int', 'cal'=>'IntlCalendar', 'dayOfWeek'=>'string'],
'intlcal_in_daylight_time' => ['bool', 'cal'=>'IntlCalendar'],
'intlcal_is_equivalent_to' => ['bool', 'cal'=>'IntlCalendar', 'other'=>'IntlCalendar'],
'intlcal_is_lenient' => ['bool', 'cal'=>'IntlCalendar'],
'intlcal_is_set' => ['bool', 'cal'=>'IntlCalendar', 'field'=>'int'],
'intlcal_is_weekend' => ['bool', 'cal'=>'IntlCalendar', 'date='=>'float'],
'intlcal_roll' => ['bool', 'cal'=>'IntlCalendar', 'field'=>'int', 'amountOrUpOrDown'=>'mixed'],
'intlcal_set' => ['bool', 'cal'=>'IntlCalendar', 'field'=>'int', 'value'=>'int'],
'intlcal_set\'1' => ['bool', 'cal'=>'IntlCalendar', 'year'=>'int', 'month'=>'int', 'dayOfMonth='=>'int', 'hour='=>'int', 'minute='=>'int', 'second='=>'int'],
'intlcal_set_first_day_of_week' => ['bool', 'cal'=>'IntlCalendar', 'dayOfWeek'=>'int'],
'intlcal_set_lenient' => ['bool', 'cal'=>'IntlCalendar', 'isLenient'=>'bool'],
'intlcal_set_repeated_wall_time_option' => ['bool', 'cal'=>'IntlCalendar', 'wallTimeOption'=>'int'],
'intlcal_set_skipped_wall_time_option' => ['bool', 'cal'=>'IntlCalendar', 'wallTimeOption'=>'int'],
'intlcal_set_time' => ['bool', 'cal'=>'IntlCalendar', 'date'=>'float'],
'intlcal_set_time_zone' => ['bool', 'cal'=>'IntlCalendar', 'timeZone'=>'mixed'],
'intlcal_to_date_time' => ['DateTime', 'cal'=>'IntlCalendar'],
'IntlCalendar::__construct' => ['void'],
'IntlCalendar::add' => ['bool', 'field'=>'int', 'amount'=>'int'],
'IntlCalendar::after' => ['bool', 'other'=>'IntlCalendar'],
'IntlCalendar::before' => ['bool', 'other'=>'IntlCalendar'],
'IntlCalendar::clear' => ['bool', 'field='=>'int'],
'IntlCalendar::createInstance' => ['IntlCalendar', 'timeZone='=>'mixed', 'locale='=>'string'],
'IntlCalendar::equals' => ['bool', 'other'=>'IntlCalendar'],
'IntlCalendar::fieldDifference' => ['int', 'when'=>'float', 'field'=>'int'],
'IntlCalendar::fromDateTime' => ['IntlCalendar', 'dateTime'=>'DateTime|string'],
'IntlCalendar::get' => ['int', 'field'=>'int'],
'IntlCalendar::getActualMaximum' => ['int', 'field'=>'int'],
'IntlCalendar::getActualMinimum' => ['int', 'field'=>'int'],
'IntlCalendar::getAvailableLocales' => ['array'],
'IntlCalendar::getDayOfWeekType' => ['int', 'dayOfWeek'=>'int'],
'IntlCalendar::getErrorCode' => ['int'],
'IntlCalendar::getErrorMessage' => ['string'],
'IntlCalendar::getFirstDayOfWeek' => ['int'],
'IntlCalendar::getGreatestMinimum' => ['int', 'field'=>'int'],
'IntlCalendar::getKeywordValuesForLocale' => ['Iterator', 'key'=>'string', 'locale'=>'string', 'commonlyUsed'=>'bool'],
'IntlCalendar::getLeastMaximum' => ['int', 'field'=>'int'],
'IntlCalendar::getLocale' => ['string', 'localeType'=>'int'],
'IntlCalendar::getMaximum' => ['int', 'field'=>'int'],
'IntlCalendar::getMinimalDaysInFirstWeek' => ['int'],
'IntlCalendar::getMinimum' => ['int', 'field'=>'int'],
'IntlCalendar::getNow' => ['float'],
'IntlCalendar::getRepeatedWallTimeOption' => ['int'],
'IntlCalendar::getSkippedWallTimeOption' => ['int'],
'IntlCalendar::getTime' => ['float'],
'IntlCalendar::getTimeZone' => ['IntlTimeZone'],
'IntlCalendar::getType' => ['string'],
'IntlCalendar::getWeekendTransition' => ['int', 'dayOfWeek'=>'string'],
'IntlCalendar::inDaylightTime' => ['bool'],
'IntlCalendar::isEquivalentTo' => ['bool', 'other'=>'IntlCalendar'],
'IntlCalendar::isLenient' => ['bool'],
'IntlCalendar::isSet' => ['bool', 'field'=>'int'],
'IntlCalendar::isWeekend' => ['bool', 'date='=>'float'],
'IntlCalendar::roll' => ['bool', 'field'=>'int', 'amountOrUpOrDown'=>'mixed'],
'IntlCalendar::set' => ['bool', 'field'=>'int', 'value'=>'int'],
'IntlCalendar::set\'1' => ['bool', 'year'=>'int', 'month'=>'int', 'dayOfMonth='=>'int', 'hour='=>'int', 'minute='=>'int', 'second='=>'int'],
'IntlCalendar::setFirstDayOfWeek' => ['bool', 'dayOfWeek'=>'int'],
'IntlCalendar::setLenient' => ['bool', 'isLenient'=>'string'],
'IntlCalendar::setMinimalDaysInFirstWeek' => ['bool', 'minimalDays'=>'int'],
'IntlCalendar::setRepeatedWallTimeOption' => ['bool', 'wallTimeOption'=>'int'],
'IntlCalendar::setSkippedWallTimeOption' => ['bool', 'wallTimeOption'=>'int'],
'IntlCalendar::setTime' => ['bool', 'date'=>'float'],
'IntlCalendar::setTimeZone' => ['bool', 'timeZone'=>'mixed'],
'IntlCalendar::toDateTime' => ['DateTime'],
'IntlChar::charAge' => ['array', 'char'=>'int|string'],
'IntlChar::charDigitValue' => ['int', 'codepoint'=>'mixed'],
'IntlChar::charDirection' => ['int', 'codepoint'=>'mixed'],
'IntlChar::charFromName' => ['int', 'name'=>'string', 'namechoice='=>'int'],
'IntlChar::charMirror' => ['mixed', 'codepoint'=>'mixed'],
'IntlChar::charName' => ['string', 'char'=>'int|string', 'namechoice='=>'int'],
'IntlChar::charType' => ['int', 'codepoint'=>'mixed'],
'IntlChar::chr' => ['string', 'codepoint'=>'mixed'],
'IntlChar::digit' => ['int', 'char'=>'int|string', 'radix='=>'int'],
'IntlChar::enumCharNames' => ['void', 'start'=>'mixed', 'limit'=>'mixed', 'callback'=>'callable', 'nameChoice='=>'int'],
'IntlChar::enumCharTypes' => ['void', 'cb='=>'callable'],
'IntlChar::foldCase' => ['int|string', 'char'=>'int|string', 'options='=>'int'],
'IntlChar::forDigit' => ['int', 'digit'=>'int', 'radix'=>'int'],
'IntlChar::getBidiPairedBracket' => ['mixed', 'codepoint'=>'mixed'],
'IntlChar::getBlockCode' => ['int', 'char'=>'int|string'],
'IntlChar::getCombiningClass' => ['int', 'codepoint'=>'mixed'],
'IntlChar::getFC_NFKC_Closure' => ['string', 'char'=>'int|string'],
'IntlChar::getIntPropertyMaxValue' => ['int', 'property'=>'int'],
'IntlChar::getIntPropertyMinValue' => ['int', 'property'=>'int'],
'IntlChar::getIntPropertyMxValue' => ['int', 'property'=>'int'],
'IntlChar::getIntPropertyValue' => ['int', 'char'=>'int|string', 'property'=>'int'],
'IntlChar::getNumericValue' => ['float', 'char'=>'int|string'],
'IntlChar::getPropertyEnum' => ['int', 'alias'=>'string'],
'IntlChar::getPropertyName' => ['string', 'property'=>'int', 'namechoice='=>'int'],
'IntlChar::getPropertyValueEnum' => ['int', 'property'=>'int', 'name'=>'string'],
'IntlChar::getPropertyValueName' => ['string', 'prop'=>'int', 'val'=>'int', 'namechoice='=>'int'],
'IntlChar::getUnicodeVersion' => ['array'],
'IntlChar::hasBinaryProperty' => ['bool', 'char'=>'int|string', 'property'=>'int'],
'IntlChar::isalnum' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isalpha' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isbase' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isblank' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::iscntrl' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isdefined' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isdigit' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isgraph' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isIDIgnorable' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isIDPart' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isIDStart' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isISOControl' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isJavaIDPart' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isJavaIDStart' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isJavaSpaceChar' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::islower' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isMirrored' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isprint' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::ispunct' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isspace' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::istitle' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isUAlphabetic' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isULowercase' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isupper' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isUUppercase' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isUWhiteSpace' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isWhitespace' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::isxdigit' => ['bool', 'codepoint'=>'mixed'],
'IntlChar::ord' => ['int', 'character'=>'mixed'],
'IntlChar::tolower' => ['mixed', 'codepoint'=>'mixed'],
'IntlChar::totitle' => ['mixed', 'codepoint'=>'mixed'],
'IntlChar::toupper' => ['mixed', 'codepoint'=>'mixed'],
'IntlCodePointBreakIterator::getLastCodePoint' => ['int'],
'IntlDateFormatter::__construct' => ['void', 'locale'=>'string', 'datetype'=>'?int', 'timetype'=>'?int', 'timezone='=>'null|string|IntlTimeZone|DateTimeZone', 'calendar='=>'null|int|IntlCalendar', 'pattern='=>'string'],
'IntlDateFormatter::create' => ['IntlDateFormatter', 'locale'=>'string', 'datetype'=>'int', 'timetype'=>'int', 'timezone='=>'null|string|IntlTimeZone|DateTimeZone', 'calendar='=>'int|IntlCalendar', 'pattern='=>'string'],
'IntlDateFormatter::format' => ['string', 'args'=>''],
'IntlDateFormatter::formatObject' => ['string', 'object'=>'object', 'format='=>'mixed', 'locale='=>'string'],
'IntlDateFormatter::getCalendar' => ['int'],
'IntlDateFormatter::getCalendarObject' => ['IntlCalendar'],
'IntlDateFormatter::getDateType' => ['int'],
'IntlDateFormatter::getErrorCode' => ['int'],
'IntlDateFormatter::getErrorMessage' => ['string'],
'IntlDateFormatter::getLocale' => ['string'],
'IntlDateFormatter::getPattern' => ['string'],
'IntlDateFormatter::getTimeType' => ['int'],
'IntlDateFormatter::getTimeZone' => ['IntlTimeZone'],
'IntlDateFormatter::getTimeZoneId' => ['string'],
'IntlDateFormatter::isLenient' => ['bool'],
'IntlDateFormatter::localtime' => ['array', 'text_to_parse'=>'string', '&w_parse_pos='=>'int'],
'IntlDateFormatter::parse' => ['int', 'text_to_parse'=>'string', '&rw_parse_pos='=>'int'],
'IntlDateFormatter::setCalendar' => ['bool', 'calendar'=>''],
'IntlDateFormatter::setLenient' => ['bool', 'lenient'=>'bool'],
'IntlDateFormatter::setPattern' => ['bool', 'pattern'=>'string'],
'IntlDateFormatter::setTimeZone' => ['bool', 'timezone'=>''],
'IntlDateFormatter::setTimeZoneId' => ['bool', 'zone'=>'string', 'fmt='=>'IntlDateFormatter'],
'IntlGregorianCalendar::getGregorianChange' => ['float'],
'IntlGregorianCalendar::isLeapYear' => ['bool', 'year'=>'int'],
'IntlGregorianCalendar::setGregorianChange' => ['bool', 'date'=>'float'],
'IntlIterator::current' => ['mixed'],
'IntlIterator::key' => ['string'],
'IntlIterator::next' => ['void'],
'IntlIterator::rewind' => ['void'],
'IntlIterator::valid' => ['bool'],
'IntlPartsIterator::getBreakIterator' => ['IntlBreakIterator'],
'IntlRuleBasedBreakIterator::__construct' => ['void', 'rules'=>'string', 'areCompiled='=>'string'],
'IntlRuleBasedBreakIterator::createCharacterInstance' => ['IntlRuleBasedBreakIterator', 'locale'=>'string'],
'IntlRuleBasedBreakIterator::createCodePointInstance' => ['IntlCodePointBreakIterator'],
'IntlRuleBasedBreakIterator::createLineInstance' => ['IntlRuleBasedBreakIterator', 'locale'=>'string'],
'IntlRuleBasedBreakIterator::createSentenceInstance' => ['IntlRuleBasedBreakIterator', 'locale'=>'string'],
'IntlRuleBasedBreakIterator::createTitleInstance' => ['IntlRuleBasedBreakIterator', 'locale'=>'string'],
'IntlRuleBasedBreakIterator::createWordInstance' => ['IntlRuleBasedBreakIterator', 'locale'=>'string'],
'IntlRuleBasedBreakIterator::current' => ['int'],
'IntlRuleBasedBreakIterator::first' => ['int'],
'IntlRuleBasedBreakIterator::following' => ['int', 'offset'=>'string'],
'IntlRuleBasedBreakIterator::getBinaryRules' => ['string'],
'IntlRuleBasedBreakIterator::getErrorCode' => ['int'],
'IntlRuleBasedBreakIterator::getErrorMessage' => ['string'],
'IntlRuleBasedBreakIterator::getLocale' => ['string', 'locale_type'=>'string'],
'IntlRuleBasedBreakIterator::getPartsIterator' => ['IntlPartsIterator', 'key_type='=>'string'],
'IntlRuleBasedBreakIterator::getRules' => ['string'],
'IntlRuleBasedBreakIterator::getRuleStatus' => ['int'],
'IntlRuleBasedBreakIterator::getRuleStatusVec' => ['array'],
'IntlRuleBasedBreakIterator::getText' => ['string'],
'IntlRuleBasedBreakIterator::isBoundary' => ['bool', 'offset'=>'string'],
'IntlRuleBasedBreakIterator::last' => ['int'],
'IntlRuleBasedBreakIterator::next' => ['int', 'offset='=>'string'],
'IntlRuleBasedBreakIterator::preceding' => ['int', 'offset'=>'string'],
'IntlRuleBasedBreakIterator::previous' => ['int'],
'IntlRuleBasedBreakIterator::setText' => ['bool', 'text'=>'string'],
'IntlTimeZone::countEquivalentIDs' => ['int', 'zoneId'=>'string'],
'IntlTimeZone::createDefault' => ['IntlTimeZone'],
'IntlTimeZone::createEnumeration' => ['IntlIterator', 'countryOrRawOffset='=>'mixed'],
'IntlTimeZone::createTimeZone' => ['IntlTimeZone', 'zoneId'=>'string'],
'IntlTimeZone::createTimeZoneIDEnumeration' => ['IntlIterator', 'zoneType'=>'int', 'region='=>'string', 'rawOffset='=>'int'],
'IntlTimeZone::fromDateTimeZone' => ['IntlTimeZone', 'zoneId'=>'DateTimeZone'],
'IntlTimeZone::getCanonicalID' => ['string', 'zoneId'=>'string', '&w_isSystemID='=>'bool'],
'IntlTimeZone::getDisplayName' => ['string', 'isDaylight='=>'bool', 'style='=>'int', 'locale='=>'string'],
'IntlTimeZone::getDSTSavings' => ['int'],
'IntlTimeZone::getEquivalentID' => ['string', 'zoneId'=>'string', 'index'=>'int'],
'IntlTimeZone::getErrorCode' => ['int'],
'IntlTimeZone::getErrorMessage' => ['string'],
'IntlTimeZone::getGMT' => ['IntlTimeZone'],
'IntlTimeZone::getID' => ['string'],
'IntlTimeZone::getIDForWindowsID' => ['string', 'timezone'=>'string', 'region='=>'string'],
'IntlTimeZone::getOffset' => ['int', 'date'=>'float', 'local'=>'bool', '&w_rawOffset'=>'int', '&w_dstOffset'=>'int'],
'IntlTimeZone::getRawOffset' => ['int'],
'IntlTimeZone::getRegion' => ['string', 'zoneId'=>'string'],
'IntlTimeZone::getTZDataVersion' => ['string'],
'IntlTimeZone::getUnknown' => ['IntlTimeZone'],
'IntlTimeZone::getWindowsID' => ['string', 'timezone'=>'string'],
'IntlTimeZone::hasSameRules' => ['bool', 'otherTimeZone'=>'IntlTimeZone'],
'IntlTimeZone::toDateTimeZone' => ['DateTimeZone'],
'IntlTimeZone::useDaylightTime' => ['bool'],
'intltz_count_equivalent_ids' => ['int', 'zoneId'=>'string'],
'intltz_create_enumeration' => ['IntlIterator', 'countryOrRawOffset'=>'mixed'],
'intltz_create_time_zone' => ['IntlTimeZone', 'zoneId'=>'string'],
'intltz_from_date_time_zone' => ['IntlTimeZone', 'zoneId'=>'DateTimeZone'],
'intltz_get_canonical_id' => ['string', 'zoneId'=>'string', '&isSystemID'=>'bool'],
'intltz_get_display_name' => ['string', 'obj'=>'IntlTimeZone', 'isDaylight'=>'bool', 'style'=>'int', 'locale'=>'string'],
'intltz_get_dst_savings' => ['int', 'obj'=>'IntlTimeZone'],
'intltz_get_equivalent_id' => ['string', 'zoneId'=>'string', 'index'=>'int'],
'intltz_get_error_code' => ['int', 'obj'=>'IntlTimeZone'],
'intltz_get_error_message' => ['string', 'obj'=>'IntlTimeZone'],
'intltz_get_id' => ['string', 'obj'=>'IntlTimeZone'],
'intltz_get_offset' => ['int', 'obj'=>'IntlTimeZone', 'date'=>'float', 'local'=>'bool', '&rawOffset'=>'int', '&dstOffset'=>'int'],
'intltz_get_raw_offset' => ['int', 'obj'=>'IntlTimeZone'],
'intltz_get_tz_data_version' => ['string', 'obj'=>'IntlTimeZone'],
'intltz_getGMT' => ['IntlTimeZone'],
'intltz_has_same_rules' => ['bool', 'obj'=>'IntlTimeZone', 'otherTimeZone'=>'IntlTimeZone'],
'intltz_to_date_time_zone' => ['DateTimeZone', 'obj'=>''],
'intltz_use_daylight_time' => ['bool', 'obj'=>''],
'intlz_create_default' => ['IntlTimeZone'],
'intval' => ['int', 'var'=>'mixed', 'base='=>'int'],
'InvalidArgumentException::__clone' => ['void'],
'InvalidArgumentException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?InvalidArgumentException'],
'InvalidArgumentException::__toString' => ['string'],
'InvalidArgumentException::getCode' => ['int'],
'InvalidArgumentException::getFile' => ['string'],
'InvalidArgumentException::getLine' => ['int'],
'InvalidArgumentException::getMessage' => ['string'],
'InvalidArgumentException::getPrevious' => ['Throwable|InvalidArgumentException|null'],
'InvalidArgumentException::getTrace' => ['array'],
'InvalidArgumentException::getTraceAsString' => ['string'],
'ip2long' => ['int|false', 'ip_address'=>'string'],
'iptcembed' => ['array', 'iptcdata'=>'string', 'jpeg_file_name'=>'string', 'spool='=>'int'],
'iptcparse' => ['array|false', 'iptcdata'=>'string'],
'is_a' => ['bool', 'object_or_string'=>'object|string', 'class_name'=>'string', 'allow_string='=>'bool'],
'is_array' => ['bool', 'var'=>'mixed'],
'is_bool' => ['bool', 'var'=>'mixed'],
'is_callable' => ['bool', 'var'=>'mixed', 'syntax_only='=>'bool', '&w_callable_name='=>'string'],
'is_dir' => ['bool', 'filename'=>'string'],
'is_double' => ['bool', 'var'=>''],
'is_executable' => ['bool', 'filename'=>'string'],
'is_file' => ['bool', 'filename'=>'string'],
'is_finite' => ['bool', 'val'=>'float'],
'is_float' => ['bool', 'var'=>'mixed'],
'is_infinite' => ['bool', 'val'=>'float'],
'is_int' => ['bool', 'var'=>'mixed'],
'is_integer' => ['bool', 'var'=>''],
'is_iterable' => ['bool', 'var'=>'mixed'],
'is_link' => ['bool', 'filename'=>'string'],
'is_long' => ['bool', 'var'=>''],
'is_nan' => ['bool', 'val'=>'float'],
'is_null' => ['bool', 'var'=>'mixed'],
'is_numeric' => ['bool', 'value'=>'mixed'],
'is_object' => ['bool', 'var'=>'mixed'],
'is_readable' => ['bool', 'filename'=>'string'],
'is_real' => ['bool', 'var'=>''],
'is_resource' => ['bool', 'var'=>'mixed'],
'is_scalar' => ['bool', 'value'=>'mixed'],
'is_soap_fault' => ['bool', 'object'=>'mixed'],
'is_string' => ['bool', 'var'=>'mixed'],
'is_subclass_of' => ['bool', 'object_or_string'=>'object|string', 'class_name'=>'string', 'allow_string='=>'bool'],
'is_tainted' => ['bool', 'string'=>'string'],
'is_uploaded_file' => ['bool', 'path'=>'string'],
'is_writable' => ['bool', 'filename'=>'string'],
'is_writeable' => ['bool', 'filename'=>'string'],
'isset' => ['bool', 'var'=>'mixed', '...rest='=>'mixed'],
'Iterator::current' => ['mixed'],
'Iterator::key' => ['mixed'],
'Iterator::next' => ['void'],
'Iterator::rewind' => ['void'],
'Iterator::valid' => ['bool'],
'iterator_apply' => ['int', 'it'=>'Traversable', 'function'=>'callable', 'params='=>'array'],
'iterator_count' => ['int', 'it'=>'Traversable'],
'iterator_to_array' => ['array', 'it'=>'Traversable', 'use_keys='=>'bool'],
'IteratorAggregate::getIterator' => ['Traversable'],
'IteratorIterator::__construct' => ['void', 'it'=>'Traversable'],
'IteratorIterator::current' => ['mixed'],
'IteratorIterator::getInnerIterator' => ['Traversable'],
'IteratorIterator::key' => ['mixed'],
'IteratorIterator::next' => ['void'],
'IteratorIterator::rewind' => ['void'],
'IteratorIterator::valid' => ['bool'],
'java_last_exception_clear' => [''],
'java_last_exception_get' => ['object'],
'java_reload' => ['array', 'new_jarpath'=>'new_jarpath'],
'java_require' => ['array', 'new_classpath'=>'new_classpath'],
'java_set_encoding' => ['array', 'encoding'=>'encoding'],
'java_set_ignore_case' => ['void', 'ignore'=>'ignore'],
'java_throw_exceptions' => ['void', 'throw'=>'throw'],
'JavaException::getCause' => ['object'],
'jddayofweek' => ['mixed', 'juliandaycount'=>'int', 'mode'=>'int'],
'jdmonthname' => ['string', 'juliandaycount'=>'int', 'mode'=>'int'],
'jdtofrench' => ['string', 'juliandaycount'=>'int'],
'jdtogregorian' => ['string', 'juliandaycount'=>'int'],
'jdtojewish' => ['string', 'juliandaycount'=>'int', 'hebrew='=>'bool', 'fl='=>'int'],
'jdtojulian' => ['string', 'juliandaycount'=>'int'],
'jdtounix' => ['int|false', 'jday'=>'int'],
'jewishtojd' => ['int', 'month'=>'int', 'day'=>'int', 'year'=>'int'],
'jobqueue_license_info' => ['array'],
'join' => ['string', 'glue'=>'string', 'pieces'=>'array'],
'join\'1' => ['string', 'pieces'=>'array'],
'jpeg2wbmp' => ['bool', 'jpegname'=>'string', 'wbmpname'=>'string', 'dest_height'=>'int', 'dest_width'=>'int', 'threshold'=>'int'],
'json_decode' => ['mixed', 'json'=>'string', 'assoc='=>'bool', 'depth='=>'int', 'options='=>'int'],
'json_encode' => ['string|false', 'data'=>'mixed', 'options='=>'int', 'depth='=>'int'],
'json_last_error' => ['int'],
'json_last_error_msg' => ['string'],
'JsonIncrementalParser::__construct' => ['void', 'depth'=>'', 'options'=>''],
'JsonIncrementalParser::get' => ['', 'options'=>''],
'JsonIncrementalParser::getError' => [''],
'JsonIncrementalParser::parse' => ['', 'json'=>''],
'JsonIncrementalParser::parseFile' => ['', 'filename'=>''],
'JsonIncrementalParser::reset' => [''],
'JsonSerializable::jsonSerialize' => ['mixed'],
'Judy::__construct' => ['void', 'judy_type'=>'int'],
'Judy::__destruct' => [''],
'Judy::byCount' => ['int', 'nth_index'=>'int'],
'Judy::count' => ['int', 'index_start='=>'int', 'index_end='=>'int'],
'Judy::first' => ['mixed', 'index='=>'mixed'],
'Judy::firstEmpty' => ['int', 'index='=>'mixed'],
'Judy::free' => ['int'],
'Judy::getType' => ['int'],
'Judy::last' => ['void', 'index='=>'string'],
'Judy::lastEmpty' => ['int', 'index='=>'int'],
'Judy::memoryUsage' => ['int'],
'Judy::next' => ['mixed', 'index'=>'mixed'],
'Judy::nextEmpty' => ['int', 'index'=>'int'],
'Judy::offsetExists' => ['bool', 'offset'=>'mixed'],
'Judy::offsetGet' => ['mixed', 'offset'=>'mixed'],
'Judy::offsetSet' => ['bool', 'offset'=>'mixed', 'value'=>'mixed'],
'Judy::offsetUnset' => ['bool', 'offset'=>'mixed'],
'Judy::prev' => ['mixed', 'index'=>'mixed'],
'Judy::prevEmpty' => ['int', 'index'=>'mixed'],
'Judy::size' => ['void'],
'judy_type' => ['int', 'array'=>'judy'],
'judy_version' => ['string'],
'juliantojd' => ['int', 'month'=>'int', 'day'=>'int', 'year'=>'int'],
'kadm5_chpass_principal' => ['bool', 'handle'=>'resource', 'principal'=>'string', 'password'=>'string'],
'kadm5_create_principal' => ['bool', 'handle'=>'resource', 'principal'=>'string', 'password='=>'string', 'options='=>'array'],
'kadm5_delete_principal' => ['bool', 'handle'=>'resource', 'principal'=>'string'],
'kadm5_destroy' => ['bool', 'handle'=>'resource'],
'kadm5_flush' => ['bool', 'handle'=>'resource'],
'kadm5_get_policies' => ['array', 'handle'=>'resource'],
'kadm5_get_principal' => ['array', 'handle'=>'resource', 'principal'=>'string'],
'kadm5_get_principals' => ['array', 'handle'=>'resource'],
'kadm5_init_with_password' => ['resource', 'admin_server'=>'string', 'realm'=>'string', 'principal'=>'string', 'password'=>'string'],
'kadm5_modify_principal' => ['bool', 'handle'=>'resource', 'principal'=>'string', 'options'=>'array'],
'key' => ['int|string|null', 'array_arg'=>'array|object'],
'key_exists' => ['bool', 'key'=>'string|int', 'search'=>'array'],
'krsort' => ['bool', '&rw_array_arg'=>'array', 'sort_flags='=>'int'],
'ksort' => ['bool', '&rw_array_arg'=>'array', 'sort_flags='=>'int'],
'KTaglib_ID3v2_AttachedPictureFrame::getDescription' => ['string'],
'KTaglib_ID3v2_AttachedPictureFrame::getMimeType' => ['string'],
'KTaglib_ID3v2_AttachedPictureFrame::getType' => ['int'],
'KTaglib_ID3v2_AttachedPictureFrame::savePicture' => ['bool', 'filename'=>'string'],
'KTaglib_ID3v2_AttachedPictureFrame::setMimeType' => ['string', 'type'=>'string'],
'KTaglib_ID3v2_AttachedPictureFrame::setPicture' => ['', 'filename'=>'string'],
'KTaglib_ID3v2_AttachedPictureFrame::setType' => ['', 'type'=>'int'],
'KTaglib_ID3v2_Frame::__toString' => ['string'],
'KTaglib_ID3v2_Frame::getSize' => ['int'],
'KTaglib_ID3v2_Tag::addFrame' => ['bool', 'frame'=>'ktaglib_id3v2_frame'],
'KTaglib_ID3v2_Tag::getFrameList' => ['array'],
'KTaglib_MPEG_AudioProperties::getBitrate' => ['int'],
'KTaglib_MPEG_AudioProperties::getChannels' => ['int'],
'KTaglib_MPEG_AudioProperties::getLayer' => ['int'],
'KTaglib_MPEG_AudioProperties::getLength' => ['int'],
'KTaglib_MPEG_AudioProperties::getSampleBitrate' => ['int'],
'KTaglib_MPEG_AudioProperties::getVersion' => ['int'],
'KTaglib_MPEG_AudioProperties::isCopyrighted' => ['bool'],
'KTaglib_MPEG_AudioProperties::isOriginal' => ['bool'],
'KTaglib_MPEG_AudioProperties::isProtectionEnabled' => ['bool'],
'KTaglib_MPEG_File::getAudioProperties' => ['KTaglib_MPEG_File'],
'KTaglib_MPEG_File::getID3v1Tag' => ['KTaglib_ID3v1_Tag', 'create='=>'bool'],
'KTaglib_MPEG_File::getID3v2Tag' => ['KTaglib_ID3v2_Tag', 'create='=>'bool'],
'KTaglib_Tag::getAlbum' => ['string'],
'KTaglib_Tag::getArtist' => ['string'],
'KTaglib_Tag::getComment' => ['string'],
'KTaglib_Tag::getGenre' => ['string'],
'KTaglib_Tag::getTitle' => ['string'],
'KTaglib_Tag::getTrack' => ['int'],
'KTaglib_Tag::getYear' => ['int'],
'KTaglib_Tag::isEmpty' => ['bool'],
'labelcacheObj::freeCache' => ['bool'],
'labelObj::__construct' => ['void'],
'labelObj::convertToString' => ['string'],
'labelObj::deleteStyle' => ['int', 'index'=>'int'],
'labelObj::free' => ['void'],
'labelObj::getBinding' => ['string', 'labelbinding'=>'mixed'],
'labelObj::getExpressionString' => ['string'],
'labelObj::getStyle' => ['styleObj', 'index'=>'int'],
'labelObj::getTextString' => ['string'],
'labelObj::moveStyleDown' => ['int', 'index'=>'int'],
'labelObj::moveStyleUp' => ['int', 'index'=>'int'],
'labelObj::removeBinding' => ['int', 'labelbinding'=>'mixed'],
'labelObj::set' => ['int', 'property_name'=>'string', 'new_value'=>''],
'labelObj::setBinding' => ['int', 'labelbinding'=>'mixed', 'value'=>'string'],
'labelObj::setExpression' => ['int', 'expression'=>'string'],
'labelObj::setText' => ['int', 'text'=>'string'],
'labelObj::updateFromString' => ['int', 'snippet'=>'string'],
'Lapack::eigenValues' => ['array', 'a'=>'array', 'left='=>'array', 'right='=>'array'],
'Lapack::identity' => ['array', 'n'=>'int'],
'Lapack::leastSquaresByFactorisation' => ['array', 'a'=>'array', 'b'=>'array'],
'Lapack::leastSquaresBySVD' => ['array', 'a'=>'array', 'b'=>'array'],
'Lapack::pseudoInverse' => ['array', 'a'=>'array'],
'Lapack::singularValues' => ['array', 'a'=>'array'],
'Lapack::solveLinearEquation' => ['array', 'a'=>'array', 'b'=>'array'],
'layerObj::addFeature' => ['int', 'shape'=>'shapeObj'],
'layerObj::applySLD' => ['int', 'sldxml'=>'string', 'namedlayer'=>'string'],
'layerObj::applySLDURL' => ['int', 'sldurl'=>'string', 'namedlayer'=>'string'],
'layerObj::clearProcessing' => ['void'],
'layerObj::close' => ['void'],
'layerObj::convertToString' => ['string'],
'layerObj::draw' => ['int', 'image'=>'imageObj'],
'layerObj::drawQuery' => ['int', 'image'=>'imageObj'],
'layerObj::free' => ['void'],
'layerObj::generateSLD' => ['string'],
'layerObj::getClass' => ['classObj', 'classIndex'=>'int'],
'layerObj::getClassIndex' => ['int', 'shape'=>'', 'classgroup'=>'', 'numclasses'=>''],
'layerObj::getExtent' => ['rectObj'],
'layerObj::getFilterString' => ['string'],
'layerObj::getGridIntersectionCoordinates' => ['array'],
'layerObj::getItems' => ['array'],
'layerObj::getMetaData' => ['int', 'name'=>'string'],
'layerObj::getNumResults' => ['int'],
'layerObj::getProcessing' => ['array'],
'layerObj::getProjection' => ['string'],
'layerObj::getResult' => ['resultObj', 'index'=>'int'],
'layerObj::getResultsBounds' => ['rectObj'],
'layerObj::getShape' => ['shapeObj', 'result'=>'resultObj'],
'layerObj::getWMSFeatureInfoURL' => ['string', 'clickX'=>'int', 'clickY'=>'int', 'featureCount'=>'int', 'infoFormat'=>'string'],
'layerObj::isVisible' => ['bool'],
'layerObj::moveclassdown' => ['int', 'index'=>'int'],
'layerObj::moveclassup' => ['int', 'index'=>'int'],
'layerObj::ms_newLayerObj' => ['layerObj', 'map'=>'MapObj', 'layer'=>'layerObj'],
'layerObj::nextShape' => ['shapeObj'],
'layerObj::open' => ['int'],
'layerObj::queryByAttributes' => ['int', 'qitem'=>'string', 'qstring'=>'string', 'mode'=>'int'],
'layerObj::queryByFeatures' => ['int', 'slayer'=>'int'],
'layerObj::queryByPoint' => ['int', 'point'=>'pointObj', 'mode'=>'int', 'buffer'=>'float'],
'layerObj::queryByRect' => ['int', 'rect'=>'rectObj'],
'layerObj::queryByShape' => ['int', 'shape'=>'shapeObj'],
'layerObj::removeClass' => ['classObj', 'index'=>'int'],
'layerObj::removeMetaData' => ['int', 'name'=>'string'],
'layerObj::set' => ['int', 'property_name'=>'string', 'new_value'=>''],
'layerObj::setConnectionType' => ['int', 'connectiontype'=>'int', 'plugin_library'=>'string'],
'layerObj::setFilter' => ['int', 'expression'=>'string'],
'layerObj::setMetaData' => ['int', 'name'=>'string', 'value'=>'string'],
'layerObj::setProjection' => ['int', 'proj_params'=>'string'],
'layerObj::setWKTProjection' => ['int', 'proj_params'=>'string'],
'layerObj::updateFromString' => ['int', 'snippet'=>'string'],
'lcfirst' => ['string', 'str'=>'string'],
'lcg_value' => ['float'],
'lchgrp' => ['bool', 'filename'=>'string', 'group'=>'string|int'],
'lchown' => ['bool', 'filename'=>'string', 'user'=>'string|int'],
'ldap_8859_to_t61' => ['string', 'value'=>'string'],
'ldap_add' => ['bool', 'link_identifier'=>'resource', 'dn'=>'string', 'entry'=>'array'],
'ldap_bind' => ['bool', 'link_identifier'=>'resource', 'dn='=>'string', 'password='=>'string'],
'ldap_close' => ['bool', 'link_identifier'=>'resource'],
'ldap_compare' => ['bool', 'link_identifier'=>'resource', 'dn'=>'string', 'attr'=>'string', 'value'=>'string'],
'ldap_connect' => ['resource|false', 'host='=>'string', 'port='=>'int', 'wallet='=>'string', 'wallet_passwd='=>'string', 'authmode='=>'int'],
'ldap_control_paged_result' => ['bool', 'link_identifier'=>'resource', 'pagesize'=>'int', 'iscritical'=>'bool', 'cookie'=>'string'],
'ldap_control_paged_result_response' => ['bool', 'link_identifier'=>'resource', 'result_identifier'=>'resource', '&w_cookie'=>'string', '&w_estimated'=>'int'],
'ldap_count_entries' => ['int', 'link_identifier'=>'resource', 'result'=>'resource'],
'ldap_delete' => ['bool', 'link_identifier'=>'resource', 'dn'=>'string'],
'ldap_dn2ufn' => ['string', 'dn'=>'string'],
'ldap_err2str' => ['string', 'errno'=>'int'],
'ldap_errno' => ['int', 'link_identifier'=>'resource'],
'ldap_error' => ['string', 'link_identifier'=>'resource'],
'ldap_escape' => ['string', 'value'=>'string', 'ignore='=>'string', 'flags='=>'int'],
'ldap_exop' => ['mixed', 'link'=>'resource', 'reqoid'=>'string', 'reqdata='=>'string', 'servercontrols='=>'array', 'retdata='=>'string', 'retoid='=>'string'],
'ldap_exop_passwd' => ['mixed', 'link'=>'resource', 'user='=>'string', 'oldpw='=>'string', 'newpw='=>'string', 'serverctrls='=>'array'],
'ldap_exop_refresh' => ['int', 'link'=>'resource', 'dn'=>'string', 'ttl'=>'int'],
'ldap_exop_whoami' => ['string', 'link'=>'resource'],
'ldap_explode_dn' => ['array', 'dn'=>'string', 'with_attrib'=>'int'],
'ldap_first_attribute' => ['string', 'link_identifier'=>'resource', 'result_entry_identifier'=>'resource'],
'ldap_first_entry' => ['resource|false', 'link_identifier'=>'resource', 'result_identifier'=>'resource'],
'ldap_first_reference' => ['resource|false', 'link_identifier'=>'resource', 'result_identifier'=>'resource'],
'ldap_free_result' => ['bool', 'result_identifier'=>'resource'],
'ldap_get_attributes' => ['array', 'link_identifier'=>'resource', 'result_entry_identifier'=>'resource'],
'ldap_get_dn' => ['string', 'link_identifier'=>'resource', 'result_entry_identifier'=>'resource'],
'ldap_get_entries' => ['array', 'link_identifier'=>'resource', 'result_identifier'=>'resource'],
'ldap_get_option' => ['bool', 'link_identifier'=>'resource', 'option'=>'int', '&w_retval'=>'mixed'],
'ldap_get_values' => ['array', 'link_identifier'=>'resource', 'result_entry_identifier'=>'resource', 'attribute'=>'string'],
'ldap_get_values_len' => ['array', 'link_identifier'=>'resource', 'result_entry_identifier'=>'resource', 'attribute'=>'string'],
'ldap_list' => ['resource|false', 'link'=>'resource|array', 'base_dn'=>'string', 'filter'=>'string', 'attrs='=>'array', 'attrsonly='=>'int', 'sizelimit='=>'int', 'timelimit='=>'int', 'deref='=>'int'],
'ldap_mod_add' => ['bool', 'link_identifier'=>'resource', 'dn'=>'string', 'entry'=>'array'],
'ldap_mod_del' => ['bool', 'link_identifier'=>'resource', 'dn'=>'string', 'entry'=>'array'],
'ldap_mod_replace' => ['bool', 'link_identifier'=>'resource', 'dn'=>'string', 'entry'=>'array'],
'ldap_modify' => ['bool', 'link_identifier'=>'resource', 'dn'=>'string', 'entry'=>'array'],
'ldap_modify_batch' => ['bool', 'link_identifier'=>'resource', 'dn'=>'string', 'modifs'=>'array'],
'ldap_next_attribute' => ['string', 'link_identifier'=>'resource', 'result_entry_identifier'=>'resource'],
'ldap_next_entry' => ['resource|false', 'link_identifier'=>'resource', 'result_entry_identifier'=>'resource'],
'ldap_next_reference' => ['resource|false', 'link_identifier'=>'resource', 'reference_entry_identifier'=>'resource'],
'ldap_parse_exop' => ['bool', 'link'=>'resource', 'result'=>'resource', 'retdata='=>'string', 'retoid='=>'string'],
'ldap_parse_reference' => ['bool', 'link_identifier'=>'resource', 'reference_entry_identifier'=>'resource', 'referrals'=>'array'],
'ldap_parse_result' => ['bool', 'link_identifier'=>'resource', 'result'=>'resource', 'errcode'=>'int', 'matcheddn='=>'string', 'errmsg='=>'string', 'referrals='=>'array'],
'ldap_read' => ['resource|false', 'link'=>'resource|array', 'base_dn'=>'string', 'filter'=>'string', 'attrs='=>'array', 'attrsonly='=>'int', 'sizelimit='=>'int', 'timelimit='=>'int', 'deref='=>'int'],
'ldap_rename' => ['bool', 'link_identifier'=>'resource', 'dn'=>'string', 'newrdn'=>'string', 'newparent'=>'string', 'deleteoldrdn'=>'bool'],
'ldap_sasl_bind' => ['bool', 'link_identifier'=>'resource', 'binddn='=>'string', 'password='=>'string', 'sasl_mech='=>'string', 'sasl_realm='=>'string', 'sasl_authc_id='=>'string', 'sasl_authz_id='=>'string', 'props='=>'string'],
'ldap_search' => ['resource|false', 'link_identifier'=>'resource|array', 'base_dn'=>'string', 'filter'=>'string', 'attrs='=>'array', 'attrsonly='=>'int', 'sizelimit='=>'int', 'timelimit='=>'int', 'deref='=>'int'],
'ldap_set_option' => ['bool', 'link_identifier'=>'resource', 'option'=>'int', 'newval'=>'mixed'],
'ldap_set_rebind_proc' => ['bool', 'link_identifier'=>'resource', 'callback'=>'string'],
'ldap_sort' => ['bool', 'link_identifier'=>'resource', 'result_identifier'=>'resource', 'sortfilter'=>'string'],
'ldap_start_tls' => ['bool', 'link_identifier'=>'resource'],
'ldap_t61_to_8859' => ['string', 'value'=>'string'],
'ldap_unbind' => ['bool', 'link_identifier'=>'resource'],
'leak' => ['', 'num_bytes'=>'int'],
'leak_variable' => ['', 'variable'=>'', 'leak_data'=>'bool'],
'legendObj::convertToString' => ['string'],
'legendObj::free' => ['void'],
'legendObj::set' => ['int', 'property_name'=>'string', 'new_value'=>''],
'legendObj::updateFromString' => ['int', 'snippet'=>'string'],
'LengthException::__clone' => ['void'],
'LengthException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?LengthException'],
'LengthException::__toString' => ['string'],
'LengthException::getCode' => ['int'],
'LengthException::getFile' => ['string'],
'LengthException::getLine' => ['int'],
'LengthException::getMessage' => ['string'],
'LengthException::getPrevious' => ['Throwable|LengthException|null'],
'LengthException::getTrace' => ['array'],
'LengthException::getTraceAsString' => ['string'],
'levenshtein' => ['int', 'str1'=>'string', 'str2'=>'string'],
'levenshtein\'1' => ['int', 'str1'=>'string', 'str2'=>'string', 'cost_ins'=>'int', 'cost_rep'=>'int', 'cost_del'=>'int'],
'libxml_clear_errors' => ['void'],
'libxml_disable_entity_loader' => ['bool', 'disable='=>'bool'],
'libxml_get_errors' => ['array'],
'libxml_get_last_error' => ['libXMLError|false'],
'libxml_set_external_entity_loader' => ['bool', 'resolver_function'=>'callable'],
'libxml_set_streams_context' => ['void', 'streams_context'=>'resource'],
'libxml_use_internal_errors' => ['bool', 'use_errors='=>'bool'],
'LimitIterator::__construct' => ['void', 'iterator'=>'Iterator', 'offset='=>'int', 'count='=>'int'],
'LimitIterator::current' => ['mixed'],
'LimitIterator::getInnerIterator' => ['Iterator'],
'LimitIterator::getPosition' => ['int'],
'LimitIterator::key' => ['mixed'],
'LimitIterator::next' => ['void'],
'LimitIterator::rewind' => ['void'],
'LimitIterator::seek' => ['int', 'position'=>'int'],
'LimitIterator::valid' => ['bool'],
'lineObj::__construct' => ['void'],
'lineObj::add' => ['int', 'point'=>'pointObj'],
'lineObj::addXY' => ['int', 'x'=>'float', 'y'=>'float', 'm'=>'float'],
'lineObj::addXYZ' => ['int', 'x'=>'float', 'y'=>'float', 'z'=>'float', 'm'=>'float'],
'lineObj::ms_newLineObj' => ['lineObj'],
'lineObj::point' => ['pointObj', 'i'=>'int'],
'lineObj::project' => ['int', 'in'=>'projectionObj', 'out'=>'projectionObj'],
'link' => ['bool', 'target'=>'string', 'link'=>'string'],
'linkinfo' => ['int', 'filename'=>'string'],
'litespeed_request_headers' => ['array'],
'litespeed_response_headers' => ['array'],
'Locale::acceptFromHttp' => ['string|false', 'header'=>'string'],
'Locale::canonicalize' => ['string', 'locale'=>'string'],
'Locale::composeLocale' => ['string', 'subtags'=>'array'],
'Locale::filterMatches' => ['bool', 'langtag'=>'string', 'locale'=>'string', 'canonicalize='=>'bool'],
'Locale::getAllVariants' => ['array', 'locale'=>'string'],
'Locale::getDefault' => ['string'],
'Locale::getDisplayLanguage' => ['string', 'locale'=>'string', 'in_locale='=>'string'],
'Locale::getDisplayName' => ['string', 'locale'=>'string', 'in_locale='=>'string'],
'Locale::getDisplayRegion' => ['string', 'locale'=>'string', 'in_locale='=>'string'],
'Locale::getDisplayScript' => ['string', 'locale'=>'string', 'in_locale='=>'string'],
'Locale::getDisplayVariant' => ['string', 'locale'=>'string', 'in_locale='=>'string'],
'Locale::getKeywords' => ['array|false', 'locale'=>'string'],
'Locale::getPrimaryLanguage' => ['string', 'locale'=>'string'],
'Locale::getRegion' => ['string', 'locale'=>'string'],
'Locale::getScript' => ['string', 'locale'=>'string'],
'Locale::lookup' => ['string', 'langtag'=>'array', 'locale'=>'string', 'canonicalize='=>'bool', 'default='=>'string'],
'Locale::parseLocale' => ['array', 'locale'=>'string'],
'Locale::setDefault' => ['bool', 'locale'=>'string'],
'locale_accept_from_http' => ['string|false', 'header'=>'string'],
'locale_canonicalize' => ['', 'arg1'=>''],
'locale_compose' => ['string|false', 'subtags'=>'array'],
'locale_filter_matches' => ['bool', 'langtag'=>'string', 'locale'=>'string', 'canonicalize='=>'bool'],
'locale_get_all_variants' => ['array', 'locale'=>'string'],
'locale_get_default' => ['string'],
'locale_get_display_language' => ['string', 'locale'=>'string', 'in_locale='=>'string'],
'locale_get_display_name' => ['string', 'locale'=>'string', 'in_locale='=>'string'],
'locale_get_display_region' => ['string', 'locale'=>'string', 'in_locale='=>'string'],
'locale_get_display_script' => ['string', 'locale'=>'string', 'in_locale='=>'string'],
'locale_get_display_variant' => ['string', 'locale'=>'string', 'in_locale='=>'string'],
'locale_get_keywords' => ['array|false', 'locale'=>'string'],
'locale_get_primary_language' => ['string', 'locale'=>'string'],
'locale_get_region' => ['string', 'locale'=>'string'],
'locale_get_script' => ['string', 'locale'=>'string'],
'locale_lookup' => ['string', 'langtag'=>'array', 'locale'=>'string', 'canonicalize='=>'bool', 'default='=>'string'],
'locale_parse' => ['array', 'locale'=>'string'],
'locale_set_default' => ['bool', 'locale'=>'string'],
'localeconv' => ['array'],
'localtime' => ['array', 'timestamp='=>'int', 'associative_array='=>'bool'],
'log' => ['float', 'number'=>'float', 'base='=>'float'],
'log10' => ['float', 'number'=>'float'],
'log1p' => ['float', 'number'=>'float'],
'LogicException::__clone' => ['void'],
'LogicException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?LogicException'],
'LogicException::__toString' => ['string'],
'LogicException::getCode' => ['int'],
'LogicException::getFile' => ['string'],
'LogicException::getLine' => ['int'],
'LogicException::getMessage' => ['string'],
'LogicException::getPrevious' => ['Throwable|LogicException|null'],
'LogicException::getTrace' => ['array'],
'LogicException::getTraceAsString' => ['string'],
'long2ip' => ['string', 'proper_address'=>'int'],
'lstat' => ['array|false', 'filename'=>'string'],
'ltrim' => ['string', 'str'=>'string', 'character_mask='=>'string'],
'Lua::__call' => ['mixed', 'lua_func'=>'callable', 'args='=>'array', 'use_self='=>'int'],
'Lua::__construct' => ['void', 'lua_script_file'=>'string'],
'Lua::assign' => ['mixed', 'name'=>'string', 'value'=>'string'],
'Lua::call' => ['mixed', 'lua_func'=>'callable', 'args='=>'array', 'use_self='=>'int'],
'Lua::eval' => ['mixed', 'statements'=>'string'],
'Lua::getVersion' => ['string'],
'Lua::include' => ['mixed', 'file'=>'string'],
'Lua::registerCallback' => ['mixed', 'name'=>'string', 'function'=>'callable'],
'LuaClosure::__invoke' => ['void', 'arg'=>'mixed', '...args='=>'mixed'],
'lzf_compress' => ['string', 'data'=>'string'],
'lzf_decompress' => ['string', 'data'=>'string'],
'lzf_optimized_for' => ['int'],
'm_checkstatus' => ['int', 'conn'=>'resource', 'identifier'=>'int'],
'm_completeauthorizations' => ['int', 'conn'=>'resource', 'array'=>'int'],
'm_connect' => ['int', 'conn'=>'resource'],
'm_connectionerror' => ['string', 'conn'=>'resource'],
'm_deletetrans' => ['bool', 'conn'=>'resource', 'identifier'=>'int'],
'm_destroyconn' => ['bool', 'conn'=>'resource'],
'm_destroyengine' => ['void'],
'm_getcell' => ['string', 'conn'=>'resource', 'identifier'=>'int', 'column'=>'string', 'row'=>'int'],
'm_getcellbynum' => ['string', 'conn'=>'resource', 'identifier'=>'int', 'column'=>'int', 'row'=>'int'],
'm_getcommadelimited' => ['string', 'conn'=>'resource', 'identifier'=>'int'],
'm_getheader' => ['string', 'conn'=>'resource', 'identifier'=>'int', 'column_num'=>'int'],
'm_initconn' => ['resource'],
'm_initengine' => ['int', 'location'=>'string'],
'm_iscommadelimited' => ['int', 'conn'=>'resource', 'identifier'=>'int'],
'm_maxconntimeout' => ['bool', 'conn'=>'resource', 'secs'=>'int'],
'm_monitor' => ['int', 'conn'=>'resource'],
'm_numcolumns' => ['int', 'conn'=>'resource', 'identifier'=>'int'],
'm_numrows' => ['int', 'conn'=>'resource', 'identifier'=>'int'],
'm_parsecommadelimited' => ['int', 'conn'=>'resource', 'identifier'=>'int'],
'm_responsekeys' => ['array', 'conn'=>'resource', 'identifier'=>'int'],
'm_responseparam' => ['string', 'conn'=>'resource', 'identifier'=>'int', 'key'=>'string'],
'm_returnstatus' => ['int', 'conn'=>'resource', 'identifier'=>'int'],
'm_setblocking' => ['int', 'conn'=>'resource', 'tf'=>'int'],
'm_setdropfile' => ['int', 'conn'=>'resource', 'directory'=>'string'],
'm_setip' => ['int', 'conn'=>'resource', 'host'=>'string', 'port'=>'int'],
'm_setssl' => ['int', 'conn'=>'resource', 'host'=>'string', 'port'=>'int'],
'm_setssl_cafile' => ['int', 'conn'=>'resource', 'cafile'=>'string'],
'm_setssl_files' => ['int', 'conn'=>'resource', 'sslkeyfile'=>'string', 'sslcertfile'=>'string'],
'm_settimeout' => ['int', 'conn'=>'resource', 'seconds'=>'int'],
'm_sslcert_gen_hash' => ['string', 'filename'=>'string'],
'm_transactionssent' => ['int', 'conn'=>'resource'],
'm_transinqueue' => ['int', 'conn'=>'resource'],
'm_transkeyval' => ['int', 'conn'=>'resource', 'identifier'=>'int', 'key'=>'string', 'value'=>'string'],
'm_transnew' => ['int', 'conn'=>'resource'],
'm_transsend' => ['int', 'conn'=>'resource', 'identifier'=>'int'],
'm_uwait' => ['int', 'microsecs'=>'int'],
'm_validateidentifier' => ['int', 'conn'=>'resource', 'tf'=>'int'],
'm_verifyconnection' => ['bool', 'conn'=>'resource', 'tf'=>'int'],
'm_verifysslcert' => ['bool', 'conn'=>'resource', 'tf'=>'int'],
'magic_quotes_runtime' => ['', 'new_setting'=>''],
'mail' => ['bool', 'to'=>'string', 'subject'=>'string', 'message'=>'string', 'additional_headers='=>'string', 'additional_parameters='=>'string'],
'mailparse_determine_best_xfer_encoding' => ['string', 'fp'=>'resource'],
'mailparse_msg_create' => ['resource'],
'mailparse_msg_extract_part' => ['void', 'mimemail'=>'resource', 'msgbody'=>'string', 'callbackfunc='=>'callable'],
'mailparse_msg_extract_part_file' => ['string', 'mimemail'=>'resource', 'filename'=>'mixed', 'callbackfunc='=>'callable'],
'mailparse_msg_extract_whole_part_file' => ['string', 'mimemail'=>'resource', 'filename'=>'string', 'callbackfunc='=>'callable'],
'mailparse_msg_free' => ['bool', 'mimemail'=>'resource'],
'mailparse_msg_get_part' => ['resource', 'mimemail'=>'resource', 'mimesection'=>'string'],
'mailparse_msg_get_part_data' => ['array', 'mimemail'=>'resource'],
'mailparse_msg_get_structure' => ['array', 'mimemail'=>'resource'],
'mailparse_msg_parse' => ['bool', 'mimemail'=>'resource', 'data'=>'string'],
'mailparse_msg_parse_file' => ['resource', 'filename'=>'string'],
'mailparse_rfc822_parse_addresses' => ['array', 'addresses'=>'string'],
'mailparse_stream_encode' => ['bool', 'sourcefp'=>'resource', 'destfp'=>'resource', 'encoding'=>'string'],
'mailparse_uudecode_all' => ['array', 'fp'=>'resource'],
'mapObj::__construct' => ['void', 'map_file_name'=>'string', 'new_map_path'=>'string'],
'mapObj::appendOutputFormat' => ['int', 'outputFormat'=>'outputformatObj'],
'mapObj::applyconfigoptions' => ['int'],
'mapObj::applySLD' => ['int', 'sldxml'=>'string'],
'mapObj::applySLDURL' => ['int', 'sldurl'=>'string'],
'mapObj::convertToString' => ['string'],
'mapObj::draw' => ['imageObj'],
'mapObj::drawLabelCache' => ['int', 'image'=>'imageObj'],
'mapObj::drawLegend' => ['imageObj'],
'mapObj::drawQuery' => ['imageObj'],
'mapObj::drawReferenceMap' => ['imageObj'],
'mapObj::drawScaleBar' => ['imageObj'],
'mapObj::embedLegend' => ['int', 'image'=>'imageObj'],
'mapObj::embedScalebar' => ['int', 'image'=>'imageObj'],
'mapObj::free' => ['void'],
'mapObj::generateSLD' => ['string'],
'mapObj::getAllGroupNames' => ['array'],
'mapObj::getAllLayerNames' => ['array'],
'mapObj::getColorbyIndex' => ['colorObj', 'iCloIndex'=>'int'],
'mapObj::getConfigOption' => ['string', 'key'=>'string'],
'mapObj::getLabel' => ['labelcacheMemberObj', 'index'=>'int'],
'mapObj::getLayer' => ['layerObj', 'index'=>'int'],
'mapObj::getLayerByName' => ['layerObj', 'layer_name'=>'string'],
'mapObj::getLayersDrawingOrder' => ['array'],
'mapObj::getLayersIndexByGroup' => ['array', 'groupname'=>'string'],
'mapObj::getMetaData' => ['int', 'name'=>'string'],
'mapObj::getNumSymbols' => ['int'],
'mapObj::getOutputFormat' => ['outputformatObj', 'index'=>'int'],
'mapObj::getProjection' => ['string'],
'mapObj::getSymbolByName' => ['int', 'symbol_name'=>'string'],
'mapObj::getSymbolObjectById' => ['symbolObj', 'symbolid'=>'int'],
'mapObj::loadMapContext' => ['int', 'filename'=>'string', 'unique_layer_name'=>'bool'],
'mapObj::loadOWSParameters' => ['int', 'request'=>'OwsrequestObj', 'version'=>'string'],
'mapObj::moveLayerDown' => ['int', 'layerindex'=>'int'],
'mapObj::moveLayerUp' => ['int', 'layerindex'=>'int'],
'mapObj::ms_newMapObjFromString' => ['MapObj', 'map_file_string'=>'string', 'new_map_path'=>'string'],
'mapObj::offsetExtent' => ['int', 'x'=>'float', 'y'=>'float'],
'mapObj::owsDispatch' => ['int', 'request'=>'OwsrequestObj'],
'mapObj::prepareImage' => ['imageObj'],
'mapObj::prepareQuery' => ['void'],
'mapObj::processLegendTemplate' => ['string', 'params'=>'array'],
'mapObj::processQueryTemplate' => ['string', 'params'=>'array', 'generateimages'=>'bool'],
'mapObj::processTemplate' => ['string', 'params'=>'array', 'generateimages'=>'bool'],
'mapObj::queryByFeatures' => ['int', 'slayer'=>'int'],
'mapObj::queryByIndex' => ['int', 'layerindex'=>'', 'tileindex'=>'', 'shapeindex'=>'', 'addtoquery'=>''],
'mapObj::queryByPoint' => ['int', 'point'=>'pointObj', 'mode'=>'int', 'buffer'=>'float'],
'mapObj::queryByRect' => ['int', 'rect'=>'rectObj'],
'mapObj::queryByShape' => ['int', 'shape'=>'shapeObj'],
'mapObj::removeLayer' => ['layerObj', 'nIndex'=>'int'],
'mapObj::removeMetaData' => ['int', 'name'=>'string'],
'mapObj::removeOutputFormat' => ['int', 'name'=>'string'],
'mapObj::save' => ['int', 'filename'=>'string'],
'mapObj::saveMapContext' => ['int', 'filename'=>'string'],
'mapObj::saveQuery' => ['int', 'filename'=>'string', 'results'=>'int'],
'mapObj::scaleExtent' => ['int', 'zoomfactor'=>'float', 'minscaledenom'=>'float', 'maxscaledenom'=>'float'],
'mapObj::selectOutputFormat' => ['int', 'type'=>'string'],
'mapObj::set' => ['int', 'property_name'=>'string', 'new_value'=>''],
'mapObj::setCenter' => ['int', 'center'=>'pointObj'],
'mapObj::setConfigOption' => ['int', 'key'=>'string', 'value'=>'string'],
'mapObj::setExtent' => ['void', 'minx'=>'float', 'miny'=>'float', 'maxx'=>'float', 'maxy'=>'float'],
'mapObj::setFontSet' => ['int', 'fileName'=>'string'],
'mapObj::setMetaData' => ['int', 'name'=>'string', 'value'=>'string'],
'mapObj::setProjection' => ['int', 'proj_params'=>'string', 'bSetUnitsAndExtents'=>'bool'],
'mapObj::setRotation' => ['int', 'rotation_angle'=>'float'],
'mapObj::setSize' => ['int', 'width'=>'int', 'height'=>'int'],
'mapObj::setSymbolSet' => ['int', 'fileName'=>'string'],
'mapObj::setWKTProjection' => ['int', 'proj_params'=>'string', 'bSetUnitsAndExtents'=>'bool'],
'mapObj::zoomPoint' => ['int', 'nZoomFactor'=>'int', 'oPixelPos'=>'pointObj', 'nImageWidth'=>'int', 'nImageHeight'=>'int', 'oGeorefExt'=>'rectObj'],
'mapObj::zoomRectangle' => ['int', 'oPixelExt'=>'rectObj', 'nImageWidth'=>'int', 'nImageHeight'=>'int', 'oGeorefExt'=>'rectObj'],
'mapObj::zoomScale' => ['int', 'nScaleDenom'=>'float', 'oPixelPos'=>'pointObj', 'nImageWidth'=>'int', 'nImageHeight'=>'int', 'oGeorefExt'=>'rectObj', 'oMaxGeorefExt'=>'rectObj'],
'max' => ['', '...arg1'=>'array'],
'max\'1' => ['', 'arg1'=>'', 'arg2'=>'', '...args='=>''],
'maxdb::__construct' => ['void', 'host='=>'string', 'username='=>'string', 'passwd='=>'string', 'dbname='=>'string', 'port='=>'int', 'socket='=>'string'],
'maxdb::affected_rows' => ['int', 'link'=>''],
'maxdb::auto_commit' => ['bool', 'link'=>'', 'mode'=>'bool'],
'maxdb::change_user' => ['bool', 'link'=>'', 'user'=>'string', 'password'=>'string', 'database'=>'string'],
'maxdb::character_set_name' => ['string', 'link'=>''],
'maxdb::close' => ['bool', 'link'=>''],
'maxdb::commit' => ['bool', 'link'=>''],
'maxdb::disable_reads_from_master' => ['', 'link'=>''],
'maxdb::errno' => ['int', 'link'=>''],
'maxdb::error' => ['string', 'link'=>''],
'maxdb::field_count' => ['int', 'link'=>''],
'maxdb::get_host_info' => ['string', 'link'=>''],
'maxdb::info' => ['string', 'link'=>''],
'maxdb::insert_id' => ['', 'link'=>''],
'maxdb::kill' => ['bool', 'link'=>'', 'processid'=>'int'],
'maxdb::more_results' => ['bool', 'link'=>''],
'maxdb::multi_query' => ['bool', 'link'=>'', 'query'=>'string'],
'maxdb::next_result' => ['bool', 'link'=>''],
'maxdb::num_rows' => ['int', 'result'=>''],
'maxdb::options' => ['bool', 'link'=>'', 'option'=>'int', 'value'=>''],
'maxdb::ping' => ['bool', 'link'=>''],
'maxdb::prepare' => ['maxdb_stmt', 'link'=>'', 'query'=>'string'],
'maxdb::protocol_version' => ['string', 'link'=>''],
'maxdb::query' => ['', 'link'=>'', 'query'=>'string', 'resultmode='=>'int'],
'maxdb::real_connect' => ['bool', 'link'=>'', 'hostname='=>'string', 'username='=>'string', 'passwd='=>'string', 'dbname='=>'string', 'port='=>'int', 'socket='=>'string'],
'maxdb::real_escape_string' => ['string', 'link'=>'', 'escapestr'=>'string'],
'maxdb::real_query' => ['bool', 'link'=>'', 'query'=>'string'],
'maxdb::rollback' => ['bool', 'link'=>''],
'maxdb::rpl_query_type' => ['int', 'link'=>''],
'maxdb::select_db' => ['bool', 'link'=>'', 'dbname'=>'string'],
'maxdb::send_query' => ['bool', 'link'=>'', 'query'=>'string'],
'maxdb::server_info' => ['string', 'link'=>''],
'maxdb::server_version' => ['int', 'link'=>''],
'maxdb::sqlstate' => ['string', 'link'=>''],
'maxdb::ssl_set' => ['bool', 'link'=>'', 'key'=>'string', 'cert'=>'string', 'ca'=>'string', 'capath'=>'string', 'cipher'=>'string'],
'maxdb::stat' => ['string', 'link'=>''],
'maxdb::stmt_init' => ['object', 'link'=>''],
'maxdb::store_result' => ['bool', 'link'=>''],
'maxdb::thread_id' => ['int', 'link'=>''],
'maxdb::use_result' => ['resource', 'link'=>''],
'maxdb::warning_count' => ['int', 'link'=>''],
'maxdb_affected_rows' => ['int', 'link'=>'resource'],
'maxdb_autocommit' => ['bool', 'link'=>'', 'mode'=>'bool'],
'maxdb_change_user' => ['bool', 'link'=>'', 'user'=>'string', 'password'=>'string', 'database'=>'string'],
'maxdb_character_set_name' => ['string', 'link'=>''],
'maxdb_close' => ['bool', 'link'=>''],
'maxdb_commit' => ['bool', 'link'=>''],
'maxdb_connect' => ['resource', 'host='=>'string', 'username='=>'string', 'passwd='=>'string', 'dbname='=>'string', 'port='=>'int', 'socket='=>'string'],
'maxdb_connect_errno' => ['int'],
'maxdb_connect_error' => ['string'],
'maxdb_data_seek' => ['bool', 'result'=>'', 'offset'=>'int'],
'maxdb_debug' => ['void', 'debug'=>'string'],
'maxdb_disable_reads_from_master' => ['', 'link'=>''],
'maxdb_disable_rpl_parse' => ['bool', 'link'=>'resource'],
'maxdb_dump_debug_info' => ['bool', 'link'=>'resource'],
'maxdb_embedded_connect' => ['resource', 'dbname='=>'string'],
'maxdb_enable_reads_from_master' => ['bool', 'link'=>'resource'],
'maxdb_enable_rpl_parse' => ['bool', 'link'=>'resource'],
'maxdb_errno' => ['int', 'link'=>'resource'],
'maxdb_error' => ['string', 'link'=>'resource'],
'maxdb_fetch_array' => ['', 'result'=>'', 'resulttype='=>'int'],
'maxdb_fetch_assoc' => ['array', 'result'=>''],
'maxdb_fetch_field' => ['', 'result'=>''],
'maxdb_fetch_field_direct' => ['', 'result'=>'', 'fieldnr'=>'int'],
'maxdb_fetch_fields' => ['', 'result'=>''],
'maxdb_fetch_lengths' => ['array', 'result'=>'resource'],
'maxdb_fetch_object' => ['object', 'result'=>'object'],
'maxdb_fetch_row' => ['', 'result'=>''],
'maxdb_field_count' => ['int', 'link'=>''],
'maxdb_field_seek' => ['bool', 'result'=>'', 'fieldnr'=>'int'],
'maxdb_field_tell' => ['int', 'result'=>'resource'],
'maxdb_free_result' => ['', 'result'=>''],
'maxdb_get_client_info' => ['string'],
'maxdb_get_client_version' => ['int'],
'maxdb_get_host_info' => ['string', 'link'=>'resource'],
'maxdb_get_proto_info' => ['string', 'link'=>'resource'],
'maxdb_get_server_info' => ['string', 'link'=>'resource'],
'maxdb_get_server_version' => ['int', 'link'=>'resource'],
'maxdb_info' => ['string', 'link'=>'resource'],
'maxdb_init' => ['resource'],
'maxdb_insert_id' => ['mixed', 'link'=>'resource'],
'maxdb_kill' => ['bool', 'link'=>'', 'processid'=>'int'],
'maxdb_master_query' => ['bool', 'link'=>'resource', 'query'=>'string'],
'maxdb_more_results' => ['bool', 'link'=>'resource'],
'maxdb_multi_query' => ['bool', 'link'=>'', 'query'=>'string'],
'maxdb_next_result' => ['bool', 'link'=>'resource'],
'maxdb_num_fields' => ['int', 'result'=>'resource'],
'maxdb_num_rows' => ['int', 'result'=>'resource'],
'maxdb_options' => ['bool', 'link'=>'', 'option'=>'int', 'value'=>''],
'maxdb_ping' => ['bool', 'link'=>''],
'maxdb_prepare' => ['maxdb_stmt', 'link'=>'', 'query'=>'string'],
'maxdb_query' => ['', 'link'=>'', 'query'=>'string', 'resultmode='=>'int'],
'maxdb_real_connect' => ['bool', 'link'=>'', 'hostname='=>'string', 'username='=>'string', 'passwd='=>'string', 'dbname='=>'string', 'port='=>'int', 'socket='=>'string'],
'maxdb_real_escape_string' => ['string', 'link'=>'', 'escapestr'=>'string'],
'maxdb_real_query' => ['bool', 'link'=>'', 'query'=>'string'],
'maxdb_report' => ['bool', 'flags'=>'int'],
'maxdb_result::current_field' => ['int', 'result'=>''],
'maxdb_result::data_seek' => ['bool', 'result'=>'', 'offset'=>'int'],
'maxdb_result::fetch_array' => ['', 'result'=>'', 'resulttype='=>'int'],
'maxdb_result::fetch_assoc' => ['array', 'result'=>''],
'maxdb_result::fetch_field' => ['', 'result'=>''],
'maxdb_result::fetch_field_direct' => ['', 'result'=>'', 'fieldnr'=>'int'],
'maxdb_result::fetch_fields' => ['', 'result'=>''],
'maxdb_result::fetch_object' => ['object', 'result'=>'object'],
'maxdb_result::fetch_row' => ['', 'result'=>''],
'maxdb_result::field_count' => ['int', 'result'=>''],
'maxdb_result::field_seek' => ['bool', 'result'=>'', 'fieldnr'=>'int'],
'maxdb_result::free' => ['', 'result'=>''],
'maxdb_result::lengths' => ['array', 'result'=>''],
'maxdb_rollback' => ['bool', 'link'=>''],
'maxdb_rpl_parse_enabled' => ['int', 'link'=>'resource'],
'maxdb_rpl_probe' => ['bool', 'link'=>'resource'],
'maxdb_rpl_query_type' => ['int', 'link'=>''],
'maxdb_select_db' => ['bool', 'link'=>'resource', 'dbname'=>'string'],
'maxdb_send_query' => ['bool', 'link'=>'', 'query'=>'string'],
'maxdb_server_end' => ['void'],
'maxdb_server_init' => ['bool', 'server='=>'array', 'groups='=>'array'],
'maxdb_sqlstate' => ['string', 'link'=>'resource'],
'maxdb_ssl_set' => ['bool', 'link'=>'', 'key'=>'string', 'cert'=>'string', 'ca'=>'string', 'capath'=>'string', 'cipher'=>'string'],
'maxdb_stat' => ['string', 'link'=>''],
'maxdb_stmt::affected_rows' => ['int', 'stmt'=>''],
'maxdb_stmt::bind_param' => ['bool', 'stmt'=>'', 'types'=>'string', '&...rw_var'=>''],
'maxdb_stmt::bind_param\'1' => ['bool', 'stmt'=>'', 'types'=>'string', '&rw_var'=>'array'],
'maxdb_stmt::bind_result' => ['bool', 'stmt'=>'', '&rw_var1'=>'', '&...rw_vars='=>''],
'maxdb_stmt::close' => ['bool', 'stmt'=>''],
'maxdb_stmt::close_long_data' => ['bool', 'stmt'=>'', 'param_nr'=>'int'],
'maxdb_stmt::data_seek' => ['bool', 'statement'=>'', 'offset'=>'int'],
'maxdb_stmt::errno' => ['int', 'stmt'=>''],
'maxdb_stmt::error' => ['string', 'stmt'=>''],
'maxdb_stmt::execute' => ['bool', 'stmt'=>''],
'maxdb_stmt::fetch' => ['bool', 'stmt'=>''],
'maxdb_stmt::free_result' => ['', 'stmt'=>''],
'maxdb_stmt::num_rows' => ['int', 'stmt'=>''],
'maxdb_stmt::param_count' => ['int', 'stmt'=>''],
'maxdb_stmt::prepare' => ['', 'stmt'=>'', 'query'=>'string'],
'maxdb_stmt::reset' => ['bool', 'stmt'=>''],
'maxdb_stmt::result_metadata' => ['resource', 'stmt'=>''],
'maxdb_stmt::send_long_data' => ['bool', 'stmt'=>'', 'param_nr'=>'int', 'data'=>'string'],
'maxdb_stmt::stmt_send_long_data' => ['bool', 'param_nr'=>'int', 'data'=>'string'],
'maxdb_stmt::store_result' => ['bool'],
'maxdb_stmt_affected_rows' => ['int', 'stmt'=>'resource'],
'maxdb_stmt_bind_param' => ['bool', 'stmt'=>'', 'types'=>'string', 'var1'=>'', '...args='=>'', 'var='=>'array'],
'maxdb_stmt_bind_result' => ['bool', 'stmt'=>'', '&rw_var1'=>'', '&...rw_vars='=>''],
'maxdb_stmt_close' => ['bool', 'stmt'=>''],
'maxdb_stmt_close_long_data' => ['bool', 'stmt'=>'', 'param_nr'=>'int'],
'maxdb_stmt_data_seek' => ['bool', 'statement'=>'', 'offset'=>'int'],
'maxdb_stmt_errno' => ['int', 'stmt'=>'resource'],
'maxdb_stmt_error' => ['string', 'stmt'=>'resource'],
'maxdb_stmt_execute' => ['bool', 'stmt'=>''],
'maxdb_stmt_fetch' => ['bool', 'stmt'=>''],
'maxdb_stmt_free_result' => ['', 'stmt'=>''],
'maxdb_stmt_init' => ['object', 'link'=>''],
'maxdb_stmt_num_rows' => ['int', 'stmt'=>'resource'],
'maxdb_stmt_param_count' => ['int', 'stmt'=>'resource'],
'maxdb_stmt_prepare' => ['', 'stmt'=>'', 'query'=>'string'],
'maxdb_stmt_reset' => ['bool', 'stmt'=>''],
'maxdb_stmt_result_metadata' => ['resource', 'stmt'=>''],
'maxdb_stmt_send_long_data' => ['bool', 'stmt'=>'', 'param_nr'=>'int', 'data'=>'string'],
'maxdb_stmt_sqlstate' => ['string', 'stmt'=>'resource'],
'maxdb_stmt_store_result' => ['bool', 'stmt'=>''],
'maxdb_store_result' => ['bool', 'link'=>''],
'maxdb_thread_id' => ['int', 'link'=>'resource'],
'maxdb_thread_safe' => ['bool'],
'maxdb_use_result' => ['resource', 'link'=>''],
'maxdb_warning_count' => ['int', 'link'=>'resource'],
'mb_check_encoding' => ['bool', 'var='=>'string', 'encoding='=>'string'],
'mb_chr' => ['string', 'cp'=>'int', 'encoding='=>'string'],
'mb_convert_case' => ['string', 'sourcestring'=>'string', 'mode'=>'int', 'encoding='=>'string'],
'mb_convert_encoding' => ['string', 'str'=>'string', 'to_encoding'=>'string', 'from_encoding='=>'mixed'],
'mb_convert_kana' => ['string', 'str'=>'string', 'option='=>'string', 'encoding='=>'string'],
'mb_convert_variables' => ['string', 'to_encoding'=>'string', 'from_encoding'=>'array|string', '&rw_vars'=>'string|array|object', '&...rw_vars='=>'string|array|object'],
'mb_decode_mimeheader' => ['string', 'string'=>'string'],
'mb_decode_numericentity' => ['string', 'string'=>'string', 'convmap'=>'array', 'encoding'=>'string'],
'mb_detect_encoding' => ['string|false', 'str'=>'string', 'encoding_list='=>'mixed', 'strict='=>'bool'],
'mb_detect_order' => ['bool|array', 'encoding_list='=>'mixed'],
'mb_encode_mimeheader' => ['string', 'str'=>'string', 'charset='=>'string', 'transfer_encoding='=>'string', 'linefeed='=>'string', 'indent='=>'int'],
'mb_encode_numericentity' => ['string', 'string'=>'string', 'convmap'=>'array', 'encoding'=>'string', 'is_hex='=>'bool'],
'mb_encoding_aliases' => ['array|false', 'encoding'=>'string'],
'mb_ereg' => ['int', 'pattern'=>'string', 'string'=>'string', '&w_registers='=>'array'],
'mb_ereg_match' => ['bool', 'pattern'=>'string', 'string'=>'string', 'option='=>'string'],
'mb_ereg_replace' => ['string', 'pattern'=>'string', 'replacement'=>'string', 'string'=>'string', 'option='=>'string'],
'mb_ereg_replace_callback' => ['string', 'pattern'=>'string', 'callback'=>'string', 'string'=>'string', 'option='=>'string'],
'mb_ereg_search' => ['bool', 'pattern='=>'string', 'option='=>'string'],
'mb_ereg_search_getpos' => ['int'],
'mb_ereg_search_getregs' => ['array|false'],
'mb_ereg_search_init' => ['bool', 'string'=>'string', 'pattern='=>'string', 'option='=>'string'],
'mb_ereg_search_pos' => ['array', 'pattern='=>'string', 'option='=>'string'],
'mb_ereg_search_regs' => ['array|false', 'pattern='=>'string', 'option='=>'string'],
'mb_ereg_search_setpos' => ['bool', 'position'=>'int'],
'mb_eregi' => ['int', 'pattern'=>'string', 'string'=>'string', '&w_registers='=>'array'],
'mb_eregi_replace' => ['string', 'pattern'=>'string', 'replacement'=>'string', 'string'=>'string', 'option='=>'string'],
'mb_get_info' => ['mixed', 'type='=>'string'],
'mb_http_input' => ['mixed', 'type='=>'string'],
'mb_http_output' => ['string', 'encoding='=>'string'],
'mb_internal_encoding' => ['string', 'encoding='=>'string'],
'mb_language' => ['string', 'language='=>'string'],
'mb_list_encodings' => ['array'],
'mb_ord' => ['int', 'str'=>'string', 'enc='=>'string'],
'mb_output_handler' => ['string', 'contents'=>'string', 'status'=>'int'],
'mb_parse_str' => ['bool', 'encoded_string'=>'string', '&w_result='=>'array'],
'mb_preferred_mime_name' => ['string', 'encoding'=>'string'],
'mb_regex_encoding' => ['string', 'encoding='=>'string'],
'mb_regex_set_options' => ['string', 'options='=>'string'],
'mb_scrub' => ['string', 'str'=>'string', 'enc='=>'string'],
'mb_send_mail' => ['bool', 'to'=>'string', 'subject'=>'string', 'message'=>'string', 'additional_headers='=>'string', 'additional_parameter='=>'string'],
'mb_split' => ['array', 'pattern'=>'string', 'string'=>'string', 'limit='=>'int'],
'mb_strcut' => ['string', 'str'=>'string', 'start'=>'int', 'length='=>'int', 'encoding='=>'string'],
'mb_strimwidth' => ['string', 'str'=>'string', 'start'=>'int', 'width'=>'int', 'trimmarker='=>'string', 'encoding='=>'string'],
'mb_stripos' => ['int|false', 'haystack'=>'string', 'needle'=>'string', 'offset='=>'int', 'encoding='=>'string'],
'mb_stristr' => ['string|false', 'haystack'=>'string', 'needle'=>'string', 'part='=>'bool', 'encoding='=>'string'],
'mb_strlen' => ['int|false', 'str'=>'string', 'encoding='=>'string'],
'mb_strpos' => ['int|false', 'haystack'=>'string', 'needle'=>'string', 'offset='=>'int', 'encoding='=>'string'],
'mb_strrchr' => ['string|false', 'haystack'=>'string', 'needle'=>'string', 'part='=>'bool', 'encoding='=>'string'],
'mb_strrichr' => ['string|false', 'haystack'=>'string', 'needle'=>'string', 'part='=>'bool', 'encoding='=>'string'],
'mb_strripos' => ['int|false', 'haystack'=>'string', 'needle'=>'string', 'offset='=>'int', 'encoding='=>'string'],
'mb_strrpos' => ['int|false', 'haystack'=>'string', 'needle'=>'string', 'offset='=>'int', 'encoding='=>'string'],
'mb_strstr' => ['string|false', 'haystack'=>'string', 'needle'=>'string', 'part='=>'bool', 'encoding='=>'string'],
'mb_strtolower' => ['string', 'str'=>'string', 'encoding='=>'string'],
'mb_strtoupper' => ['string', 'str'=>'string', 'encoding='=>'string'],
'mb_strwidth' => ['int', 'str'=>'string', 'encoding='=>'string'],
'mb_substitute_character' => ['mixed', 'substchar='=>'mixed'],
'mb_substr' => ['string', 'str'=>'string', 'start'=>'int', 'length='=>'?int', 'encoding='=>'string'],
'mb_substr_count' => ['int', 'haystack'=>'string', 'needle'=>'string', 'encoding='=>'string'],
'mcrypt_cbc' => ['string', 'cipher'=>'string', 'key'=>'string', 'data'=>'string', 'mode'=>'int', 'iv='=>'string'],
'mcrypt_cfb' => ['string', 'cipher'=>'string', 'key'=>'string', 'data'=>'string', 'mode'=>'int', 'iv='=>'string'],
'mcrypt_create_iv' => ['string', 'size'=>'int', 'source='=>'int'],
'mcrypt_decrypt' => ['string', 'cipher'=>'string', 'key'=>'string', 'data'=>'string', 'mode'=>'string', 'iv='=>'string'],
'mcrypt_ecb' => ['string', 'cipher'=>'string', 'key'=>'string', 'data'=>'string', 'mode'=>'int', 'iv='=>'string'],
'mcrypt_enc_get_algorithms_name' => ['string', 'td'=>'resource'],
'mcrypt_enc_get_block_size' => ['int', 'td'=>'resource'],
'mcrypt_enc_get_iv_size' => ['int', 'td'=>'resource'],
'mcrypt_enc_get_key_size' => ['int', 'td'=>'resource'],
'mcrypt_enc_get_modes_name' => ['string', 'td'=>'resource'],
'mcrypt_enc_get_supported_key_sizes' => ['array', 'td'=>'resource'],
'mcrypt_enc_is_block_algorithm' => ['bool', 'td'=>'resource'],
'mcrypt_enc_is_block_algorithm_mode' => ['bool', 'td'=>'resource'],
'mcrypt_enc_is_block_mode' => ['bool', 'td'=>'resource'],
'mcrypt_enc_self_test' => ['int', 'td'=>'resource'],
'mcrypt_encrypt' => ['string', 'cipher'=>'string', 'key'=>'string', 'data'=>'string', 'mode'=>'string', 'iv='=>'string'],
'mcrypt_generic' => ['string', 'td'=>'resource', 'data'=>'string'],
'mcrypt_generic_deinit' => ['bool', 'td'=>'resource'],
'mcrypt_generic_end' => ['bool', 'td'=>'resource'],
'mcrypt_generic_init' => ['int', 'td'=>'resource', 'key'=>'string', 'iv'=>'string'],
'mcrypt_get_block_size' => ['int', 'cipher'=>'string', 'module'=>'string'],
'mcrypt_get_cipher_name' => ['string', 'cipher'=>'string'],
'mcrypt_get_iv_size' => ['int', 'cipher'=>'string', 'module'=>'string'],
'mcrypt_get_key_size' => ['int', 'cipher'=>'string', 'module'=>'string'],
'mcrypt_list_algorithms' => ['array', 'lib_dir='=>'string'],
'mcrypt_list_modes' => ['array', 'lib_dir='=>'string'],
'mcrypt_module_close' => ['bool', 'td'=>'resource'],
'mcrypt_module_get_algo_block_size' => ['int', 'algorithm'=>'string', 'lib_dir='=>'string'],
'mcrypt_module_get_algo_key_size' => ['int', 'algorithm'=>'string', 'lib_dir='=>'string'],
'mcrypt_module_get_supported_key_sizes' => ['array', 'algorithm'=>'string', 'lib_dir='=>'string'],
'mcrypt_module_is_block_algorithm' => ['bool', 'algorithm'=>'string', 'lib_dir='=>'string'],
'mcrypt_module_is_block_algorithm_mode' => ['bool', 'mode'=>'string', 'lib_dir='=>'string'],
'mcrypt_module_is_block_mode' => ['bool', 'mode'=>'string', 'lib_dir='=>'string'],
'mcrypt_module_open' => ['resource', 'cipher'=>'string', 'cipher_directory'=>'string', 'mode'=>'string', 'mode_directory'=>'string'],
'mcrypt_module_self_test' => ['bool', 'algorithm'=>'string', 'lib_dir='=>'string'],
'mcrypt_ofb' => ['string', 'cipher'=>'string', 'key'=>'string', 'data'=>'string', 'mode'=>'int', 'iv='=>'string'],
'md5' => ['string', 'str'=>'string', 'raw_output='=>'bool'],
'md5_file' => ['string|false', 'filename'=>'string', 'raw_output='=>'bool'],
'mdecrypt_generic' => ['string', 'td'=>'resource', 'data'=>'string'],
'Memcache::add' => ['bool', 'key'=>'string', 'var'=>'mixed', 'flag='=>'int', 'expire='=>'int'],
'Memcache::addServer' => ['bool', 'host'=>'string', 'port='=>'int', 'persistent='=>'bool', 'weight='=>'int', 'timeout='=>'int', 'retry_interval='=>'int', 'status='=>'bool', 'failure_callback='=>'callable', 'timeoutms='=>'int'],
'Memcache::close' => ['bool'],
'Memcache::connect' => ['bool', 'host'=>'string', 'port='=>'int', 'timeout='=>'int'],
'Memcache::decrement' => ['int', 'key'=>'string', 'value='=>'int'],
'Memcache::delete' => ['bool', 'key'=>'string', 'timeout='=>'int'],
'Memcache::flush' => ['bool'],
'Memcache::get' => ['array', 'key'=>'string', 'flags='=>'array', 'keys='=>'array'],
'Memcache::getExtendedStats' => ['array', 'type='=>'string', 'slabid='=>'int', 'limit='=>'int'],
'Memcache::getServerStatus' => ['int', 'host'=>'string', 'port='=>'int'],
'Memcache::getStats' => ['array', 'type='=>'string', 'slabid='=>'int', 'limit='=>'int'],
'Memcache::getVersion' => ['string'],
'Memcache::increment' => ['int', 'key'=>'string', 'value='=>'int'],
'Memcache::pconnect' => ['bool', 'host'=>'string', 'port='=>'int', 'timeout='=>'int'],
'Memcache::replace' => ['bool', 'key'=>'string', 'var'=>'mixed', 'flag='=>'int', 'expire='=>'int'],
'Memcache::set' => ['bool', 'key'=>'string', 'var'=>'mixed', 'flag='=>'int', 'expire='=>'int'],
'Memcache::setCompressThreshold' => ['bool', 'threshold'=>'int', 'min_savings='=>'float'],
'Memcache::setServerParams' => ['bool', 'host'=>'string', 'port='=>'int', 'timeout='=>'int', 'retry_interval='=>'int', 'status='=>'bool', 'failure_callback='=>'callable'],
'memcache_debug' => ['bool', 'on_off'=>'bool'],
'Memcached::add' => ['bool', 'key'=>'string', 'value'=>'mixed', 'expiration='=>'int'],
'Memcached::addByKey' => ['bool', 'server_key'=>'string', 'key'=>'string', 'value'=>'mixed', 'expiration='=>'int'],
'Memcached::addServer' => ['bool', 'host'=>'string', 'port'=>'int', 'weight='=>'int'],
'Memcached::addServers' => ['bool', 'servers'=>'array'],
'Memcached::append' => ['bool', 'key'=>'string', 'value'=>'string'],
'Memcached::appendByKey' => ['bool', 'server_key'=>'string', 'key'=>'string', 'value'=>'string'],
'Memcached::cas' => ['bool', 'cas_token'=>'float', 'key'=>'string', 'value'=>'mixed', 'expiration='=>'int'],
'Memcached::casByKey' => ['bool', 'cas_token'=>'float', 'server_key'=>'string', 'key'=>'string', 'value'=>'mixed', 'expiration='=>'int'],
'Memcached::decrement' => ['int|false', 'key'=>'string', 'offset='=>'int', 'initial_value='=>'int', 'expiry='=>'int'],
'Memcached::decrementByKey' => ['int|false', 'server_key'=>'string', 'key'=>'string', 'offset='=>'int', 'initial_value='=>'int', 'expiry='=>'int'],
'Memcached::delete' => ['bool', 'key'=>'string', 'time='=>'int'],
'Memcached::deleteByKey' => ['bool', 'server_key'=>'string', 'key'=>'string', 'time='=>'int'],
'Memcached::deleteMulti' => ['bool', 'keys'=>'array', 'time='=>'int'],
'Memcached::deleteMultiByKey' => ['bool', 'server_key'=>'string', 'keys'=>'array', 'time='=>'int'],
'Memcached::fetch' => ['array'],
'Memcached::fetchAll' => ['array'],
'Memcached::flush' => ['bool', 'delay='=>'int'],
'Memcached::get' => ['mixed', 'key'=>'string', 'cache_cb='=>'?callable', 'flags='=>'int'],
'Memcached::getAllKeys' => ['array'],
'Memcached::getByKey' => ['mixed', 'server_key'=>'string', 'key'=>'string', 'value_cb='=>'?callable', 'flags='=>'int'],
'Memcached::getDelayed' => ['bool', 'keys'=>'array', 'with_cas='=>'bool', 'value_cb='=>'callable'],
'Memcached::getDelayedByKey' => ['bool', 'server_key'=>'string', 'keys'=>'array', 'with_cas='=>'bool', 'value_cb='=>'?callable'],
'Memcached::getMulti' => ['array|false', 'keys'=>'array', 'flags='=>'int'],
'Memcached::getMultiByKey' => ['array', 'server_key'=>'string', 'keys'=>'array', 'flags='=>'int'],
'Memcached::getOption' => ['mixed', 'option'=>'int'],
'Memcached::getResultCode' => ['int'],
'Memcached::getResultMessage' => ['string'],
'Memcached::getServerByKey' => ['array', 'server_key'=>'string'],
'Memcached::getServerList' => ['array'],
'Memcached::getStats' => ['array', 'type='=>'?string'],
'Memcached::getVersion' => ['array'],
'Memcached::increment' => ['int|false', 'key'=>'string', 'offset='=>'int', 'initial_value='=>'int', 'expiry='=>'int'],
'Memcached::incrementByKey' => ['int|false', 'server_key'=>'string', 'key'=>'string', 'offset='=>'int', 'initial_value='=>'int', 'expiry='=>'int'],
'Memcached::isPersistent' => ['bool'],
'Memcached::isPristine' => ['bool'],
'Memcached::prepend' => ['bool', 'key'=>'string', 'value'=>'string'],
'Memcached::prependByKey' => ['bool', 'server_key'=>'string', 'key'=>'string', 'value'=>'string'],
'Memcached::quit' => ['bool'],
'Memcached::replace' => ['bool', 'key'=>'string', 'value'=>'mixed', 'expiration='=>'int'],
'Memcached::replaceByKey' => ['bool', 'server_key'=>'string', 'key'=>'string', 'value'=>'mixed', 'expiration='=>'int'],
'Memcached::resetServerList' => ['bool'],
'Memcached::set' => ['bool', 'key'=>'string', 'value'=>'mixed', 'expiration='=>'int'],
'Memcached::setByKey' => ['bool', 'server_key'=>'string', 'key'=>'string', 'value'=>'mixed', 'expiration='=>'int'],
'Memcached::setMulti' => ['bool', 'items'=>'array', 'expiration='=>'int'],
'Memcached::setMultiByKey' => ['bool', 'server_key'=>'string', 'items'=>'array', 'expiration='=>'int'],
'Memcached::setOption' => ['bool', 'option'=>'int', 'value'=>'mixed'],
'Memcached::setOptions' => ['bool', 'options'=>'array'],
'Memcached::setSaslAuthData' => ['void', 'username'=>'string', 'password'=>'string'],
'Memcached::touch' => ['bool', 'key'=>'string', 'expiration'=>'int'],
'Memcached::touchByKey' => ['bool', 'server_key'=>'string', 'key'=>'string', 'expiration'=>'int'],
'memory_get_peak_usage' => ['int', 'real_usage='=>'bool'],
'memory_get_usage' => ['int', 'real_usage='=>'bool'],
'MessageFormatter::__construct' => ['void', 'locale'=>'string', 'pattern'=>'string'],
'MessageFormatter::create' => ['MessageFormatter', 'locale'=>'string', 'pattern'=>'string'],
'MessageFormatter::format' => ['false|string', 'args'=>'array'],
'MessageFormatter::formatMessage' => ['false|string', 'locale'=>'string', 'pattern'=>'string', 'args'=>'array'],
'MessageFormatter::getErrorCode' => ['int'],
'MessageFormatter::getErrorMessage' => ['string'],
'MessageFormatter::getLocale' => ['string'],
'MessageFormatter::getPattern' => ['string'],
'MessageFormatter::parse' => ['array', 'value'=>'string'],
'MessageFormatter::parseMessage' => ['array', 'locale'=>'string', 'pattern'=>'string', 'source'=>'string'],
'MessageFormatter::setPattern' => ['bool', 'pattern'=>'string'],
'metaphone' => ['string', 'text'=>'string', 'phones='=>'int'],
'method_exists' => ['bool', 'object'=>'object|string', 'method'=>'string'],
'mhash' => ['string', 'hash'=>'int', 'data'=>'string', 'key='=>'string'],
'mhash_count' => ['int'],
'mhash_get_block_size' => ['int', 'hash'=>'int'],
'mhash_get_hash_name' => ['string', 'hash'=>'int'],
'mhash_keygen_s2k' => ['string', 'hash'=>'int', 'input_password'=>'string', 'salt'=>'string', 'bytes'=>'int'],
'microtime' => ['mixed', 'get_as_float='=>'bool'],
'mime_content_type' => ['string|false', 'filename_or_stream'=>'string'],
'min' => ['', '...arg1'=>'array'],
'min\'1' => ['', 'arg1'=>'', 'arg2'=>'', '...args='=>''],
'ming_keypress' => ['int', 'char'=>'string'],
'ming_setcubicthreshold' => ['void', 'threshold'=>'int'],
'ming_setscale' => ['void', 'scale'=>'float'],
'ming_setswfcompression' => ['void', 'level'=>'int'],
'ming_useconstants' => ['void', 'use'=>'int'],
'ming_useswfversion' => ['void', 'version'=>'int'],
'mkdir' => ['bool', 'pathname'=>'string', 'mode='=>'int', 'recursive='=>'bool', 'context='=>'resource'],
'mktime' => ['int', 'hour='=>'int', 'min='=>'int', 'sec='=>'int', 'mon='=>'int', 'day='=>'int', 'year='=>'int'],
'money_format' => ['string', 'format'=>'string', 'value'=>'float'],
'Mongo::__get' => ['MongoDB', 'dbname'=>'string'],
'Mongo::__toString' => ['string'],
'Mongo::close' => ['bool'],
'Mongo::connect' => ['bool'],
'Mongo::connectUtil' => ['bool'],
'Mongo::dropDB' => ['array', 'db'=>''],
'Mongo::forceError' => ['bool'],
'Mongo::getConnections' => ['array'],
'Mongo::getHosts' => ['array'],
'Mongo::getPoolSize' => ['int'],
'Mongo::getReadPreference' => ['array'],
'Mongo::getSlave' => ['string'],
'Mongo::getSlaveOkay' => ['bool'],
'Mongo::getWriteConcern' => ['array'],
'Mongo::killCursor' => ['', 'server_hash'=>'string', 'id'=>'MongoInt64|int'],
'Mongo::lastError' => ['array|null'],
'Mongo::listDBs' => ['array'],
'Mongo::pairConnect' => ['bool'],
'Mongo::pairPersistConnect' => ['bool', 'username='=>'string', 'password='=>'string'],
'Mongo::persistConnect' => ['bool', 'username='=>'string', 'password='=>'string'],
'Mongo::poolDebug' => ['array'],
'Mongo::prevError' => ['array'],
'Mongo::resetError' => ['array'],
'Mongo::selectCollection' => ['MongoCollection', 'db'=>'string', 'collection'=>'string'],
'Mongo::selectDB' => ['MongoDB', 'name'=>'string'],
'Mongo::setPoolSize' => ['bool', 'size'=>'int'],
'Mongo::setReadPreference' => ['bool', 'readPreference'=>'string', 'tags='=>'array'],
'Mongo::setSlaveOkay' => ['bool', 'ok='=>'bool'],
'Mongo::switchSlave' => ['string'],
'MongoBinData::__construct' => ['void', 'data'=>'string', 'type='=>'int'],
'MongoBinData::__toString' => ['string'],
'MongoClient::__construct' => ['void', 'server='=>'string', 'options='=>'array', 'driver_options'=>'array'],
'MongoClient::__get' => ['MongoDB', 'dbname'=>'string'],
'MongoClient::__toString' => ['string'],
'MongoClient::close' => ['bool', 'connection='=>'bool|string'],
'MongoClient::connect' => ['bool'],
'MongoClient::dropDB' => ['array', 'db'=>'mixed'],
'MongoClient::getConnections' => ['array'],
'MongoClient::getHosts' => ['array'],
'MongoClient::getReadPreference' => ['array'],
'MongoClient::getWriteConcern' => ['array'],
'MongoClient::killCursor' => ['bool', 'server_hash'=>'string', 'id'=>'int|MongoInt64'],
'MongoClient::listDBs' => ['array'],
'MongoClient::selectCollection' => ['MongoCollection', 'db'=>'string', 'collection'=>'string'],
'MongoClient::selectDB' => ['MongoDB', 'name'=>'string'],
'MongoClient::setReadPreference' => ['bool', 'read_preference'=>'string', 'tags='=>'array'],
'MongoClient::setWriteConcern' => ['bool', 'w'=>'mixed', 'wtimeout='=>'int'],
'MongoClient::switchSlave' => ['string'],
'MongoCode::__construct' => ['void', 'code'=>'string', 'scope='=>'array'],
'MongoCode::__toString' => ['string'],
'MongoCollection::__construct' => ['void', 'db'=>'MongoDB', 'name'=>'string'],
'MongoCollection::__get' => ['MongoCollection', 'name'=>'string'],
'MongoCollection::__toString' => ['string'],
'MongoCollection::aggregate' => ['array', 'op'=>'array', 'op='=>'array', '...args='=>'array'],
'MongoCollection::aggregate\'1' => ['array', 'pipeline'=>'array', 'options='=>'array'],
'MongoCollection::aggregateCursor' => ['MongoCommandCursor', 'command'=>'array', 'options='=>'array'],
'MongoCollection::batchInsert' => ['mixed', 'a'=>'array', 'options='=>'array'],
'MongoCollection::count' => ['int', 'query='=>'array', 'limit='=>'int', 'skip='=>'int'],
'MongoCollection::createDBRef' => ['array', 'a'=>'array'],
'MongoCollection::createIndex' => ['bool', 'keys'=>'array', 'options='=>'array'],
'MongoCollection::deleteIndex' => ['array', 'keys'=>'string|array'],
'MongoCollection::deleteIndexes' => ['array'],
'MongoCollection::distinct' => ['array', 'key'=>'string', 'query='=>'array'],
'MongoCollection::drop' => ['array'],
'MongoCollection::ensureIndex' => ['bool', 'keys'=>'array', 'options='=>'array'],
'MongoCollection::find' => ['MongoCursor', 'query='=>'array', 'fields='=>'array'],
'MongoCollection::findAndModify' => ['array', 'query'=>'array', 'update='=>'array', 'fields='=>'array', 'options='=>'array'],
'MongoCollection::findOne' => ['array', 'query='=>'array', 'fields='=>'array'],
'MongoCollection::getDBRef' => ['array', 'ref'=>'array'],
'MongoCollection::getIndexInfo' => ['array'],
'MongoCollection::getName' => ['string'],
'MongoCollection::getReadPreference' => ['array'],
'MongoCollection::getSlaveOkay' => ['bool'],
'MongoCollection::getWriteConcern' => ['array'],
'MongoCollection::group' => ['array', 'keys'=>'mixed', 'initial'=>'array', 'reduce'=>'mongocode', 'options='=>'array'],
'MongoCollection::insert' => ['bool|array', 'a'=>'array', 'options='=>'array'],
'MongoCollection::parallelCollectionScan' => ['MongoCommandCursor[]', 'num_cursors'=>'int'],
'MongoCollection::remove' => ['bool|array', 'criteria='=>'array', 'options='=>'array'],
'MongoCollection::save' => ['mixed', 'a'=>'array', 'options='=>'array'],
'MongoCollection::setReadPreference' => ['bool', 'read_preference'=>'string', 'tags='=>'array'],
'MongoCollection::setSlaveOkay' => ['bool', 'ok='=>'bool'],
'MongoCollection::setWriteConcern' => ['bool', 'w'=>'mixed', 'wtimeout='=>'int'],
'MongoCollection::toIndexString' => ['string', 'keys'=>'mixed'],
'MongoCollection::update' => ['bool', 'criteria'=>'array', 'newobj'=>'array', 'options='=>'array'],
'MongoCollection::validate' => ['array', 'scan_data='=>'bool'],
'MongoCommandCursor::__construct' => ['void', 'connection'=>'MongoClient', 'ns'=>'string', 'command'=>'array'],
'MongoCommandCursor::batchSize' => ['MongoCommandCursor', 'batchSize'=>'int'],
'MongoCommandCursor::createFromDocument' => ['MongoCommandCursor', 'connection'=>'MongoClient', 'hash'=>'string', 'document'=>'array'],
'MongoCommandCursor::current' => ['array'],
'MongoCommandCursor::dead' => ['bool'],
'MongoCommandCursor::getReadPreference' => ['array'],
'MongoCommandCursor::info' => ['array'],
'MongoCommandCursor::key' => ['int'],
'MongoCommandCursor::next' => ['void'],
'MongoCommandCursor::rewind' => ['array'],
'MongoCommandCursor::setReadPreference' => ['MongoCommandCursor', 'read_preference'=>'string', 'tags='=>'array'],
'MongoCommandCursor::timeout' => ['MongoCommandCursor', 'ms'=>'int'],
'MongoCommandCursor::valid' => ['bool'],
'MongoCursor::__construct' => ['void', 'connection'=>'MongoClient', 'ns'=>'string', 'query='=>'array', 'fields='=>'array'],
'MongoCursor::addOption' => ['MongoCursor', 'key'=>'string', 'value'=>'mixed'],
'MongoCursor::awaitData' => ['MongoCursor', 'wait='=>'bool'],
'MongoCursor::batchSize' => ['MongoCursor', 'num'=>'int'],
'MongoCursor::count' => ['int', 'foundonly='=>'bool'],
'MongoCursor::current' => ['array'],
'MongoCursor::dead' => ['bool'],
'MongoCursor::doQuery' => ['void'],
'MongoCursor::explain' => ['array'],
'MongoCursor::fields' => ['MongoCursor', 'f'=>'array'],
'MongoCursor::getNext' => ['array'],
'MongoCursor::getReadPreference' => ['array'],
'MongoCursor::hasNext' => ['bool'],
'MongoCursor::hint' => ['MongoCursor', 'key_pattern'=>'array'],
'MongoCursor::immortal' => ['MongoCursor', 'liveforever='=>'bool'],
'MongoCursor::info' => ['array'],
'MongoCursor::key' => ['string'],
'MongoCursor::limit' => ['MongoCursor', 'num'=>'int'],
'MongoCursor::maxTimeMS' => ['MongoCursor', 'ms'=>'int'],
'MongoCursor::next' => ['array'],
'MongoCursor::partial' => ['MongoCursor', 'okay='=>'bool'],
'MongoCursor::reset' => ['void'],
'MongoCursor::rewind' => ['void'],
'MongoCursor::setFlag' => ['MongoCursor', 'flag'=>'int', 'set='=>'bool'],
'MongoCursor::setReadPreference' => ['MongoCursor', 'read_preference'=>'string', 'tags='=>'array'],
'MongoCursor::skip' => ['MongoCursor', 'num'=>'int'],
'MongoCursor::slaveOkay' => ['MongoCursor', 'okay='=>'bool'],
'MongoCursor::snapshot' => ['MongoCursor'],
'MongoCursor::sort' => ['MongoCursor', 'fields'=>'array'],
'MongoCursor::tailable' => ['MongoCursor', 'tail='=>'bool'],
'MongoCursor::timeout' => ['MongoCursor', 'ms'=>'int'],
'MongoCursor::valid' => ['bool'],
'MongoCursorException::__clone' => ['void'],
'MongoCursorException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?\Exception|?\Throwable'],
'MongoCursorException::__toString' => ['string'],
'MongoCursorException::__wakeup' => ['void'],
'MongoCursorException::getCode' => ['int'],
'MongoCursorException::getFile' => ['string'],
'MongoCursorException::getHost' => ['string'],
'MongoCursorException::getLine' => ['int'],
'MongoCursorException::getMessage' => ['string'],
'MongoCursorException::getPrevious' => ['Exception|Throwable'],
'MongoCursorException::getTrace' => ['array'],
'MongoCursorException::getTraceAsString' => ['string'],
'MongoCursorInterface::__construct' => ['void'],
'MongoCursorInterface::batchSize' => ['MongoCursorInterface', 'batchSize'=>'int'],
'MongoCursorInterface::current' => ['mixed'],
'MongoCursorInterface::dead' => ['bool'],
'MongoCursorInterface::getReadPreference' => ['array'],
'MongoCursorInterface::info' => ['array'],
'MongoCursorInterface::key' => ['int|string'],
'MongoCursorInterface::next' => ['void'],
'MongoCursorInterface::rewind' => ['void'],
'MongoCursorInterface::setReadPreference' => ['MongoCursorInterface', 'read_preference'=>'string', 'tags='=>'array'],
'MongoCursorInterface::timeout' => ['MongoCursorInterface', 'ms'=>'int'],
'MongoCursorInterface::valid' => ['bool'],
'MongoDate::__construct' => ['void', 'sec='=>'int', 'usec='=>'int'],
'MongoDate::__toString' => ['string'],
'MongoDate::toDateTime' => ['DateTime'],
'MongoDB::__construct' => ['void', 'conn'=>'MongoClient', 'name'=>'string'],
'MongoDB::__get' => ['MongoCollection', 'name'=>'string'],
'MongoDB::__toString' => ['string'],
'MongoDB::authenticate' => ['array', 'username'=>'string', 'password'=>'string'],
'MongoDB::command' => ['array', 'command'=>'array'],
'MongoDB::createCollection' => ['MongoCollection', 'name'=>'string', 'capped='=>'bool', 'size='=>'int', 'max='=>'int'],
'MongoDB::createDBRef' => ['array', 'collection'=>'string', 'a'=>''],
'MongoDB::drop' => ['array'],
'MongoDB::dropCollection' => ['array', 'coll'=>''],
'MongoDB::execute' => ['array', 'code'=>'', 'args='=>'array'],
'MongoDB::forceError' => ['bool'],
'MongoDB::getCollectionInfo' => ['array', 'options='=>'array'],
'MongoDB::getCollectionNames' => ['array', 'options='=>'array'],
'MongoDB::getDBRef' => ['array', 'ref'=>'array'],
'MongoDB::getGridFS' => ['MongoGridFS', 'prefix='=>'string'],
'MongoDB::getProfilingLevel' => ['int'],
'MongoDB::getReadPreference' => ['array'],
'MongoDB::getSlaveOkay' => ['bool'],
'MongoDB::getWriteConcern' => ['array'],
'MongoDB::lastError' => ['array'],
'MongoDB::listCollections' => ['array'],
'MongoDB::prevError' => ['array'],
'MongoDB::repair' => ['array', 'preserve_cloned_files='=>'bool', 'backup_original_files='=>'bool'],
'MongoDB::resetError' => ['array'],
'MongoDB::selectCollection' => ['MongoCollection', 'name'=>'string'],
'MongoDB::setProfilingLevel' => ['int', 'level'=>'int'],
'MongoDB::setReadPreference' => ['bool', 'read_preference'=>'string', 'tags='=>'array'],
'MongoDB::setSlaveOkay' => ['bool', 'ok='=>'bool'],
'MongoDB::setWriteConcern' => ['bool', 'w'=>'mixed', 'wtimeout='=>'int'],
'MongoDB\BSON\Binary::__construct' => ['void', 'data'=>'string', 'type'=>'int'],
'MongoDB\BSON\Binary::getData' => ['string'],
'MongoDB\BSON\Binary::getType' => ['int'],
'MongoDB\BSON\Decimal128::__construct' => ['void', 'value='=>'string'],
'MongoDB\BSON\Decimal128::__toString' => ['string'],
'MongoDB\BSON\fromJSON' => ['string', 'json'=>'string'],
'MongoDB\BSON\fromPHP' => ['string', 'value'=>'array|object'],
'MongoDB\BSON\Javascript::__construct' => ['void', 'code'=>'string', 'scope='=>'array|object'],
'MongoDB\BSON\ObjectId::__construct' => ['void', 'id='=>'string'],
'MongoDB\BSON\ObjectId::__toString' => ['string'],
'MongoDB\BSON\Regex::__construct' => ['void', 'pattern'=>'string', 'flags='=>'string'],
'MongoDB\BSON\Regex::__toString' => ['string'],
'MongoDB\BSON\Regex::getFlags' => [''],
'MongoDB\BSON\Regex::getPattern' => ['string'],
'MongoDB\BSON\Serializable::bsonSerialize' => ['array|object'],
'MongoDB\BSON\Timestamp::__construct' => ['void', 'increment'=>'int', 'timestamp'=>'int'],
'MongoDB\BSON\Timestamp::__toString' => ['string'],
'MongoDB\BSON\toJSON' => ['string', 'bson'=>'string'],
'MongoDB\BSON\toPHP' => ['object', 'bson'=>'string', 'typeMap'=>'array'],
'MongoDB\BSON\Unserializable::bsonUnserialize' => ['', 'data'=>'array'],
'MongoDB\BSON\UTCDateTime::__construct' => ['void', 'milliseconds='=>'int'],
'MongoDB\BSON\UTCDateTime::__toString' => ['string'],
'MongoDB\BSON\UTCDateTime::toDateTime' => ['DateTime'],
'MongoDB\Driver\BulkWrite::__construct' => ['void', 'ordered='=>'bool'],
'MongoDB\Driver\BulkWrite::count' => ['int'],
'MongoDB\Driver\BulkWrite::delete' => ['void', 'filter'=>'array|object', 'deleteOptions='=>'array'],
'MongoDB\Driver\BulkWrite::insert' => ['MongoDB\Driver\ObjectID', 'document'=>'array|object'],
'MongoDB\Driver\BulkWrite::update' => ['void', 'filter'=>'array|object', 'newObj'=>'array|object', 'updateOptions='=>'array'],
'MongoDB\Driver\Command::__construct' => ['void', 'document'=>'array|object'],
'MongoDB\Driver\Cursor::__construct' => ['void', 'server'=>'Server', 'responseDocument'=>'string'],
'MongoDB\Driver\Cursor::getId' => ['MongoDB\Driver\CursorId'],
'MongoDB\Driver\Cursor::getServer' => ['MongoDB\Driver\Server'],
'MongoDB\Driver\Cursor::isDead' => ['bool'],
'MongoDB\Driver\Cursor::setTypeMap' => ['void', 'typemap'=>'array'],
'MongoDB\Driver\Cursor::toArray' => ['array'],
'MongoDB\Driver\CursorId::__construct' => ['void', 'id'=>'string'],
'MongoDB\Driver\CursorId::__toString' => ['string'],
'MongoDB\Driver\Exception\RuntimeException::__clone' => ['void'],
'MongoDB\Driver\Exception\RuntimeException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?\RuntimeException|?\Throwable'],
'MongoDB\Driver\Exception\RuntimeException::__toString' => ['string'],
'MongoDB\Driver\Exception\RuntimeException::__wakeup' => ['void'],
'MongoDB\Driver\Exception\RuntimeException::getCode' => ['int'],
'MongoDB\Driver\Exception\RuntimeException::getFile' => ['string'],
'MongoDB\Driver\Exception\RuntimeException::getLine' => ['int'],
'MongoDB\Driver\Exception\RuntimeException::getMessage' => ['string'],
'MongoDB\Driver\Exception\RuntimeException::getPrevious' => ['RuntimeException|Throwable'],
'MongoDB\Driver\Exception\RuntimeException::getTrace' => ['array'],
'MongoDB\Driver\Exception\RuntimeException::getTraceAsString' => ['string'],
'MongoDB\Driver\Exception\WriteException::__clone' => ['void'],
'MongoDB\Driver\Exception\WriteException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?\RuntimeException|?\Throwable'],
'MongoDB\Driver\Exception\WriteException::__toString' => ['string'],
'MongoDB\Driver\Exception\WriteException::__wakeup' => ['void'],
'MongoDB\Driver\Exception\WriteException::getCode' => ['int'],
'MongoDB\Driver\Exception\WriteException::getFile' => ['string'],
'MongoDB\Driver\Exception\WriteException::getLine' => ['int'],
'MongoDB\Driver\Exception\WriteException::getMessage' => ['string'],
'MongoDB\Driver\Exception\WriteException::getPrevious' => ['RuntimeException|Throwable'],
'MongoDB\Driver\Exception\WriteException::getTrace' => ['array'],
'MongoDB\Driver\Exception\WriteException::getTraceAsString' => ['string'],
'MongoDB\Driver\Exception\WriteException::getWriteResult' => ['MongoDB\Driver\WriteResult'],
'MongoDB\Driver\Manager::__construct' => ['void', 'uri'=>'string', 'options='=>'array', 'driverOptions='=>'array'],
'MongoDB\Driver\Manager::executeBulkWrite' => ['MongoDB\Driver\WriteResult', 'namespace'=>'string', 'bulk'=>'MongoDB\Driver\BulkWrite', 'writeConcern='=>'MongoDB\Driver\WriteConcern'],
'MongoDB\Driver\Manager::executeCommand' => ['MongoDB\Driver\Cursor', 'db'=>'string', 'command'=>'MongoDB\Driver\Command', 'readPreference='=>'MongoDB\Driver\ReadPreference'],
'MongoDB\Driver\Manager::executeDelete' => ['MongoDB\Driver\WriteResult', 'namespace'=>'string', 'filter'=>'array|object', 'deleteOptions='=>'array', 'writeConcern='=>'MongoDB\Driver\WriteConcern'],
'MongoDB\Driver\Manager::executeInsert' => ['MongoDB\Driver\WriteResult', 'namespace'=>'string', 'document'=>'array|object', 'writeConcern='=>'MongoDB\Driver\WriteConcern'],
'MongoDB\Driver\Manager::executeQuery' => ['MongoDB\Driver\Cursor', 'namespace'=>'string', 'query'=>'MongoDB\Driver\Query', 'readPreference='=>'MongoDB\Driver\ReadPreference'],
'MongoDB\Driver\Manager::executeUpdate' => ['MongoDB\Driver\WriteResult', 'namespace'=>'string', 'filter'=>'array|object', 'newObj'=>'array|object', 'updateOptions='=>'array', 'writeConcern='=>'MongoDB\Driver\WriteConcern'],
'MongoDB\Driver\Manager::getReadConcern' => ['MongoDB\Driver\ReadConcern'],
'MongoDB\Driver\Manager::getReadPreference' => ['MongoDB\Driver\ReadPreference'],
'MongoDB\Driver\Manager::getServers' => ['array'],
'MongoDB\Driver\Manager::getWriteConcern' => ['MongoDB\Driver\WriteConcern'],
'MongoDB\Driver\Manager::selectServer' => ['MongoDB\Driver\Server', 'readPreference'=>'MongoDB\Driver\ReadPreference'],
'MongoDB\Driver\Query::__construct' => ['void', 'filter'=>'array|object', 'queryOptions='=>'array'],
'MongoDB\Driver\ReadConcern::__construct' => ['void', 'level='=>'string'],
'MongoDB\Driver\ReadConcern::bsonSerialize' => ['object'],
'MongoDB\Driver\ReadConcern::getLevel' => ['null|string'],
'MongoDB\Driver\ReadPreference::__construct' => ['void', 'readPreference'=>'string', 'tagSets='=>'array'],
'MongoDB\Driver\ReadPreference::bsonSerialize' => ['object'],
'MongoDB\Driver\ReadPreference::getMode' => ['int'],
'MongoDB\Driver\ReadPreference::getTagSets' => ['array'],
'MongoDB\Driver\Server::__construct' => ['void', 'host'=>'string', 'port'=>'string', 'options='=>'array', 'driverOptions='=>'array'],
'MongoDB\Driver\Server::executeBulkWrite' => ['', 'namespace'=>'string', 'zwrite'=>'BulkWrite'],
'MongoDB\Driver\Server::executeCommand' => ['', 'db'=>'string', 'command'=>'Command'],
'MongoDB\Driver\Server::executeQuery' => ['', 'namespace'=>'string', 'zquery'=>'Query'],
'MongoDB\Driver\Server::getHost' => [''],
'MongoDB\Driver\Server::getInfo' => [''],
'MongoDB\Driver\Server::getLatency' => [''],
'MongoDB\Driver\Server::getPort' => [''],
'MongoDB\Driver\Server::getState' => [''],
'MongoDB\Driver\Server::getTags' => ['array'],
'MongoDB\Driver\Server::getType' => [''],
'MongoDB\Driver\Server::isArbiter' => ['bool'],
'MongoDB\Driver\Server::isDelayed' => [''],
'MongoDB\Driver\Server::isHidden' => ['bool'],
'MongoDB\Driver\Server::isPassive' => [''],
'MongoDB\Driver\Server::isPrimary' => ['bool'],
'MongoDB\Driver\Server::isSecondary' => ['bool'],
'MongoDB\Driver\WriteConcern::__construct' => ['void', 'wstring'=>'string', 'wtimeout='=>'int', 'journal='=>'bool', 'fsync='=>'bool'],
'MongoDB\Driver\WriteConcern::getJurnal' => ['bool|null'],
'MongoDB\Driver\WriteConcern::getW' => ['int|null|string'],
'MongoDB\Driver\WriteConcern::getWtimeout' => ['int'],
'MongoDB\Driver\WriteConcernError::getCode' => [''],
'MongoDB\Driver\WriteConcernError::getInfo' => [''],
'MongoDB\Driver\WriteConcernError::getMessage' => [''],
'MongoDB\Driver\WriteError::getCode' => [''],
'MongoDB\Driver\WriteError::getIndex' => [''],
'MongoDB\Driver\WriteError::getInfo' => ['mixed'],
'MongoDB\Driver\WriteError::getMessage' => [''],
'MongoDB\Driver\WriteException::getWriteResult' => [''],
'MongoDB\Driver\WriteResult::getDeletedCount' => ['int'],
'MongoDB\Driver\WriteResult::getInfo' => [''],
'MongoDB\Driver\WriteResult::getInsertedCount' => ['int'],
'MongoDB\Driver\WriteResult::getMatchedCount' => ['int'],
'MongoDB\Driver\WriteResult::getModifiedCount' => ['int'],
'MongoDB\Driver\WriteResult::getServer' => [''],
'MongoDB\Driver\WriteResult::getUpsertedCount' => ['int'],
'MongoDB\Driver\WriteResult::getUpsertedIds' => [''],
'MongoDB\Driver\WriteResult::getWriteConcernError' => [''],
'MongoDB\Driver\WriteResult::getWriteErrors' => [''],
'MongoDB\Driver\WriteResult::isAcknowledged' => ['bool'],
'MongoDBRef::create' => ['array', 'collection'=>'string', 'id'=>'mixed', 'database='=>'string'],
'MongoDBRef::get' => ['array', 'db'=>'mongodb', 'ref'=>'array'],
'MongoDBRef::isRef' => ['bool', 'ref'=>'mixed'],
'MongoDeleteBatch::__construct' => ['void', 'collection'=>'MongoCollection', 'write_options='=>'array'],
'MongoException::__clone' => ['void'],
'MongoException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?\Exception|?\Throwable'],
'MongoException::__toString' => ['string'],
'MongoException::__wakeup' => ['void'],
'MongoException::getCode' => ['int'],
'MongoException::getFile' => ['string'],
'MongoException::getLine' => ['int'],
'MongoException::getMessage' => ['string'],
'MongoException::getPrevious' => ['Exception|Throwable'],
'MongoException::getTrace' => ['array'],
'MongoException::getTraceAsString' => ['string'],
'MongoGridFS::__construct' => ['void', 'db'=>'MongoDB', 'prefix='=>'string', 'chunks='=>'mixed'],
'MongoGridFS::__get' => ['MongoCollection', 'name'=>'string'],
'MongoGridFS::__toString' => ['string'],
'MongoGridFS::aggregate' => ['array', 'pipeline'=>'array', 'op'=>'array', 'pipelineOperators'=>'array'],
'MongoGridFS::aggregateCursor' => ['MongoCommandCursor', 'pipeline'=>'array', 'options'=>'array'],
'MongoGridFS::batchInsert' => ['mixed', 'a'=>'array', 'options='=>'array'],
'MongoGridFS::count' => ['int', 'query='=>'stdClass|array'],
'MongoGridFS::createDBRef' => ['array', 'a'=>'array'],
'MongoGridFS::createIndex' => ['array', 'keys'=>'array', 'options='=>'array'],
'MongoGridFS::delete' => ['bool', 'id'=>'mixed'],
'MongoGridFS::deleteIndex' => ['array', 'keys'=>'array|string'],
'MongoGridFS::deleteIndexes' => ['array'],
'MongoGridFS::distinct' => ['array|bool', 'key'=>'string', 'query='=>'?array'],
'MongoGridFS::drop' => ['array'],
'MongoGridFS::ensureIndex' => ['bool', 'keys'=>'array', 'options='=>'array'],
'MongoGridFS::find' => ['MongoGridFSCursor', 'query='=>'array', 'fields='=>'array'],
'MongoGridFS::findAndModify' => ['array', 'query'=>'array', 'update='=>'?array', 'fields='=>'?array', 'options='=>'?array'],
'MongoGridFS::findOne' => ['MongoGridFSFile', 'query='=>'mixed', 'fields='=>'mixed'],
'MongoGridFS::get' => ['MongoGridFSFile', 'id'=>'mixed'],
'MongoGridFS::getDBRef' => ['array', 'ref'=>'array'],
'MongoGridFS::getIndexInfo' => ['array'],
'MongoGridFS::getName' => ['string'],
'MongoGridFS::getReadPreference' => ['array'],
'MongoGridFS::getSlaveOkay' => ['bool'],
'MongoGridFS::group' => ['array', 'keys'=>'mixed', 'initial'=>'array', 'reduce'=>'MongoCode', 'condition='=>'array'],
'MongoGridFS::insert' => ['array|bool', 'a'=>'array|object', 'options='=>'array'],
'MongoGridFS::put' => ['mixed', 'filename'=>'string', 'extra='=>'array'],
'MongoGridFS::remove' => ['bool', 'criteria='=>'array', 'options='=>'array'],
'MongoGridFS::save' => ['array|bool', 'a'=>'array|object', 'options='=>'array'],
'MongoGridFS::setReadPreference' => ['bool', 'read_preference'=>'string', 'tags'=>'array'],
'MongoGridFS::setSlaveOkay' => ['bool', 'ok='=>'bool|true'],
'MongoGridFS::storeBytes' => ['mixed', 'bytes'=>'string', 'extra='=>'array', 'options='=>'array'],
'MongoGridFS::storeFile' => ['mixed', 'filename'=>'string', 'extra='=>'array', 'options='=>'array'],
'MongoGridFS::storeUpload' => ['mixed', 'name'=>'string', 'filename='=>'string'],
'MongoGridFS::toIndexString' => ['string', 'keys'=>'mixed'],
'MongoGridFS::update' => ['bool', 'criteria'=>'array', 'newobj'=>'array', 'options='=>'array'],
'MongoGridFS::validate' => ['array', 'scan_data='=>'bool|false'],
'MongoGridFSCursor::__construct' => ['void', 'gridfs'=>'MongoGridFS', 'connection'=>'resource', 'ns'=>'string', 'query'=>'array', 'fields'=>'array'],
'MongoGridFSCursor::addOption' => ['MongoCursor', 'key'=>'string', 'value'=>'mixed'],
'MongoGridFSCursor::awaitData' => ['MongoCursor', 'wait='=>'bool|true'],
'MongoGridFSCursor::batchSize' => ['MongoCursor', 'batchSize'=>'int'],
'MongoGridFSCursor::count' => ['int', 'all='=>'bool|false'],
'MongoGridFSCursor::current' => ['MongoGridFSFile'],
'MongoGridFSCursor::dead' => ['bool'],
'MongoGridFSCursor::doQuery' => ['void'],
'MongoGridFSCursor::explain' => ['array'],
'MongoGridFSCursor::fields' => ['MongoCursor', 'f'=>'array'],
'MongoGridFSCursor::getNext' => ['MongoGridFSFile'],
'MongoGridFSCursor::getReadPreference' => ['array'],
'MongoGridFSCursor::hasNext' => ['bool'],
'MongoGridFSCursor::hint' => ['MongoCursor', 'key_pattern'=>'mixed'],
'MongoGridFSCursor::immortal' => ['MongoCursor', 'liveForever='=>'bool|true'],
'MongoGridFSCursor::info' => ['array'],
'MongoGridFSCursor::key' => ['string'],
'MongoGridFSCursor::limit' => ['MongoCursor', 'num'=>'int'],
'MongoGridFSCursor::maxTimeMS' => ['MongoCursor', 'ms'=>'int'],
'MongoGridFSCursor::next' => ['void'],
'MongoGridFSCursor::partial' => ['MongoCursor', 'okay='=>'bool|true'],
'MongoGridFSCursor::reset' => ['void'],
'MongoGridFSCursor::rewind' => ['void'],
'MongoGridFSCursor::setFlag' => ['MongoCursor', 'flag'=>'int', 'set='=>'bool|true'],
'MongoGridFSCursor::setReadPreference' => ['MongoCursor', 'read_preference'=>'string', 'tags'=>'array'],
'MongoGridFSCursor::skip' => ['MongoCursor', 'num'=>'int'],
'MongoGridFSCursor::slaveOkay' => ['MongoCursor', 'okay='=>'bool|true'],
'MongoGridFSCursor::snapshot' => ['MongoCursor'],
'MongoGridFSCursor::sort' => ['MongoCursor', 'fields'=>'array'],
'MongoGridFSCursor::tailable' => ['MongoCursor', 'tail='=>'bool|true'],
'MongoGridFSCursor::timeout' => ['MongoCursor', 'ms'=>'int'],
'MongoGridFSCursor::valid' => ['bool'],
'MongoGridfsFile::__construct' => ['void', 'gridfs'=>'MongoGridFS', 'file'=>'array'],
'MongoGridFSFile::getBytes' => ['string'],
'MongoGridFSFile::getFilename' => ['string'],
'MongoGridFSFile::getResource' => ['resource'],
'MongoGridFSFile::getSize' => ['int'],
'MongoGridFSFile::write' => ['int', 'filename='=>'string'],
'MongoId::__construct' => ['void', 'id='=>'string|MongoId'],
'MongoId::__set_state' => ['MongoId', 'props'=>'array'],
'MongoId::__toString' => ['string'],
'MongoId::getHostname' => ['string'],
'MongoId::getInc' => ['int'],
'MongoId::getPID' => ['int'],
'MongoId::getTimestamp' => ['int'],
'MongoId::isValid' => ['bool', 'value'=>'mixed'],
'MongoInsertBatch::__construct' => ['void', 'collection'=>'MongoCollection', 'write_options='=>'array'],
'MongoInt32::__construct' => ['void', 'value'=>'string'],
'MongoInt32::__toString' => ['string'],
'MongoInt64::__construct' => ['void', 'value'=>'string'],
'MongoInt64::__toString' => ['string'],
'MongoLog::getCallback' => ['callable'],
'MongoLog::getLevel' => ['int'],
'MongoLog::getModule' => ['int'],
'MongoLog::setCallback' => ['void', 'log_function'=>'callable'],
'MongoLog::setLevel' => ['void', 'level'=>'int'],
'MongoLog::setModule' => ['void', 'module'=>'int'],
'MongoPool::getSize' => ['int'],
'MongoPool::info' => ['array'],
'MongoPool::setSize' => ['bool', 'size'=>'int'],
'MongoRegex::__construct' => ['void', 'regex'=>'string'],
'MongoRegex::__toString' => ['string'],
'MongoResultException::__clone' => ['void'],
'MongoResultException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?\Exception|?\Throwable'],
'MongoResultException::__toString' => ['string'],
'MongoResultException::__wakeup' => ['void'],
'MongoResultException::getCode' => ['int'],
'MongoResultException::getDocument' => ['array'],
'MongoResultException::getFile' => ['string'],
'MongoResultException::getLine' => ['int'],
'MongoResultException::getMessage' => ['string'],
'MongoResultException::getPrevious' => ['Exception|Throwable'],
'MongoResultException::getTrace' => ['array'],
'MongoResultException::getTraceAsString' => ['string'],
'MongoTimestamp::__construct' => ['void', 'sec='=>'int', 'inc='=>'int'],
'MongoTimestamp::__toString' => ['string'],
'MongoUpdateBatch::__construct' => ['void', 'collection'=>'MongoCollection', 'write_options='=>'array'],
'MongoUpdateBatch::add' => ['bool', 'item'=>'array'],
'MongoUpdateBatch::execute' => ['array', 'write_options'=>'array'],
'MongoWriteBatch::__construct' => ['void', 'collection'=>'MongoCollection', 'batch_type'=>'string', 'write_options'=>'array'],
'MongoWriteBatch::add' => ['bool', 'item'=>'array'],
'MongoWriteBatch::execute' => ['array', 'write_options'=>'array'],
'MongoWriteConcernException::__clone' => ['void'],
'MongoWriteConcernException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?\Exception|?\Throwable'],
'MongoWriteConcernException::__toString' => ['string'],
'MongoWriteConcernException::__wakeup' => ['void'],
'MongoWriteConcernException::getCode' => ['int'],
'MongoWriteConcernException::getDocument' => ['array'],
'MongoWriteConcernException::getFile' => ['string'],
'MongoWriteConcernException::getLine' => ['int'],
'MongoWriteConcernException::getMessage' => ['string'],
'MongoWriteConcernException::getPrevious' => ['Exception|Throwable'],
'MongoWriteConcernException::getTrace' => ['array'],
'MongoWriteConcernException::getTraceAsString' => ['string'],
'monitor_custom_event' => ['void', 'class'=>'class', 'text'=>'text', 'severe='=>'severe', 'user_data='=>'user_data'],
'monitor_httperror_event' => ['void', 'error_code'=>'error_code', 'url'=>'url', 'severe='=>'severe'],
'monitor_license_info' => ['array'],
'monitor_pass_error' => ['void', 'errno'=>'', 'errstr'=>'', 'errfile'=>'', 'errline'=>''],
'monitor_set_aggregation_hint' => ['void', 'hint'=>'hint'],
'move_uploaded_file' => ['bool', 'path'=>'string', 'new_path'=>'string'],
'mqseries_back' => ['void', 'hconn'=>'resource', 'compcode'=>'resource', 'reason'=>'resource'],
'mqseries_begin' => ['void', 'hconn'=>'resource', 'beginoptions'=>'array', 'compcode'=>'resource', 'reason'=>'resource'],
'mqseries_close' => ['void', 'hconn'=>'resource', 'hobj'=>'resource', 'options'=>'int', 'compcode'=>'resource', 'reason'=>'resource'],
'mqseries_cmit' => ['void', 'hconn'=>'resource', 'compcode'=>'resource', 'reason'=>'resource'],
'mqseries_conn' => ['void', 'qmanagername'=>'string', 'hconn'=>'resource', 'compcode'=>'resource', 'reason'=>'resource'],
'mqseries_connx' => ['void', 'qmanagername'=>'string', 'connoptions'=>'array', 'hconn'=>'resource', 'compcode'=>'resource', 'reason'=>'resource'],
'mqseries_disc' => ['void', 'hconn'=>'resource', 'compcode'=>'resource', 'reason'=>'resource'],
'mqseries_get' => ['void', 'hconn'=>'resource', 'hobj'=>'resource', 'md'=>'array', 'gmo'=>'array', 'bufferlength'=>'int', 'msg'=>'string', 'data_length'=>'int', 'compcode'=>'resource', 'reason'=>'resource'],
'mqseries_inq' => ['void', 'hconn'=>'resource', 'hobj'=>'resource', 'selectorcount'=>'int', 'selectors'=>'array', 'intattrcount'=>'int', 'intattr'=>'resource', 'charattrlength'=>'int', 'charattr'=>'resource', 'compcode'=>'resource', 'reason'=>'resource'],
'mqseries_open' => ['void', 'hconn'=>'resource', 'objdesc'=>'array', 'option'=>'int', 'hobj'=>'resource', 'compcode'=>'resource', 'reason'=>'resource'],
'mqseries_put' => ['void', 'hconn'=>'resource', 'hobj'=>'resource', 'md'=>'array', 'pmo'=>'array', 'message'=>'string', 'compcode'=>'resource', 'reason'=>'resource'],
'mqseries_put1' => ['void', 'hconn'=>'resource', 'objdesc'=>'resource', 'msgdesc'=>'resource', 'pmo'=>'resource', 'buffer'=>'string', 'compcode'=>'resource', 'reason'=>'resource'],
'mqseries_set' => ['void', 'hconn'=>'resource', 'hobj'=>'resource', 'selectorcount'=>'int', 'selectors'=>'array', 'intattrcount'=>'int', 'intattrs'=>'array', 'charattrlength'=>'int', 'charattrs'=>'array', 'compcode'=>'resource', 'reason'=>'resource'],
'mqseries_strerror' => ['string', 'reason'=>'int'],
'ms_GetErrorObj' => ['errorObj'],
'ms_GetVersion' => ['string'],
'ms_GetVersionInt' => ['int'],
'ms_iogetStdoutBufferBytes' => ['int'],
'ms_iogetstdoutbufferstring' => ['void'],
'ms_ioinstallstdinfrombuffer' => ['void'],
'ms_ioinstallstdouttobuffer' => ['void'],
'ms_ioresethandlers' => ['void'],
'ms_iostripstdoutbuffercontentheaders' => ['void'],
'ms_iostripstdoutbuffercontenttype' => ['string'],
'ms_ResetErrorList' => ['void'],
'ms_TokenizeMap' => ['array', 'map_file_name'=>'string'],
'msession_connect' => ['bool', 'host'=>'string', 'port'=>'string'],
'msession_count' => ['int'],
'msession_create' => ['bool', 'session'=>'string', 'classname='=>'string', 'data='=>'string'],
'msession_destroy' => ['bool', 'name'=>'string'],
'msession_disconnect' => ['void'],
'msession_find' => ['array', 'name'=>'string', 'value'=>'string'],
'msession_get' => ['string', 'session'=>'string', 'name'=>'string', 'value'=>'string'],
'msession_get_array' => ['array', 'session'=>'string'],
'msession_get_data' => ['string', 'session'=>'string'],
'msession_inc' => ['string', 'session'=>'string', 'name'=>'string'],
'msession_list' => ['array'],
'msession_listvar' => ['array', 'name'=>'string'],
'msession_lock' => ['int', 'name'=>'string'],
'msession_plugin' => ['string', 'session'=>'string', 'val'=>'string', 'param='=>'string'],
'msession_randstr' => ['string', 'param'=>'int'],
'msession_set' => ['bool', 'session'=>'string', 'name'=>'string', 'value'=>'string'],
'msession_set_array' => ['void', 'session'=>'string', 'tuples'=>'array'],
'msession_set_data' => ['bool', 'session'=>'string', 'value'=>'string'],
'msession_timeout' => ['int', 'session'=>'string', 'param='=>'int'],
'msession_uniq' => ['string', 'param'=>'int', 'classname='=>'string', 'data='=>'string'],
'msession_unlock' => ['int', 'session'=>'string', 'key'=>'int'],
'msg_get_queue' => ['resource', 'key'=>'int', 'perms='=>'int'],
'msg_queue_exists' => ['bool', 'key'=>'int'],
'msg_receive' => ['bool', 'queue'=>'resource', 'desiredmsgtype'=>'int', '&w_msgtype'=>'int', 'maxsize'=>'int', '&w_message'=>'mixed', 'unserialize='=>'bool', 'flags='=>'int', '&w_errorcode='=>'int'],
'msg_remove_queue' => ['bool', 'queue'=>'resource'],
'msg_send' => ['bool', 'queue'=>'resource', 'msgtype'=>'int', 'message'=>'mixed', 'serialize='=>'bool', 'blocking='=>'bool', '&w_errorcode='=>'int'],
'msg_set_queue' => ['bool', 'queue'=>'resource', 'data'=>'array'],
'msg_stat_queue' => ['array', 'queue'=>'resource'],
'msgfmt_create' => ['MessageFormatter', 'locale'=>'string', 'pattern'=>'string'],
'msgfmt_format' => ['string', 'fmt'=>'messageformatter', 'args'=>'array'],
'msgfmt_format_message' => ['string', 'locale'=>'string', 'pattern'=>'string', 'args'=>'array'],
'msgfmt_get_error_code' => ['int', 'fmt'=>'messageformatter'],
'msgfmt_get_error_message' => ['string', 'fmt'=>'messageformatter'],
'msgfmt_get_locale' => ['string', 'formatter'=>'messageformatter'],
'msgfmt_get_pattern' => ['string', 'fmt'=>'messageformatter'],
'msgfmt_parse' => ['array', 'fmt'=>'messageformatter', 'value'=>'string'],
'msgfmt_parse_message' => ['array', 'locale'=>'string', 'pattern'=>'string', 'source'=>'string'],
'msgfmt_set_pattern' => ['bool', 'fmt'=>'messageformatter', 'pattern'=>'string'],
'msql_affected_rows' => ['int', 'result'=>'resource'],
'msql_close' => ['bool', 'link_identifier='=>'?resource'],
'msql_connect' => ['resource', 'hostname='=>'string'],
'msql_create_db' => ['bool', 'database_name'=>'string', 'link_identifier='=>'?resource'],
'msql_data_seek' => ['bool', 'result'=>'resource', 'row_number'=>'int'],
'msql_db_query' => ['resource', 'database'=>'string', 'query'=>'string', 'link_identifier='=>'?resource'],
'msql_drop_db' => ['bool', 'database_name'=>'string', 'link_identifier='=>'?resource'],
'msql_error' => ['string'],
'msql_fetch_array' => ['array', 'result'=>'resource', 'result_type='=>'int'],
'msql_fetch_field' => ['object', 'result'=>'resource', 'field_offset='=>'int'],
'msql_fetch_object' => ['object', 'result'=>'resource'],
'msql_fetch_row' => ['array', 'result'=>'resource'],
'msql_field_flags' => ['string', 'result'=>'resource', 'field_offset'=>'int'],
'msql_field_len' => ['int', 'result'=>'resource', 'field_offset'=>'int'],
'msql_field_name' => ['string', 'result'=>'resource', 'field_offset'=>'int'],
'msql_field_seek' => ['bool', 'result'=>'resource', 'field_offset'=>'int'],
'msql_field_table' => ['int', 'result'=>'resource', 'field_offset'=>'int'],
'msql_field_type' => ['string', 'result'=>'resource', 'field_offset'=>'int'],
'msql_free_result' => ['bool', 'result'=>'resource'],
'msql_list_dbs' => ['resource', 'link_identifier='=>'?resource'],
'msql_list_fields' => ['resource', 'database'=>'string', 'tablename'=>'string', 'link_identifier='=>'?resource'],
'msql_list_tables' => ['resource', 'database'=>'string', 'link_identifier='=>'?resource'],
'msql_num_fields' => ['int', 'result'=>'resource'],
'msql_num_rows' => ['int', 'query_identifier'=>'resource'],
'msql_pconnect' => ['resource', 'hostname='=>'string'],
'msql_query' => ['resource', 'query'=>'string', 'link_identifier='=>'?resource'],
'msql_result' => ['string', 'result'=>'resource', 'row'=>'int', 'field='=>'mixed'],
'msql_select_db' => ['bool', 'database_name'=>'string', 'link_identifier='=>'?resource'],
'mssql_bind' => ['bool', 'stmt'=>'resource', 'param_name'=>'string', 'var'=>'mixed', 'type'=>'int', 'is_output='=>'bool', 'is_null='=>'bool', 'maxlen='=>'int'],
'mssql_close' => ['bool', 'link_identifier='=>'resource'],
'mssql_connect' => ['resource', 'servername='=>'string', 'username='=>'string', 'password='=>'string', 'new_link='=>'bool'],
'mssql_data_seek' => ['bool', 'result_identifier'=>'resource', 'row_number'=>'int'],
'mssql_execute' => ['mixed', 'stmt'=>'resource', 'skip_results='=>'bool'],
'mssql_fetch_array' => ['array', 'result'=>'resource', 'result_type='=>'int'],
'mssql_fetch_assoc' => ['array', 'result_id'=>'resource'],
'mssql_fetch_batch' => ['int', 'result'=>'resource'],
'mssql_fetch_field' => ['object', 'result'=>'resource', 'field_offset='=>'int'],
'mssql_fetch_object' => ['object', 'result'=>'resource'],
'mssql_fetch_row' => ['array', 'result'=>'resource'],
'mssql_field_length' => ['int', 'result'=>'resource', 'offset='=>'int'],
'mssql_field_name' => ['string', 'result'=>'resource', 'offset='=>'int'],
'mssql_field_seek' => ['bool', 'result'=>'resource', 'field_offset'=>'int'],
'mssql_field_type' => ['string', 'result'=>'resource', 'offset='=>'int'],
'mssql_free_result' => ['bool', 'result'=>'resource'],
'mssql_free_statement' => ['bool', 'stmt'=>'resource'],
'mssql_get_last_message' => ['string'],
'mssql_guid_string' => ['string', 'binary'=>'string', 'short_format='=>'bool'],
'mssql_init' => ['resource', 'sp_name'=>'string', 'link_identifier='=>'resource'],
'mssql_min_error_severity' => ['void', 'severity'=>'int'],
'mssql_min_message_severity' => ['void', 'severity'=>'int'],
'mssql_next_result' => ['bool', 'result_id'=>'resource'],
'mssql_num_fields' => ['int', 'result'=>'resource'],
'mssql_num_rows' => ['int', 'result'=>'resource'],
'mssql_pconnect' => ['resource', 'servername='=>'string', 'username='=>'string', 'password='=>'string', 'new_link='=>'bool'],
'mssql_query' => ['mixed', 'query'=>'string', 'link_identifier='=>'resource', 'batch_size='=>'int'],
'mssql_result' => ['string', 'result'=>'resource', 'row'=>'int', 'field'=>'mixed'],
'mssql_rows_affected' => ['int', 'link_identifier'=>'resource'],
'mssql_select_db' => ['bool', 'database_name'=>'string', 'link_identifier='=>'resource'],
'mt_getrandmax' => ['int'],
'mt_rand' => ['int', 'min'=>'int', 'max'=>'int'],
'mt_rand\'1' => ['int'],
'mt_srand' => ['void', 'seed='=>'int', 'mode='=>'int'],
'MultipleIterator::__construct' => ['void', 'flags'=>'int'],
'MultipleIterator::attachIterator' => ['void', 'iterator'=>'iterator', 'infos='=>'string'],
'MultipleIterator::containsIterator' => ['bool', 'iterator'=>'iterator'],
'MultipleIterator::countIterators' => ['int'],
'MultipleIterator::current' => ['array'],
'MultipleIterator::detachIterator' => ['void', 'iterator'=>'iterator'],
'MultipleIterator::getFlags' => ['int'],
'MultipleIterator::key' => ['array'],
'MultipleIterator::next' => ['void'],
'MultipleIterator::rewind' => ['void'],
'MultipleIterator::setFlags' => ['int', 'flags'=>'int'],
'MultipleIterator::valid' => ['bool'],
'Mutex::create' => ['long', 'lock='=>'bool'],
'Mutex::destroy' => ['bool', 'mutex'=>'long'],
'Mutex::lock' => ['bool', 'mutex'=>'long'],
'Mutex::trylock' => ['bool', 'mutex'=>'long'],
'Mutex::unlock' => ['bool', 'mutex'=>'long', 'destroy='=>'bool'],
'mysql_affected_rows' => ['int', 'link_identifier='=>'resource'],
'mysql_client_encoding' => ['string', 'link_identifier='=>'resource'],
'mysql_close' => ['bool', 'link_identifier='=>'resource'],
'mysql_connect' => ['resource', 'server='=>'string', 'username='=>'string', 'password='=>'string', 'new_link='=>'bool', 'client_flags='=>'int'],
'mysql_create_db' => ['bool', 'database_name'=>'string', 'link_identifier='=>'resource'],
'mysql_data_seek' => ['bool', 'result'=>'resource', 'row_number'=>'int'],
'mysql_db_name' => ['string', 'result'=>'resource', 'row'=>'int', 'field='=>'mixed'],
'mysql_db_query' => ['resource', 'database'=>'string', 'query'=>'string', 'link_identifier='=>'resource'],
'mysql_drop_db' => ['bool', 'database_name'=>'string', 'link_identifier='=>'resource'],
'mysql_errno' => ['int', 'link_identifier='=>'resource'],
'mysql_error' => ['string', 'link_identifier='=>'resource'],
'mysql_escape_string' => ['string', 'unescaped_string'=>'string'],
'mysql_fetch_array' => ['array', 'result'=>'resource', 'result_type='=>'int'],
'mysql_fetch_assoc' => ['array', 'result'=>'resource'],
'mysql_fetch_field' => ['object', 'result'=>'resource', 'field_offset='=>'int'],
'mysql_fetch_lengths' => ['array', 'result'=>'resource'],
'mysql_fetch_object' => ['object', 'result'=>'resource', 'class_name='=>'string', 'params='=>'array'],
'mysql_fetch_row' => ['array', 'result'=>'resource'],
'mysql_field_flags' => ['string', 'result'=>'resource', 'field_offset'=>'int'],
'mysql_field_len' => ['int', 'result'=>'resource', 'field_offset'=>'int'],
'mysql_field_name' => ['string', 'result'=>'resource', 'field_offset'=>'int'],
'mysql_field_seek' => ['bool', 'result'=>'resource', 'field_offset'=>'int'],
'mysql_field_table' => ['string', 'result'=>'resource', 'field_offset'=>'int'],
'mysql_field_type' => ['string', 'result'=>'resource', 'field_offset'=>'int'],
'mysql_free_result' => ['bool', 'result'=>'resource'],
'mysql_get_client_info' => ['string'],
'mysql_get_host_info' => ['string', 'link_identifier='=>'resource'],
'mysql_get_proto_info' => ['int', 'link_identifier='=>'resource'],
'mysql_get_server_info' => ['string', 'link_identifier='=>'resource'],
'mysql_info' => ['string', 'link_identifier='=>'resource'],
'mysql_insert_id' => ['int', 'link_identifier='=>'resource'],
'mysql_list_dbs' => ['resource', 'link_identifier='=>'resource'],
'mysql_list_fields' => ['resource', 'database_name'=>'string', 'table_name'=>'string', 'link_identifier='=>'resource'],
'mysql_list_processes' => ['resource', 'link_identifier='=>'resource'],
'mysql_list_tables' => ['resource', 'database'=>'string', 'link_identifier='=>'resource'],
'mysql_num_fields' => ['int', 'result'=>'resource'],
'mysql_num_rows' => ['int', 'result'=>'resource'],
'mysql_pconnect' => ['resource', 'server='=>'string', 'username='=>'string', 'password='=>'string', 'client_flags='=>'int'],
'mysql_ping' => ['bool', 'link_identifier='=>'resource'],
'mysql_query' => ['resource', 'query'=>'string', 'link_identifier='=>'resource'],
'mysql_real_escape_string' => ['string', 'unescaped_string'=>'string', 'link_identifier='=>'resource'],
'mysql_result' => ['string', 'result'=>'resource', 'row'=>'int', 'field='=>'mixed'],
'mysql_select_db' => ['bool', 'database_name'=>'string', 'link_identifier='=>'resource'],
'mysql_set_charset' => ['bool', 'charset'=>'string', 'link_identifier='=>'resource'],
'mysql_stat' => ['string', 'link_identifier='=>'resource'],
'mysql_tablename' => ['string', 'result'=>'resource', 'i'=>'int'],
'mysql_thread_id' => ['int', 'link_identifier='=>'resource'],
'mysql_unbuffered_query' => ['resource', 'query'=>'string', 'link_identifier='=>'resource'],
'mysqli::__construct' => ['void', 'host='=>'string', 'username='=>'string', 'passwd='=>'string', 'dbname='=>'string', 'port='=>'int', 'socket='=>'string'],
'mysqli::autocommit' => ['bool', 'mode'=>'bool'],
'mysqli::begin_transaction' => ['bool', 'flags='=>'int', 'name='=>'string'],
'mysqli::change_user' => ['bool', 'user'=>'string', 'password'=>'string', 'database'=>'string'],
'mysqli::character_set_name' => ['string'],
'mysqli::close' => ['bool'],
'mysqli::commit' => ['bool', 'flags='=>'int', 'name='=>'string'],
'mysqli::debug' => ['bool', 'message'=>'string'],
'mysqli::disable_reads_from_master' => ['bool'],
'mysqli::dump_debug_info' => ['bool'],
'mysqli::get_charset' => ['object'],
'mysqli::get_client_info' => ['string'],
'mysqli::get_connection_stats' => ['array|false'],
'mysqli::get_warnings' => ['mysqli_warning'],
'mysqli::init' => ['mysqli'],
'mysqli::kill' => ['bool', 'processid'=>'int'],
'mysqli::more_results' => ['bool'],
'mysqli::multi_query' => ['bool', 'query'=>'string'],
'mysqli::next_result' => ['bool'],
'mysqli::options' => ['bool', 'option'=>'int', 'value'=>'mixed'],
'mysqli::ping' => ['bool'],
'mysqli::poll' => ['int|false', 'read'=>'array', 'error'=>'array', 'reject'=>'array', 'sec'=>'int', 'usec='=>'int'],
'mysqli::prepare' => ['mysqli_stmt|false', 'query'=>'string'],
'mysqli::query' => ['bool|mysqli_result', 'query'=>'string', 'resultmode='=>'int'],
'mysqli::real_connect' => ['bool', 'host='=>'string', 'username='=>'string', 'passwd='=>'string', 'dbname='=>'string', 'port='=>'int', 'socket='=>'string', 'flags='=>'int'],
'mysqli::real_escape_string' => ['string', 'escapestr'=>'string'],
'mysqli::real_query' => ['bool', 'query'=>'string'],
'mysqli::reap_async_query' => ['mysqli_result|false'],
'mysqli::refresh' => ['bool', 'options'=>'int'],
'mysqli::release_savepoint' => ['bool', 'name'=>'string'],
'mysqli::rollback' => ['bool', 'flags='=>'int', 'name='=>'string'],
'mysqli::rpl_query_type' => ['int', 'query'=>'string'],
'mysqli::savepoint' => ['bool', 'name'=>'string'],
'mysqli::select_db' => ['bool', 'dbname'=>'string'],
'mysqli::send_query' => ['bool', 'query'=>'string'],
'mysqli::set_charset' => ['bool', 'charset'=>'string'],
'mysqli::set_local_infile_default' => ['void'],
'mysqli::set_local_infile_handler' => ['bool', 'read_func='=>'callable'],
'mysqli::ssl_set' => ['bool', 'key'=>'string', 'cert'=>'string', 'ca'=>'string', 'capath'=>'string', 'cipher'=>'string'],
'mysqli::stat' => ['string|false'],
'mysqli::stmt_init' => ['mysqli_stmt'],
'mysqli::store_result' => ['mysqli_result|false', 'option='=>'int'],
'mysqli::thread_safe' => ['bool'],
'mysqli::use_result' => ['mysqli_result|false'],
'mysqli_affected_rows' => ['int', 'link'=>'mysqli'],
'mysqli_autocommit' => ['bool', 'link'=>'mysqli', 'mode'=>'bool'],
'mysqli_begin_transaction' => ['bool', 'link'=>'mysqli', 'flags'=>'int', 'name'=>'string'],
'mysqli_change_user' => ['bool', 'link'=>'mysqli', 'user'=>'string', 'password'=>'string', 'database'=>'string'],
'mysqli_character_set_name' => ['string', 'link'=>'mysqli'],
'mysqli_close' => ['bool', 'link'=>'mysqli'],
'mysqli_commit' => ['bool', 'link'=>'mysqli', 'flags='=>'int', 'name='=>'string'],
'mysqli_connect' => ['mysqli|false', 'host='=>'string', 'username='=>'string', 'passwd='=>'string', 'dbname='=>'string', 'port='=>'int', 'socket='=>'string'],
'mysqli_connect_errno' => ['int'],
'mysqli_connect_error' => ['string'],
'mysqli_data_seek' => ['bool', 'result'=>'mysqli_result', 'offset'=>'int'],
'mysqli_debug' => ['bool', 'message'=>'string'],
'mysqli_disable_reads_from_master' => ['bool', 'link'=>'mysqli'],
'mysqli_disable_rpl_parse' => ['bool', 'link'=>'mysqli'],
'mysqli_driver::embedded_server_end' => ['void'],
'mysqli_driver::embedded_server_start' => ['bool', 'start'=>'int', 'arguments'=>'array', 'groups'=>'array'],
'mysqli_dump_debug_info' => ['bool', 'link'=>'mysqli'],
'mysqli_embedded_server_end' => ['void'],
'mysqli_embedded_server_start' => ['bool', 'start'=>'int', 'arguments'=>'array', 'groups'=>'array'],
'mysqli_enable_reads_from_master' => ['bool', 'link'=>'mysqli'],
'mysqli_enable_rpl_parse' => ['bool', 'link'=>'mysqli'],
'mysqli_errno' => ['int', 'link'=>'mysqli'],
'mysqli_error' => ['string', 'link'=>'mysqli'],
'mysqli_error_list' => ['array', 'connection'=>'mysqli'],
'mysqli_fetch_all' => ['array', 'result'=>'mysqli_result', 'resulttype='=>'int'],
'mysqli_fetch_array' => ['array|null', 'result'=>'mysqli_result', 'resulttype='=>'int'],
'mysqli_fetch_assoc' => ['array|null', 'result'=>'mysqli_result'],
'mysqli_fetch_field' => ['object|false', 'result'=>'mysqli_result'],
'mysqli_fetch_field_direct' => ['object|false', 'result'=>'mysqli_result', 'fieldnr'=>'int'],
'mysqli_fetch_fields' => ['array|false', 'result'=>'mysqli_result'],
'mysqli_fetch_lengths' => ['array|false', 'result'=>'mysqli_result'],
'mysqli_fetch_object' => ['object|null', 'result'=>'mysqli_result', 'class_name='=>'string', 'params='=>'?array'],
'mysqli_fetch_row' => ['array|null', 'result'=>'mysqli_result'],
'mysqli_field_count' => ['int', 'link'=>'mysqli'],
'mysqli_field_seek' => ['bool', 'result'=>'mysqli_result', 'fieldnr'=>'int'],
'mysqli_field_tell' => ['int', 'result'=>'mysqli_result'],
'mysqli_free_result' => ['void', 'link'=>'mysqli_result'],
'mysqli_get_cache_stats' => ['array'],
'mysqli_get_charset' => ['object', 'link'=>'mysqli'],
'mysqli_get_client_info' => ['string', 'link'=>'mysqli'],
'mysqli_get_client_stats' => ['array'],
'mysqli_get_client_version' => ['int', 'link'=>'mysqli'],
'mysqli_get_connection_stats' => ['array|false', 'link'=>'mysqli'],
'mysqli_get_host_info' => ['string', 'link'=>'mysqli'],
'mysqli_get_links_stats' => ['array'],
'mysqli_get_proto_info' => ['int', 'link'=>'mysqli'],
'mysqli_get_server_info' => ['string', 'link'=>'mysqli'],
'mysqli_get_server_version' => ['int', 'link'=>'mysqli'],
'mysqli_get_warnings' => ['mysqli_warning', 'link'=>'mysqli'],
'mysqli_info' => ['?string', 'link'=>'mysqli'],
'mysqli_init' => ['mysqli'],
'mysqli_insert_id' => ['int|string', 'link'=>'mysqli'],
'mysqli_kill' => ['bool', 'link'=>'mysqli', 'processid'=>'int'],
'mysqli_link_construct' => ['object'],
'mysqli_master_query' => ['bool', 'link'=>'mysqli', 'query'=>'string'],
'mysqli_more_results' => ['bool', 'link'=>'mysqli'],
'mysqli_multi_query' => ['bool', 'link'=>'mysqli', 'query'=>'string'],
'mysqli_next_result' => ['bool', 'link'=>'mysqli'],
'mysqli_num_fields' => ['int', 'link'=>'mysqli_result'],
'mysqli_num_rows' => ['int', 'link'=>'mysqli_result'],
'mysqli_options' => ['bool', 'link'=>'mysqli', 'option'=>'int', 'value'=>'mixed'],
'mysqli_ping' => ['bool', 'link'=>'mysqli'],
'mysqli_poll' => ['int|false', 'read'=>'array', 'error'=>'array', 'reject'=>'array', 'sec'=>'int', 'usec='=>'int'],
'mysqli_prepare' => ['mysqli_stmt|false', 'link'=>'mysqli', 'query'=>'string'],
'mysqli_query' => ['false|mysqli_result', 'link'=>'mysqli', 'query'=>'string', 'resultmode='=>'int'],
'mysqli_real_connect' => ['bool', 'link='=>'mysqli', 'host='=>'string', 'username='=>'string', 'passwd='=>'string', 'dbname='=>'string', 'port='=>'int', 'socket='=>'string', 'flags='=>'int'],
'mysqli_real_escape_string' => ['string', 'link'=>'mysqli', 'escapestr'=>'string'],
'mysqli_real_query' => ['bool', 'link'=>'mysqli', 'query'=>'string'],
'mysqli_reap_async_query' => ['mysqli_result|false', 'link'=>'mysqli'],
'mysqli_refresh' => ['bool', 'link'=>'mysqli', 'options'=>'int'],
'mysqli_release_savepoint' => ['bool', 'link'=>'mysqli', 'name'=>'string'],
'mysqli_report' => ['bool', 'flags'=>'int'],
'mysqli_result::__construct' => ['void', 'link'=>'mysqli', 'resultmode='=>'int'],
'mysqli_result::close' => ['void'],
'mysqli_result::data_seek' => ['bool', 'offset'=>'int'],
'mysqli_result::fetch_all' => ['array', 'resulttype='=>'int'],
'mysqli_result::fetch_array' => ['array|null', 'resulttype='=>'int'],
'mysqli_result::fetch_assoc' => ['array|null'],
'mysqli_result::fetch_field' => ['object|false'],
'mysqli_result::fetch_field_direct' => ['object|false', 'fieldnr'=>'int'],
'mysqli_result::fetch_fields' => ['array|false'],
'mysqli_result::fetch_object' => ['object|null', 'class_name='=>'string', 'params='=>'array'],
'mysqli_result::fetch_row' => ['array|null'],
'mysqli_result::field_seek' => ['bool', 'fieldnr'=>'int'],
'mysqli_result::free' => ['void'],
'mysqli_result::free_result' => ['void'],
'mysqli_rollback' => ['bool', 'link'=>'mysqli', 'flags='=>'int', 'name='=>'string'],
'mysqli_rpl_parse_enabled' => ['int', 'link'=>'mysqli'],
'mysqli_rpl_probe' => ['bool', 'link'=>'mysqli'],
'mysqli_rpl_query_type' => ['int', 'link'=>'mysqli', 'query'=>'string'],
'mysqli_savepoint' => ['bool', 'link'=>'mysqli', 'name'=>'string'],
'mysqli_savepoint_libmysql' => ['bool'],
'mysqli_select_db' => ['bool', 'link'=>'mysqli', 'dbname'=>'string'],
'mysqli_send_query' => ['bool', 'link'=>'mysqli', 'query'=>'string'],
'mysqli_set_charset' => ['bool', 'link'=>'mysqli', 'charset'=>'string'],
'mysqli_set_local_infile_default' => ['void', 'link'=>'mysqli'],
'mysqli_set_local_infile_handler' => ['bool', 'link'=>'mysqli', 'read_func'=>'callable'],
'mysqli_slave_query' => ['bool', 'link'=>'mysqli', 'query'=>'string'],
'mysqli_sqlstate' => ['string', 'link'=>'mysqli'],
'mysqli_ssl_set' => ['bool', 'link'=>'mysqli', 'key'=>'string', 'cert'=>'string', 'ca'=>'string', 'capath'=>'string', 'cipher'=>'string'],
'mysqli_stat' => ['string|false', 'link'=>'mysqli'],
'mysqli_stmt::__construct' => ['void', 'query='=>'string'],
'mysqli_stmt::attr_get' => ['false|int', 'attr'=>'int'],
'mysqli_stmt::attr_set' => ['bool', 'attr'=>'int', 'mode'=>'int'],
'mysqli_stmt::bind_param' => ['bool', 'types'=>'string', 'var1'=>'mixed', '...args='=>'mixed'],
'mysqli_stmt::bind_result' => ['bool', 'var1'=>'mixed', '...args='=>'mixed'],
'mysqli_stmt::close' => ['bool'],
'mysqli_stmt::data_seek' => ['void', 'offset'=>'int'],
'mysqli_stmt::execute' => ['bool'],
'mysqli_stmt::fetch' => ['bool'],
'mysqli_stmt::free_result' => ['void'],
'mysqli_stmt::get_result' => ['mysqli_result|false'],
'mysqli_stmt::get_warnings' => ['object'],
'mysqli_stmt::more_results' => ['bool'],
'mysqli_stmt::next_result' => ['bool'],
'mysqli_stmt::num_rows' => ['int'],
'mysqli_stmt::prepare' => ['bool', 'query'=>'string'],
'mysqli_stmt::reset' => ['bool'],
'mysqli_stmt::result_metadata' => ['mysqli_result|false'],
'mysqli_stmt::send_long_data' => ['bool', 'param_nr'=>'int', 'data'=>'string'],
'mysqli_stmt::store_result' => ['bool'],
'mysqli_stmt_affected_rows' => ['int', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_attr_get' => ['false|int', 'stmt'=>'mysqli_stmt', 'attr'=>'int'],
'mysqli_stmt_attr_set' => ['bool', 'stmt'=>'mysqli_stmt', 'attr'=>'int', 'mode'=>'int'],
'mysqli_stmt_bind_param' => ['bool', 'stmt'=>'mysqli_stmt', 'types'=>'string', 'var1'=>'mixed', '...args='=>'mixed'],
'mysqli_stmt_bind_result' => ['bool', 'stmt'=>'mysqli_stmt', 'var1='=>'mixed', '...args='=>'mixed'],
'mysqli_stmt_close' => ['bool', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_data_seek' => ['void', 'stmt'=>'mysqli_stmt', 'offset'=>'int'],
'mysqli_stmt_errno' => ['int', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_error' => ['string', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_error_list' => ['array', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_execute' => ['bool', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_fetch' => ['bool', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_field_count' => ['int', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_free_result' => ['void', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_get_result' => ['mysqli_result|false', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_get_warnings' => ['object', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_init' => ['mysqli_stmt', 'link'=>'mysqli'],
'mysqli_stmt_insert_id' => ['', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_more_results' => ['bool', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_next_result' => ['bool', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_num_rows' => ['int', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_param_count' => ['int', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_prepare' => ['bool', 'stmt'=>'mysqli_stmt', 'query'=>'string'],
'mysqli_stmt_reset' => ['bool', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_result_metadata' => ['mysqli_result|false', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_send_long_data' => ['bool', 'stmt'=>'mysqli_stmt', 'param_nr'=>'int', 'data'=>'string'],
'mysqli_stmt_sqlstate' => ['string', 'stmt'=>'mysqli_stmt'],
'mysqli_stmt_store_result' => ['bool', 'stmt'=>'mysqli_stmt'],
'mysqli_store_result' => ['mysqli_result|false', 'link'=>'mysqli', 'option='=>'int'],
'mysqli_thread_id' => ['int', 'link'=>'mysqli'],
'mysqli_thread_safe' => ['bool'],
'mysqli_use_result' => ['mysqli_result|false', 'link'=>'mysqli'],
'mysqli_warning::__construct' => ['void'],
'mysqli_warning::next' => ['void'],
'mysqli_warning_count' => ['int', 'link'=>'mysqli'],
'mysqlnd_memcache_get_config' => ['array', 'connection'=>'mixed'],
'mysqlnd_memcache_set' => ['bool', 'mysql_connection'=>'mixed', 'memcache_connection='=>'Memcached', 'pattern='=>'string', 'callback='=>'callable'],
'mysqlnd_ms_dump_servers' => ['array', 'connection'=>'mixed'],
'mysqlnd_ms_fabric_select_global' => ['array', 'connection'=>'mixed', 'table_name'=>'mixed'],
'mysqlnd_ms_fabric_select_shard' => ['array', 'connection'=>'mixed', 'table_name'=>'mixed', 'shard_key'=>'mixed'],
'mysqlnd_ms_get_last_gtid' => ['string', 'connection'=>'mixed'],
'mysqlnd_ms_get_last_used_connection' => ['array', 'connection'=>'mixed'],
'mysqlnd_ms_get_stats' => ['array'],
'mysqlnd_ms_match_wild' => ['bool', 'table_name'=>'string', 'wildcard'=>'string'],
'mysqlnd_ms_query_is_select' => ['int', 'query'=>'string'],
'mysqlnd_ms_set_qos' => ['bool', 'connection'=>'mixed', 'service_level'=>'int', 'service_level_option='=>'int', 'option_value='=>'mixed'],
'mysqlnd_ms_set_user_pick_server' => ['bool', 'function'=>'string'],
'mysqlnd_ms_xa_begin' => ['int', 'connection'=>'mixed', 'gtrid'=>'string', 'timeout='=>'int'],
'mysqlnd_ms_xa_commit' => ['int', 'connection'=>'mixed', 'gtrid'=>'string'],
'mysqlnd_ms_xa_gc' => ['int', 'connection'=>'mixed', 'gtrid='=>'string', 'ignore_max_retries='=>'bool'],
'mysqlnd_ms_xa_rollback' => ['int', 'connection'=>'mixed', 'gtrid'=>'string'],
'mysqlnd_qc_change_handler' => ['bool', 'handler'=>''],
'mysqlnd_qc_clear_cache' => ['bool'],
'mysqlnd_qc_get_available_handlers' => ['array'],
'mysqlnd_qc_get_cache_info' => ['array'],
'mysqlnd_qc_get_core_stats' => ['array'],
'mysqlnd_qc_get_handler' => ['array'],
'mysqlnd_qc_get_normalized_query_trace_log' => ['array'],
'mysqlnd_qc_get_query_trace_log' => ['array'],
'mysqlnd_qc_set_cache_condition' => ['bool', 'condition_type'=>'int', 'condition'=>'mixed', 'condition_option'=>'mixed'],
'mysqlnd_qc_set_is_select' => ['mixed', 'callback'=>'string'],
'mysqlnd_qc_set_storage_handler' => ['bool', 'handler'=>'string'],
'mysqlnd_qc_set_user_handlers' => ['bool', 'get_hash'=>'string', 'find_query_in_cache'=>'string', 'return_to_cache'=>'string', 'add_query_to_cache_if_not_exists'=>'string', 'query_is_select'=>'string', 'update_query_run_time_stats'=>'string', 'get_stats'=>'string', 'clear_cache'=>'string'],
'mysqlnd_uh_convert_to_mysqlnd' => ['resource', '&rw_mysql_connection'=>'mysqli'],
'mysqlnd_uh_set_connection_proxy' => ['bool', '&rw_connection_proxy'=>'MysqlndUhConnection', '&rw_mysqli_connection='=>'mysqli'],
'mysqlnd_uh_set_statement_proxy' => ['bool', '&rw_statement_proxy'=>'MysqlndUhStatement'],
'MysqlndUhConnection::__construct' => ['void'],
'MysqlndUhConnection::changeUser' => ['bool', 'connection'=>'mysqlnd_connection', 'user'=>'string', 'password'=>'string', 'database'=>'string', 'silent'=>'bool', 'passwd_len'=>'int'],
'MysqlndUhConnection::charsetName' => ['string', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::close' => ['bool', 'connection'=>'mysqlnd_connection', 'close_type'=>'int'],
'MysqlndUhConnection::connect' => ['bool', 'connection'=>'mysqlnd_connection', 'host'=>'string', 'use'=>'string', 'password'=>'string', 'database'=>'string', 'port'=>'int', 'socket'=>'string', 'mysql_flags'=>'int'],
'MysqlndUhConnection::endPSession' => ['bool', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::escapeString' => ['string', 'connection'=>'mysqlnd_connection', 'escape_string'=>'string'],
'MysqlndUhConnection::getAffectedRows' => ['int', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::getErrorNumber' => ['int', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::getErrorString' => ['string', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::getFieldCount' => ['int', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::getHostInformation' => ['string', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::getLastInsertId' => ['int', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::getLastMessage' => ['void', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::getProtocolInformation' => ['string', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::getServerInformation' => ['string', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::getServerStatistics' => ['string', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::getServerVersion' => ['int', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::getSqlstate' => ['string', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::getStatistics' => ['array', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::getThreadId' => ['int', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::getWarningCount' => ['int', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::init' => ['bool', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::killConnection' => ['bool', 'connection'=>'mysqlnd_connection', 'pid'=>'int'],
'MysqlndUhConnection::listFields' => ['array', 'connection'=>'mysqlnd_connection', 'table'=>'string', 'achtung_wild'=>'string'],
'MysqlndUhConnection::listMethod' => ['void', 'connection'=>'mysqlnd_connection', 'query'=>'string', 'achtung_wild'=>'string', 'par1'=>'string'],
'MysqlndUhConnection::moreResults' => ['bool', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::nextResult' => ['bool', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::ping' => ['bool', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::query' => ['bool', 'connection'=>'mysqlnd_connection', 'query'=>'string'],
'MysqlndUhConnection::queryReadResultsetHeader' => ['bool', 'connection'=>'mysqlnd_connection', 'mysqlnd_stmt'=>'mysqlnd_statement'],
'MysqlndUhConnection::reapQuery' => ['bool', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::refreshServer' => ['bool', 'connection'=>'mysqlnd_connection', 'options'=>'int'],
'MysqlndUhConnection::restartPSession' => ['bool', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::selectDb' => ['bool', 'connection'=>'mysqlnd_connection', 'database'=>'string'],
'MysqlndUhConnection::sendClose' => ['bool', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::sendQuery' => ['bool', 'connection'=>'mysqlnd_connection', 'query'=>'string'],
'MysqlndUhConnection::serverDumpDebugInformation' => ['bool', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::setAutocommit' => ['bool', 'connection'=>'mysqlnd_connection', 'mode'=>'int'],
'MysqlndUhConnection::setCharset' => ['bool', 'connection'=>'mysqlnd_connection', 'charset'=>'string'],
'MysqlndUhConnection::setClientOption' => ['bool', 'connection'=>'mysqlnd_connection', 'option'=>'int', 'value'=>'int'],
'MysqlndUhConnection::setServerOption' => ['void', 'connection'=>'mysqlnd_connection', 'option'=>'int'],
'MysqlndUhConnection::shutdownServer' => ['void', 'MYSQLND_UH_RES_MYSQLND_NAME'=>'string', 'level'=>'string'],
'MysqlndUhConnection::simpleCommand' => ['bool', 'connection'=>'mysqlnd_connection', 'command'=>'int', 'arg'=>'string', 'ok_packet'=>'int', 'silent'=>'bool', 'ignore_upsert_status'=>'bool'],
'MysqlndUhConnection::simpleCommandHandleResponse' => ['bool', 'connection'=>'mysqlnd_connection', 'ok_packet'=>'int', 'silent'=>'bool', 'command'=>'int', 'ignore_upsert_status'=>'bool'],
'MysqlndUhConnection::sslSet' => ['bool', 'connection'=>'mysqlnd_connection', 'key'=>'string', 'cert'=>'string', 'ca'=>'string', 'capath'=>'string', 'cipher'=>'string'],
'MysqlndUhConnection::stmtInit' => ['resource', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::storeResult' => ['resource', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::txCommit' => ['bool', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::txRollback' => ['bool', 'connection'=>'mysqlnd_connection'],
'MysqlndUhConnection::useResult' => ['resource', 'connection'=>'mysqlnd_connection'],
'MysqlndUhPreparedStatement::__construct' => ['void'],
'MysqlndUhPreparedStatement::execute' => ['bool', 'statement'=>'mysqlnd_prepared_statement'],
'MysqlndUhPreparedStatement::prepare' => ['bool', 'statement'=>'mysqlnd_prepared_statement', 'query'=>'string'],
'natcasesort' => ['bool', '&rw_array_arg'=>'array'],
'natsort' => ['bool', '&rw_array_arg'=>'array'],
'ncurses_addch' => ['int', 'ch'=>'int'],
'ncurses_addchnstr' => ['int', 's'=>'string', 'n'=>'int'],
'ncurses_addchstr' => ['int', 's'=>'string'],
'ncurses_addnstr' => ['int', 's'=>'string', 'n'=>'int'],
'ncurses_addstr' => ['int', 'text'=>'string'],
'ncurses_assume_default_colors' => ['int', 'fg'=>'int', 'bg'=>'int'],
'ncurses_attroff' => ['int', 'attributes'=>'int'],
'ncurses_attron' => ['int', 'attributes'=>'int'],
'ncurses_attrset' => ['int', 'attributes'=>'int'],
'ncurses_baudrate' => ['int'],
'ncurses_beep' => ['int'],
'ncurses_bkgd' => ['int', 'attrchar'=>'int'],
'ncurses_bkgdset' => ['void', 'attrchar'=>'int'],
'ncurses_border' => ['int', 'left'=>'int', 'right'=>'int', 'top'=>'int', 'bottom'=>'int', 'tl_corner'=>'int', 'tr_corner'=>'int', 'bl_corner'=>'int', 'br_corner'=>'int'],
'ncurses_bottom_panel' => ['int', 'panel'=>'resource'],
'ncurses_can_change_color' => ['bool'],
'ncurses_cbreak' => ['bool'],
'ncurses_clear' => ['bool'],
'ncurses_clrtobot' => ['bool'],
'ncurses_clrtoeol' => ['bool'],
'ncurses_color_content' => ['int', 'color'=>'int', 'r'=>'int', 'g'=>'int', 'b'=>'int'],
'ncurses_color_set' => ['int', 'pair'=>'int'],
'ncurses_curs_set' => ['int', 'visibility'=>'int'],
'ncurses_def_prog_mode' => ['bool'],
'ncurses_def_shell_mode' => ['bool'],
'ncurses_define_key' => ['int', 'definition'=>'string', 'keycode'=>'int'],
'ncurses_del_panel' => ['bool', 'panel'=>'resource'],
'ncurses_delay_output' => ['int', 'milliseconds'=>'int'],
'ncurses_delch' => ['bool'],
'ncurses_deleteln' => ['bool'],
'ncurses_delwin' => ['bool', 'window'=>'resource'],
'ncurses_doupdate' => ['bool'],
'ncurses_echo' => ['bool'],
'ncurses_echochar' => ['int', 'character'=>'int'],
'ncurses_end' => ['int'],
'ncurses_erase' => ['bool'],
'ncurses_erasechar' => ['string'],
'ncurses_filter' => ['void'],
'ncurses_flash' => ['bool'],
'ncurses_flushinp' => ['bool'],
'ncurses_getch' => ['int'],
'ncurses_getmaxyx' => ['void', 'window'=>'resource', 'y'=>'int', 'x'=>'int'],
'ncurses_getmouse' => ['bool', 'mevent'=>'array'],
'ncurses_getyx' => ['void', 'window'=>'resource', 'y'=>'int', 'x'=>'int'],
'ncurses_halfdelay' => ['int', 'tenth'=>'int'],
'ncurses_has_colors' => ['bool'],
'ncurses_has_ic' => ['bool'],
'ncurses_has_il' => ['bool'],
'ncurses_has_key' => ['int', 'keycode'=>'int'],
'ncurses_hide_panel' => ['int', 'panel'=>'resource'],
'ncurses_hline' => ['int', 'charattr'=>'int', 'n'=>'int'],
'ncurses_inch' => ['string'],
'ncurses_init' => ['void'],
'ncurses_init_color' => ['int', 'color'=>'int', 'r'=>'int', 'g'=>'int', 'b'=>'int'],
'ncurses_init_pair' => ['int', 'pair'=>'int', 'fg'=>'int', 'bg'=>'int'],
'ncurses_insch' => ['int', 'character'=>'int'],
'ncurses_insdelln' => ['int', 'count'=>'int'],
'ncurses_insertln' => ['int'],
'ncurses_insstr' => ['int', 'text'=>'string'],
'ncurses_instr' => ['int', 'buffer'=>'string'],
'ncurses_isendwin' => ['bool'],
'ncurses_keyok' => ['int', 'keycode'=>'int', 'enable'=>'bool'],
'ncurses_keypad' => ['int', 'window'=>'resource', 'bf'=>'bool'],
'ncurses_killchar' => ['string'],
'ncurses_longname' => ['string'],
'ncurses_meta' => ['int', 'window'=>'resource', '_8bit'=>'bool'],
'ncurses_mouse_trafo' => ['bool', 'y'=>'int', 'x'=>'int', 'toscreen'=>'bool'],
'ncurses_mouseinterval' => ['int', 'milliseconds'=>'int'],
'ncurses_mousemask' => ['int', 'newmask'=>'int', 'oldmask'=>'int'],
'ncurses_move' => ['int', 'y'=>'int', 'x'=>'int'],
'ncurses_move_panel' => ['int', 'panel'=>'resource', 'startx'=>'int', 'starty'=>'int'],
'ncurses_mvaddch' => ['int', 'y'=>'int', 'x'=>'int', 'c'=>'int'],
'ncurses_mvaddchnstr' => ['int', 'y'=>'int', 'x'=>'int', 's'=>'string', 'n'=>'int'],
'ncurses_mvaddchstr' => ['int', 'y'=>'int', 'x'=>'int', 's'=>'string'],
'ncurses_mvaddnstr' => ['int', 'y'=>'int', 'x'=>'int', 's'=>'string', 'n'=>'int'],
'ncurses_mvaddstr' => ['int', 'y'=>'int', 'x'=>'int', 's'=>'string'],
'ncurses_mvcur' => ['int', 'old_y'=>'int', 'old_x'=>'int', 'new_y'=>'int', 'new_x'=>'int'],
'ncurses_mvdelch' => ['int', 'y'=>'int', 'x'=>'int'],
'ncurses_mvgetch' => ['int', 'y'=>'int', 'x'=>'int'],
'ncurses_mvhline' => ['int', 'y'=>'int', 'x'=>'int', 'attrchar'=>'int', 'n'=>'int'],
'ncurses_mvinch' => ['int', 'y'=>'int', 'x'=>'int'],
'ncurses_mvvline' => ['int', 'y'=>'int', 'x'=>'int', 'attrchar'=>'int', 'n'=>'int'],
'ncurses_mvwaddstr' => ['int', 'window'=>'resource', 'y'=>'int', 'x'=>'int', 'text'=>'string'],
'ncurses_napms' => ['int', 'milliseconds'=>'int'],
'ncurses_new_panel' => ['resource', 'window'=>'resource'],
'ncurses_newpad' => ['resource', 'rows'=>'int', 'cols'=>'int'],
'ncurses_newwin' => ['resource', 'rows'=>'int', 'cols'=>'int', 'y'=>'int', 'x'=>'int'],
'ncurses_nl' => ['bool'],
'ncurses_nocbreak' => ['bool'],
'ncurses_noecho' => ['bool'],
'ncurses_nonl' => ['bool'],
'ncurses_noqiflush' => ['void'],
'ncurses_noraw' => ['bool'],
'ncurses_pair_content' => ['int', 'pair'=>'int', 'f'=>'int', 'b'=>'int'],
'ncurses_panel_above' => ['resource', 'panel'=>'resource'],
'ncurses_panel_below' => ['resource', 'panel'=>'resource'],
'ncurses_panel_window' => ['resource', 'panel'=>'resource'],
'ncurses_pnoutrefresh' => ['int', 'pad'=>'resource', 'pminrow'=>'int', 'pmincol'=>'int', 'sminrow'=>'int', 'smincol'=>'int', 'smaxrow'=>'int', 'smaxcol'=>'int'],
'ncurses_prefresh' => ['int', 'pad'=>'resource', 'pminrow'=>'int', 'pmincol'=>'int', 'sminrow'=>'int', 'smincol'=>'int', 'smaxrow'=>'int', 'smaxcol'=>'int'],
'ncurses_putp' => ['int', 'text'=>'string'],
'ncurses_qiflush' => ['void'],
'ncurses_raw' => ['bool'],
'ncurses_refresh' => ['int', 'ch'=>'int'],
'ncurses_replace_panel' => ['int', 'panel'=>'resource', 'window'=>'resource'],
'ncurses_reset_prog_mode' => ['int'],
'ncurses_reset_shell_mode' => ['int'],
'ncurses_resetty' => ['bool'],
'ncurses_savetty' => ['bool'],
'ncurses_scr_dump' => ['int', 'filename'=>'string'],
'ncurses_scr_init' => ['int', 'filename'=>'string'],
'ncurses_scr_restore' => ['int', 'filename'=>'string'],
'ncurses_scr_set' => ['int', 'filename'=>'string'],
'ncurses_scrl' => ['int', 'count'=>'int'],
'ncurses_show_panel' => ['int', 'panel'=>'resource'],
'ncurses_slk_attr' => ['int'],
'ncurses_slk_attroff' => ['int', 'intarg'=>'int'],
'ncurses_slk_attron' => ['int', 'intarg'=>'int'],
'ncurses_slk_attrset' => ['int', 'intarg'=>'int'],
'ncurses_slk_clear' => ['bool'],
'ncurses_slk_color' => ['int', 'intarg'=>'int'],
'ncurses_slk_init' => ['bool', 'format'=>'int'],
'ncurses_slk_noutrefresh' => ['bool'],
'ncurses_slk_refresh' => ['int'],
'ncurses_slk_restore' => ['int'],
'ncurses_slk_set' => ['bool', 'labelnr'=>'int', 'label'=>'string', 'format'=>'int'],
'ncurses_slk_touch' => ['int'],
'ncurses_standend' => ['int'],
'ncurses_standout' => ['int'],
'ncurses_start_color' => ['int'],
'ncurses_termattrs' => ['bool'],
'ncurses_termname' => ['string'],
'ncurses_timeout' => ['void', 'millisec'=>'int'],
'ncurses_top_panel' => ['int', 'panel'=>'resource'],
'ncurses_typeahead' => ['int', 'fd'=>'int'],
'ncurses_ungetch' => ['int', 'keycode'=>'int'],
'ncurses_ungetmouse' => ['bool', 'mevent'=>'array'],
'ncurses_update_panels' => ['void'],
'ncurses_use_default_colors' => ['bool'],
'ncurses_use_env' => ['void', 'flag'=>'bool'],
'ncurses_use_extended_names' => ['int', 'flag'=>'bool'],
'ncurses_vidattr' => ['int', 'intarg'=>'int'],
'ncurses_vline' => ['int', 'charattr'=>'int', 'n'=>'int'],
'ncurses_waddch' => ['int', 'window'=>'resource', 'ch'=>'int'],
'ncurses_waddstr' => ['int', 'window'=>'resource', 'str'=>'string', 'n='=>'int'],
'ncurses_wattroff' => ['int', 'window'=>'resource', 'attrs'=>'int'],
'ncurses_wattron' => ['int', 'window'=>'resource', 'attrs'=>'int'],
'ncurses_wattrset' => ['int', 'window'=>'resource', 'attrs'=>'int'],
'ncurses_wborder' => ['int', 'window'=>'resource', 'left'=>'int', 'right'=>'int', 'top'=>'int', 'bottom'=>'int', 'tl_corner'=>'int', 'tr_corner'=>'int', 'bl_corner'=>'int', 'br_corner'=>'int'],
'ncurses_wclear' => ['int', 'window'=>'resource'],
'ncurses_wcolor_set' => ['int', 'window'=>'resource', 'color_pair'=>'int'],
'ncurses_werase' => ['int', 'window'=>'resource'],
'ncurses_wgetch' => ['int', 'window'=>'resource'],
'ncurses_whline' => ['int', 'window'=>'resource', 'charattr'=>'int', 'n'=>'int'],
'ncurses_wmouse_trafo' => ['bool', 'window'=>'resource', 'y'=>'int', 'x'=>'int', 'toscreen'=>'bool'],
'ncurses_wmove' => ['int', 'window'=>'resource', 'y'=>'int', 'x'=>'int'],
'ncurses_wnoutrefresh' => ['int', 'window'=>'resource'],
'ncurses_wrefresh' => ['int', 'window'=>'resource'],
'ncurses_wstandend' => ['int', 'window'=>'resource'],
'ncurses_wstandout' => ['int', 'window'=>'resource'],
'ncurses_wvline' => ['int', 'window'=>'resource', 'charattr'=>'int', 'n'=>'int'],
'newrelic_add_custom_parameter' => ['bool', 'key'=>'string', 'value'=>''],
'newrelic_add_custom_tracer' => ['bool', 'function_name'=>'string'],
'newrelic_background_job' => ['void', 'flag='=>'bool'],
'newrelic_capture_params' => ['void', 'enable='=>'bool'],
'newrelic_custom_metric' => ['bool', 'metric_name'=>'string', 'value'=>'float'],
'newrelic_disable_autorum' => ['bool'],
'newrelic_end_of_transaction' => ['void'],
'newrelic_end_transaction' => ['bool', 'ignore='=>'bool'],
'newrelic_get_browser_timing_footer' => ['string', 'include_tags='=>'bool'],
'newrelic_get_browser_timing_header' => ['string', 'include_tags='=>'bool'],
'newrelic_ignore_apdex' => ['void'],
'newrelic_ignore_transaction' => ['void'],
'newrelic_name_transaction' => ['bool', 'name'=>'string'],
'newrelic_notice_error' => ['void', 'message'=>'string', 'exception='=>'Exception|Throwable'],
'newrelic_notice_error\'1' => ['void', 'unused_1'=>'string', 'message'=>'string', 'unused_2'=>'string', 'unused_3'=>'int', 'unused_4='=>''],
'newrelic_record_custom_event' => ['void', 'name'=>'string', 'attributes'=>'array'],
'newrelic_record_datastore_segment' => ['mixed', 'func'=>'callable', 'parameters'=>'array'],
'newrelic_set_appname' => ['bool', 'name'=>'string', 'license='=>'string', 'xmit='=>'bool'],
'newrelic_set_user_attributes' => ['bool', 'user'=>'string', 'account'=>'string', 'product'=>'string'],
'newrelic_start_transaction' => ['bool', 'appname'=>'string', 'license='=>'string'],
'newt_bell' => ['void'],
'newt_button' => ['resource', 'left'=>'int', 'top'=>'int', 'text'=>'string'],
'newt_button_bar' => ['resource', 'buttons'=>'array'],
'newt_centered_window' => ['int', 'width'=>'int', 'height'=>'int', 'title='=>'string'],
'newt_checkbox' => ['resource', 'left'=>'int', 'top'=>'int', 'text'=>'string', 'def_value'=>'string', 'seq='=>'string'],
'newt_checkbox_get_value' => ['string', 'checkbox'=>'resource'],
'newt_checkbox_set_flags' => ['void', 'checkbox'=>'resource', 'flags'=>'int', 'sense'=>'int'],
'newt_checkbox_set_value' => ['void', 'checkbox'=>'resource', 'value'=>'string'],
'newt_checkbox_tree' => ['resource', 'left'=>'int', 'top'=>'int', 'height'=>'int', 'flags='=>'int'],
'newt_checkbox_tree_add_item' => ['void', 'checkboxtree'=>'resource', 'text'=>'string', 'data'=>'mixed', 'flags'=>'int', 'index'=>'int', '...args='=>'int'],
'newt_checkbox_tree_find_item' => ['array', 'checkboxtree'=>'resource', 'data'=>'mixed'],
'newt_checkbox_tree_get_current' => ['mixed', 'checkboxtree'=>'resource'],
'newt_checkbox_tree_get_entry_value' => ['string', 'checkboxtree'=>'resource', 'data'=>'mixed'],
'newt_checkbox_tree_get_multi_selection' => ['array', 'checkboxtree'=>'resource', 'seqnum'=>'string'],
'newt_checkbox_tree_get_selection' => ['array', 'checkboxtree'=>'resource'],
'newt_checkbox_tree_multi' => ['resource', 'left'=>'int', 'top'=>'int', 'height'=>'int', 'seq'=>'string', 'flags='=>'int'],
'newt_checkbox_tree_set_current' => ['void', 'checkboxtree'=>'resource', 'data'=>'mixed'],
'newt_checkbox_tree_set_entry' => ['void', 'checkboxtree'=>'resource', 'data'=>'mixed', 'text'=>'string'],
'newt_checkbox_tree_set_entry_value' => ['void', 'checkboxtree'=>'resource', 'data'=>'mixed', 'value'=>'string'],
'newt_checkbox_tree_set_width' => ['void', 'checkbox_tree'=>'resource', 'width'=>'int'],
'newt_clear_key_buffer' => ['void'],
'newt_cls' => ['void'],
'newt_compact_button' => ['resource', 'left'=>'int', 'top'=>'int', 'text'=>'string'],
'newt_component_add_callback' => ['void', 'component'=>'resource', 'func_name'=>'mixed', 'data'=>'mixed'],
'newt_component_takes_focus' => ['void', 'component'=>'resource', 'takes_focus'=>'bool'],
'newt_create_grid' => ['resource', 'cols'=>'int', 'rows'=>'int'],
'newt_cursor_off' => ['void'],
'newt_cursor_on' => ['void'],
'newt_delay' => ['void', 'microseconds'=>'int'],
'newt_draw_form' => ['void', 'form'=>'resource'],
'newt_draw_root_text' => ['void', 'left'=>'int', 'top'=>'int', 'text'=>'string'],
'newt_entry' => ['resource', 'left'=>'int', 'top'=>'int', 'width'=>'int', 'init_value='=>'string', 'flags='=>'int'],
'newt_entry_get_value' => ['string', 'entry'=>'resource'],
'newt_entry_set' => ['void', 'entry'=>'resource', 'value'=>'string', 'cursor_at_end='=>'bool'],
'newt_entry_set_filter' => ['void', 'entry'=>'resource', 'filter'=>'callable', 'data'=>'mixed'],
'newt_entry_set_flags' => ['void', 'entry'=>'resource', 'flags'=>'int', 'sense'=>'int'],
'newt_finished' => ['int'],
'newt_form' => ['resource', 'vert_bar='=>'resource', 'help='=>'string', 'flags='=>'int'],
'newt_form_add_component' => ['void', 'form'=>'resource', 'component'=>'resource'],
'newt_form_add_components' => ['void', 'form'=>'resource', 'components'=>'array'],
'newt_form_add_hot_key' => ['void', 'form'=>'resource', 'key'=>'int'],
'newt_form_destroy' => ['void', 'form'=>'resource'],
'newt_form_get_current' => ['resource', 'form'=>'resource'],
'newt_form_run' => ['void', 'form'=>'resource', 'exit_struct'=>'array'],
'newt_form_set_background' => ['void', 'from'=>'resource', 'background'=>'int'],
'newt_form_set_height' => ['void', 'form'=>'resource', 'height'=>'int'],
'newt_form_set_size' => ['void', 'form'=>'resource'],
'newt_form_set_timer' => ['void', 'form'=>'resource', 'milliseconds'=>'int'],
'newt_form_set_width' => ['void', 'form'=>'resource', 'width'=>'int'],
'newt_form_watch_fd' => ['void', 'form'=>'resource', 'stream'=>'resource', 'flags='=>'int'],
'newt_get_screen_size' => ['void', 'cols'=>'int', 'rows'=>'int'],
'newt_grid_add_components_to_form' => ['void', 'grid'=>'resource', 'form'=>'resource', 'recurse'=>'bool'],
'newt_grid_basic_window' => ['resource', 'text'=>'resource', 'middle'=>'resource', 'buttons'=>'resource'],
'newt_grid_free' => ['void', 'grid'=>'resource', 'recurse'=>'bool'],
'newt_grid_get_size' => ['void', 'grid'=>'resource', 'width'=>'int', 'height'=>'int'],
'newt_grid_h_close_stacked' => ['resource', 'element1_type'=>'int', 'element1'=>'resource', '...args='=>'resource'],
'newt_grid_h_stacked' => ['resource', 'element1_type'=>'int', 'element1'=>'resource', '...args='=>'resource'],
'newt_grid_place' => ['void', 'grid'=>'resource', 'left'=>'int', 'top'=>'int'],
'newt_grid_set_field' => ['void', 'grid'=>'resource', 'col'=>'int', 'row'=>'int', 'type'=>'int', 'val'=>'resource', 'pad_left'=>'int', 'pad_top'=>'int', 'pad_right'=>'int', 'pad_bottom'=>'int', 'anchor'=>'int', 'flags='=>'int'],
'newt_grid_simple_window' => ['resource', 'text'=>'resource', 'middle'=>'resource', 'buttons'=>'resource'],
'newt_grid_v_close_stacked' => ['resource', 'element1_type'=>'int', 'element1'=>'resource', '...args='=>'resource'],
'newt_grid_v_stacked' => ['resource', 'element1_type'=>'int', 'element1'=>'resource', '...args='=>'resource'],
'newt_grid_wrapped_window' => ['void', 'grid'=>'resource', 'title'=>'string'],
'newt_grid_wrapped_window_at' => ['void', 'grid'=>'resource', 'title'=>'string', 'left'=>'int', 'top'=>'int'],
'newt_init' => ['int'],
'newt_label' => ['resource', 'left'=>'int', 'top'=>'int', 'text'=>'string'],
'newt_label_set_text' => ['void', 'label'=>'resource', 'text'=>'string'],
'newt_listbox' => ['resource', 'left'=>'int', 'top'=>'int', 'height'=>'int', 'flags='=>'int'],
'newt_listbox_append_entry' => ['void', 'listbox'=>'resource', 'text'=>'string', 'data'=>'mixed'],
'newt_listbox_clear' => ['void', 'listobx'=>'resource'],
'newt_listbox_clear_selection' => ['void', 'listbox'=>'resource'],
'newt_listbox_delete_entry' => ['void', 'listbox'=>'resource', 'key'=>'mixed'],
'newt_listbox_get_current' => ['string', 'listbox'=>'resource'],
'newt_listbox_get_selection' => ['array', 'listbox'=>'resource'],
'newt_listbox_insert_entry' => ['void', 'listbox'=>'resource', 'text'=>'string', 'data'=>'mixed', 'key'=>'mixed'],
'newt_listbox_item_count' => ['int', 'listbox'=>'resource'],
'newt_listbox_select_item' => ['void', 'listbox'=>'resource', 'key'=>'mixed', 'sense'=>'int'],
'newt_listbox_set_current' => ['void', 'listbox'=>'resource', 'num'=>'int'],
'newt_listbox_set_current_by_key' => ['void', 'listbox'=>'resource', 'key'=>'mixed'],
'newt_listbox_set_data' => ['void', 'listbox'=>'resource', 'num'=>'int', 'data'=>'mixed'],
'newt_listbox_set_entry' => ['void', 'listbox'=>'resource', 'num'=>'int', 'text'=>'string'],
'newt_listbox_set_width' => ['void', 'listbox'=>'resource', 'width'=>'int'],
'newt_listitem' => ['resource', 'left'=>'int', 'top'=>'int', 'text'=>'string', 'is_default'=>'bool', 'prev_item'=>'resource', 'data'=>'mixed', 'flags='=>'int'],
'newt_listitem_get_data' => ['mixed', 'item'=>'resource'],
'newt_listitem_set' => ['void', 'item'=>'resource', 'text'=>'string'],
'newt_open_window' => ['int', 'left'=>'int', 'top'=>'int', 'width'=>'int', 'height'=>'int', 'title='=>'string'],
'newt_pop_help_line' => ['void'],
'newt_pop_window' => ['void'],
'newt_push_help_line' => ['void', 'text='=>'string'],
'newt_radio_get_current' => ['resource', 'set_member'=>'resource'],
'newt_radiobutton' => ['resource', 'left'=>'int', 'top'=>'int', 'text'=>'string', 'is_default'=>'bool', 'prev_button='=>'resource'],
'newt_redraw_help_line' => ['void'],
'newt_reflow_text' => ['string', 'text'=>'string', 'width'=>'int', 'flex_down'=>'int', 'flex_up'=>'int', 'actual_width'=>'int', 'actual_height'=>'int'],
'newt_refresh' => ['void'],
'newt_resize_screen' => ['void', 'redraw='=>'bool'],
'newt_resume' => ['void'],
'newt_run_form' => ['resource', 'form'=>'resource'],
'newt_scale' => ['resource', 'left'=>'int', 'top'=>'int', 'width'=>'int', 'full_value'=>'int'],
'newt_scale_set' => ['void', 'scale'=>'resource', 'amount'=>'int'],
'newt_scrollbar_set' => ['void', 'scrollbar'=>'resource', 'where'=>'int', 'total'=>'int'],
'newt_set_help_callback' => ['void', 'function'=>'mixed'],
'newt_set_suspend_callback' => ['void', 'function'=>'callable', 'data'=>'mixed'],
'newt_suspend' => ['void'],
'newt_textbox' => ['resource', 'left'=>'int', 'top'=>'int', 'width'=>'int', 'height'=>'int', 'flags='=>'int'],
'newt_textbox_get_num_lines' => ['int', 'textbox'=>'resource'],
'newt_textbox_reflowed' => ['resource', 'left'=>'int', 'top'=>'int', 'text'=>'char', 'width'=>'int', 'flex_down'=>'int', 'flex_up'=>'int', 'flags='=>'int'],
'newt_textbox_set_height' => ['void', 'textbox'=>'resource', 'height'=>'int'],
'newt_textbox_set_text' => ['void', 'textbox'=>'resource', 'text'=>'string'],
'newt_vertical_scrollbar' => ['resource', 'left'=>'int', 'top'=>'int', 'height'=>'int', 'normal_colorset='=>'int', 'thumb_colorset='=>'int'],
'newt_wait_for_key' => ['void'],
'newt_win_choice' => ['int', 'title'=>'string', 'button1_text'=>'string', 'button2_text'=>'string', 'format'=>'string', 'args='=>'mixed', '...args='=>'mixed'],
'newt_win_entries' => ['int', 'title'=>'string', 'text'=>'string', 'suggested_width'=>'int', 'flex_down'=>'int', 'flex_up'=>'int', 'data_width'=>'int', 'items'=>'array', 'button1'=>'string', '...args='=>'string'],
'newt_win_menu' => ['int', 'title'=>'string', 'text'=>'string', 'suggestedwidth'=>'int', 'flexdown'=>'int', 'flexup'=>'int', 'maxlistheight'=>'int', 'items'=>'array', 'listitem'=>'int', 'button1='=>'string', '...args='=>'string'],
'newt_win_message' => ['void', 'title'=>'string', 'button_text'=>'string', 'format'=>'string', 'args='=>'mixed', '...args='=>'mixed'],
'newt_win_messagev' => ['void', 'title'=>'string', 'button_text'=>'string', 'format'=>'string', 'args'=>'array'],
'newt_win_ternary' => ['int', 'title'=>'string', 'button1_text'=>'string', 'button2_text'=>'string', 'button3_text'=>'string', 'format'=>'string', 'args='=>'mixed', '...args='=>'mixed'],
'next' => ['mixed', '&rw_array_arg'=>'array|object'],
'ngettext' => ['string', 'msgid1'=>'string', 'msgid2'=>'string', 'n'=>'int'],
'nl2br' => ['string', 'str'=>'string', 'is_xhtml='=>'bool'],
'nl_langinfo' => ['string', 'item'=>'int'],
'NoRewindIterator::__construct' => ['void', 'it'=>'iterator'],
'NoRewindIterator::current' => ['mixed'],
'NoRewindIterator::getInnerIterator' => ['iterator'],
'NoRewindIterator::key' => ['mixed'],
'NoRewindIterator::next' => ['void'],
'NoRewindIterator::rewind' => ['void'],
'NoRewindIterator::valid' => ['bool'],
'Normalizer::isNormalized' => ['bool', 'input'=>'string', 'form='=>'int'],
'Normalizer::normalize' => ['string', 'input'=>'string', 'form='=>'int'],
'normalizer_is_normalized' => ['bool', 'input'=>'string', 'form='=>'int'],
'normalizer_normalize' => ['string', 'input'=>'string', 'form='=>'int'],
'notes_body' => ['array', 'server'=>'string', 'mailbox'=>'string', 'msg_number'=>'int'],
'notes_copy_db' => ['bool', 'from_database_name'=>'string', 'to_database_name'=>'string'],
'notes_create_db' => ['bool', 'database_name'=>'string'],
'notes_create_note' => ['bool', 'database_name'=>'string', 'form_name'=>'string'],
'notes_drop_db' => ['bool', 'database_name'=>'string'],
'notes_find_note' => ['int', 'database_name'=>'string', 'name'=>'string', 'type='=>'string'],
'notes_header_info' => ['object', 'server'=>'string', 'mailbox'=>'string', 'msg_number'=>'int'],
'notes_list_msgs' => ['bool', 'db'=>'string'],
'notes_mark_read' => ['bool', 'database_name'=>'string', 'user_name'=>'string', 'note_id'=>'string'],
'notes_mark_unread' => ['bool', 'database_name'=>'string', 'user_name'=>'string', 'note_id'=>'string'],
'notes_nav_create' => ['bool', 'database_name'=>'string', 'name'=>'string'],
'notes_search' => ['array', 'database_name'=>'string', 'keywords'=>'string'],
'notes_unread' => ['array', 'database_name'=>'string', 'user_name'=>'string'],
'notes_version' => ['float', 'database_name'=>'string'],
'nsapi_request_headers' => ['array'],
'nsapi_response_headers' => ['array'],
'nsapi_virtual' => ['bool', 'uri'=>'string'],
'nthmac' => ['string', 'clent'=>'string', 'data'=>'string'],
'number_format' => ['string', 'number'=>'float', 'num_decimal_places='=>'int'],
'number_format\'1' => ['string', 'number'=>'float', 'num_decimal_places'=>'int', 'dec_separator'=>'string', 'thousands_separator'=>'string'],
'NumberFormatter::__construct' => ['void', 'locale'=>'string', 'style'=>'int', 'pattern='=>'string'],
'NumberFormatter::create' => ['NumberFormatter', 'locale'=>'string', 'style'=>'int', 'pattern='=>'string'],
'NumberFormatter::format' => ['string', 'num'=>'', 'type='=>'int'],
'NumberFormatter::formatCurrency' => ['string', 'num'=>'float', 'currency'=>'string'],
'NumberFormatter::getAttribute' => ['int', 'attr'=>'int'],
'NumberFormatter::getErrorCode' => ['int'],
'NumberFormatter::getErrorMessage' => ['string'],
'NumberFormatter::getLocale' => ['string', 'type='=>'int'],
'NumberFormatter::getPattern' => ['string'],
'NumberFormatter::getSymbol' => ['string', 'attr'=>'int'],
'NumberFormatter::getTextAttribute' => ['string', 'attr'=>'int'],
'NumberFormatter::parse' => ['float|false', 'str'=>'string', 'type='=>'int', '&rw_position='=>'int'],
'NumberFormatter::parseCurrency' => ['float', 'str'=>'string', '&w_currency'=>'string', '&rw_position='=>'int'],
'NumberFormatter::setAttribute' => ['bool', 'attr'=>'int', 'value'=>''],
'NumberFormatter::setPattern' => ['bool', 'pattern'=>'string'],
'NumberFormatter::setSymbol' => ['bool', 'attr'=>'int', 'symbol'=>'string'],
'NumberFormatter::setTextAttribute' => ['bool', 'attr'=>'int', 'value'=>'string'],
'numfmt_create' => ['NumberFormatter', 'locale'=>'string', 'style'=>'int', 'pattern='=>'string'],
'numfmt_format' => ['string', 'fmt'=>'numberformatter', 'value='=>'float', 'type='=>'int'],
'numfmt_format_currency' => ['string|false', 'fmt'=>'numberformatter', 'value'=>'float', 'currency'=>'string'],
'numfmt_get_attribute' => ['int', 'fmt'=>'numberformatter', 'attr'=>'int'],
'numfmt_get_error_code' => ['int', 'fmt'=>'numberformatter'],
'numfmt_get_error_message' => ['string', 'fmt'=>'numberformatter'],
'numfmt_get_locale' => ['string', 'fmt'=>'numberformatter', 'type='=>'int'],
'numfmt_get_pattern' => ['string', 'fmt'=>'numberformatter'],
'numfmt_get_symbol' => ['string', 'fmt'=>'numberformatter', 'attr'=>'int'],
'numfmt_get_text_attribute' => ['string', 'fmt'=>'numberformatter', 'attr'=>'int'],
'numfmt_parse' => ['float|false', 'fmt'=>'numberformatter', 'value'=>'string', 'type='=>'int', '&rw_position='=>'int'],
'numfmt_parse_currency' => ['float|false', 'fmt'=>'numberformatter', 'value'=>'string', '&w_currency'=>'string', '&rw_position='=>'int'],
'numfmt_set_attribute' => ['bool', 'fmt'=>'numberformatter', 'attr'=>'int', 'value'=>'int'],
'numfmt_set_pattern' => ['bool', 'fmt'=>'numberformatter', 'pattern'=>'string'],
'numfmt_set_symbol' => ['bool', 'fmt'=>'numberformatter', 'attr'=>'int', 'value'=>'string'],
'numfmt_set_text_attribute' => ['bool', 'fmt'=>'numberformatter', 'attr'=>'int', 'value'=>'string'],
'OAuth::__construct' => ['void', 'consumer_key'=>'string', 'consumer_secret'=>'string', 'signature_method='=>'string', 'auth_type='=>'int'],
'OAuth::__destruct' => [''],
'OAuth::disableDebug' => ['bool'],
'OAuth::disableRedirects' => ['bool'],
'OAuth::disableSSLChecks' => ['bool'],
'OAuth::enableDebug' => ['bool'],
'OAuth::enableRedirects' => ['bool'],
'OAuth::enableSSLChecks' => ['bool'],
'OAuth::fetch' => ['mixed', 'protected_resource_url'=>'string', 'extra_parameters='=>'array', 'http_method='=>'string', 'http_headers='=>'array'],
'OAuth::generateSignature' => ['string', 'http_method'=>'string', 'url'=>'string', 'extra_parameters='=>'mixed'],
'OAuth::getAccessToken' => ['array|false', 'access_token_url'=>'string', 'auth_session_handle='=>'string', 'verifier_token='=>'string'],
'OAuth::getCAPath' => ['array'],
'OAuth::getLastResponse' => ['string'],
'OAuth::getLastResponseHeaders' => ['string|false'],
'OAuth::getLastResponseInfo' => ['array'],
'OAuth::getRequestHeader' => ['string|false', 'http_method'=>'string', 'url'=>'string', 'extra_parameters='=>'mixed'],
'OAuth::getRequestToken' => ['array|false', 'request_token_url'=>'string', 'callback_url='=>'string'],
'OAuth::setAuthType' => ['bool', 'auth_type'=>'int'],
'OAuth::setCAPath' => ['mixed', 'ca_path='=>'string', 'ca_info='=>'string'],
'OAuth::setNonce' => ['mixed', 'nonce'=>'string'],
'OAuth::setRequestEngine' => ['void', 'reqengine'=>'int'],
'OAuth::setRSACertificate' => ['mixed', 'cert'=>'string'],
'OAuth::setSSLChecks' => ['bool', 'sslcheck'=>'int'],
'OAuth::setTimestamp' => ['mixed', 'timestamp'=>'string'],
'OAuth::setToken' => ['bool', 'token'=>'string', 'token_secret'=>'string'],
'OAuth::setVersion' => ['bool', 'version'=>'string'],
'oauth_get_sbs' => ['string', 'http_method'=>'string', 'uri'=>'string', 'request_parameters='=>'array'],
'oauth_urlencode' => ['string', 'uri'=>'string'],
'OAuthProvider::__construct' => ['void', 'params_array='=>'array'],
'OAuthProvider::addRequiredParameter' => ['bool', 'req_params'=>'string'],
'OAuthProvider::callconsumerHandler' => ['void'],
'OAuthProvider::callTimestampNonceHandler' => ['void'],
'OAuthProvider::calltokenHandler' => ['void'],
'OAuthProvider::checkOAuthRequest' => ['void', 'uri='=>'string', 'method='=>'string'],
'OAuthProvider::consumerHandler' => ['void', 'callback_function'=>'callable'],
'OAuthProvider::generateToken' => ['string', 'size'=>'int', 'strong='=>'bool'],
'OAuthProvider::is2LeggedEndpoint' => ['void', 'params_array'=>'mixed'],
'OAuthProvider::isRequestTokenEndpoint' => ['void', 'will_issue_request_token'=>'bool'],
'OAuthProvider::removeRequiredParameter' => ['bool', 'req_params'=>'string'],
'OAuthProvider::reportProblem' => ['string', 'oauthexception'=>'string', 'send_headers='=>'bool'],
'OAuthProvider::setParam' => ['bool', 'param_key'=>'string', 'param_val='=>'mixed'],
'OAuthProvider::setRequestTokenPath' => ['bool', 'path'=>'string'],
'OAuthProvider::timestampNonceHandler' => ['void', 'callback_function'=>'callable'],
'OAuthProvider::tokenHandler' => ['void', 'callback_function'=>'callable'],
'ob_clean' => ['bool'],
'ob_deflatehandler' => ['string', 'data'=>'string', 'mode'=>'int'],
'ob_end_clean' => ['bool'],
'ob_end_flush' => ['bool'],
'ob_etaghandler' => ['string', 'data'=>'string', 'mode'=>'int'],
'ob_flush' => ['bool'],
'ob_get_clean' => ['string|false'],
'ob_get_contents' => ['string|false'],
'ob_get_flush' => ['string|false'],
'ob_get_length' => ['int|false'],
'ob_get_level' => ['int'],
'ob_get_status' => ['array', 'full_status='=>'bool'],
'ob_gzhandler' => ['string|false', 'data'=>'string', 'flags'=>'int'],
'ob_iconv_handler' => ['string', 'contents'=>'string', 'status'=>'int'],
'ob_implicit_flush' => ['void', 'flag='=>'int'],
'ob_inflatehandler' => ['string', 'data'=>'string', 'mode'=>'int'],
'ob_list_handlers' => ['false|array'],
'ob_start' => ['bool', 'user_function='=>'string|array|?callable', 'chunk_size='=>'int', 'flags='=>'int'],
'ob_tidyhandler' => ['string', 'input'=>'string', 'mode='=>'int'],
'OCI-Collection::assignElem' => ['bool', 'index'=>'int', 'value'=>''],
'OCI-Collection::getElem' => ['', 'index'=>'int'],
'OCI-Lob::append' => ['bool', 'lob_from'=>'OCI-Lob'],
'OCI-Lob::close' => ['bool'],
'OCI-Lob::eof' => ['bool'],
'OCI-Lob::erase' => ['int', 'offset='=>'int', 'length='=>'int'],
'OCI-Lob::export' => ['bool', 'filename'=>'string', 'start='=>'int', 'length='=>'int'],
'OCI-Lob::flush' => ['bool', 'flag='=>'int'],
'OCI-Lob::free' => ['bool'],
'OCI-Lob::getBuffering' => ['bool'],
'OCI-Lob::import' => ['bool', 'filename'=>'string'],
'OCI-Lob::load' => ['string'],
'OCI-Lob::read' => ['string', 'length'=>'int'],
'OCI-Lob::rewind' => ['bool'],
'OCI-Lob::save' => ['bool', 'data'=>'string', 'offset='=>'int'],
'OCI-Lob::seek' => ['bool', 'offset'=>'int', 'whence='=>'int'],
'OCI-Lob::setBuffering' => ['bool', 'on_off'=>'bool'],
'OCI-Lob::size' => ['int'],
'OCI-Lob::tell' => ['int'],
'OCI-Lob::truncate' => ['bool', 'length='=>'int'],
'OCI-Lob::write' => ['int', 'data'=>'string', 'length='=>'int'],
'OCI-Lob::writeTemporary' => ['bool', 'data'=>'string', 'lob_type='=>'int'],
'oci_bind_array_by_name' => ['bool', 'stmt'=>'resource', 'name'=>'string', '&rw_var'=>'array', 'max_table_length'=>'int', 'max_item_length='=>'int', 'type='=>'int'],
'oci_bind_by_name' => ['bool', 'stmt'=>'resource', 'name'=>'string', '&rw_var'=>'mixed', 'maxlength='=>'int', 'type='=>'int'],
'oci_cancel' => ['bool', 'stmt'=>'resource'],
'oci_client_version' => ['string'],
'oci_close' => ['bool', 'connection'=>'resource'],
'OCI-Collection::append' => ['bool', 'value'=>'mixed'],
'OCI-Collection::assign' => ['bool', 'from'=>'OCI-Collection'],
'OCI-Collection::assignelem' => ['bool', 'index'=>'int', 'value'=>'mixed'],
'OCI-Collection::free' => ['bool'],
'OCI-Collection::getelem' => ['mixed', 'index'=>'int'],
'OCI-Collection::max' => ['int'],
'OCI-Collection::size' => ['int'],
'OCI-Collection::trim' => ['bool', 'num'=>'int'],
'oci_collection_append' => ['bool', 'value'=>'string'],
'oci_collection_assign' => ['bool', 'from'=>'OCI-Collection'],
'oci_collection_element_assign' => ['bool', 'index'=>'int', 'val'=>'string'],
'oci_collection_element_get' => ['string', 'ndx'=>'int'],
'oci_collection_max' => ['int'],
'oci_collection_size' => ['int'],
'oci_collection_trim' => ['bool', 'num'=>'int'],
'oci_commit' => ['bool', 'connection'=>'resource'],
'oci_connect' => ['resource', 'user'=>'string', 'pass'=>'string', 'db='=>'string', 'charset='=>'string', 'session_mode='=>'int'],
'oci_define_by_name' => ['bool', 'stmt'=>'resource', 'name'=>'string', '&w_var'=>'mixed', 'type='=>'int'],
'oci_error' => ['array', 'resource='=>'resource'],
'oci_execute' => ['bool', 'stmt'=>'resource', 'mode='=>'int'],
'oci_fetch' => ['bool', 'stmt'=>'resource'],
'oci_fetch_all' => ['int', 'stmt'=>'resource', '&w_output'=>'array', 'skip='=>'int', 'maxrows='=>'int', 'flags='=>'int'],
'oci_fetch_array' => ['array', 'stmt'=>'resource', 'mode='=>'int'],
'oci_fetch_assoc' => ['array', 'stmt'=>'resource'],
'oci_fetch_object' => ['object', 'stmt'=>'resource'],
'oci_fetch_row' => ['array', 'stmt'=>'resource'],
'oci_field_is_null' => ['bool', 'stmt'=>'resource', 'col'=>'mixed'],
'oci_field_name' => ['string', 'stmt'=>'resource', 'col'=>'mixed'],
'oci_field_precision' => ['int', 'stmt'=>'resource', 'col'=>'mixed'],
'oci_field_scale' => ['int', 'stmt'=>'resource', 'col'=>'mixed'],
'oci_field_size' => ['int', 'stmt'=>'resource', 'col'=>'mixed'],
'oci_field_type' => ['mixed', 'stmt'=>'resource', 'col'=>'mixed'],
'oci_field_type_raw' => ['int', 'stmt'=>'resource', 'col'=>'mixed'],
'oci_free_collection' => ['bool'],
'oci_free_cursor' => ['bool', 'stmt'=>'resource'],
'oci_free_descriptor' => ['bool'],
'oci_free_statement' => ['bool', 'stmt'=>'resource'],
'oci_get_implicit' => ['bool', 'stmt'=>''],
'oci_get_implicit_resultset' => ['resource', 'statement'=>'resource'],
'oci_internal_debug' => ['void', 'onoff'=>'bool'],
'OCI-Lob::getbuffering' => ['bool'],
'OCI-Lob::savefile' => ['bool', 'filename'=>''],
'OCI-Lob::setbuffering' => ['bool', 'on_off'=>'bool'],
'OCI-Lob::writetofile' => ['bool', 'filename'=>'', 'start'=>'', 'length'=>''],
'oci_lob_append' => ['bool', 'lob'=>'OCI-Lob'],
'oci_lob_close' => ['bool'],
'oci_lob_copy' => ['bool', 'lob_to'=>'OCI-Lob', 'lob_from'=>'OCI-Lob', 'length='=>'int'],
'oci_lob_eof' => ['bool'],
'oci_lob_erase' => ['int', 'offset'=>'int', 'length'=>'int'],
'oci_lob_export' => ['bool', 'filename'=>'string', 'start'=>'int', 'length'=>'int'],
'oci_lob_flush' => ['bool', 'flag'=>'int'],
'oci_lob_import' => ['bool', 'filename'=>'string'],
'oci_lob_is_equal' => ['bool', 'lob1'=>'OCI-Lob', 'lob2'=>'OCI-Lob'],
'oci_lob_load' => ['string'],
'oci_lob_read' => ['string', 'length'=>'int'],
'oci_lob_rewind' => ['bool'],
'oci_lob_save' => ['bool', 'data'=>'string', 'offset'=>'int'],
'oci_lob_seek' => ['bool', 'offset'=>'int', 'whence'=>'int'],
'oci_lob_size' => ['int'],
'oci_lob_tell' => ['int'],
'oci_lob_truncate' => ['bool', 'length'=>'int'],
'oci_lob_write' => ['int', 'string'=>'string', 'length'=>'int'],
'oci_lob_write_temporary' => ['bool', 'var'=>'string', 'lob_type'=>'int'],
'oci_new_collection' => ['OCI-Collection', 'connection'=>'resource', 'tdo'=>'string', 'schema='=>'string'],
'oci_new_connect' => ['resource', 'user'=>'string', 'pass'=>'string', 'db='=>'string', 'charset='=>'string', 'session_mode='=>'int'],
'oci_new_cursor' => ['resource', 'connection'=>'resource'],
'oci_new_descriptor' => ['OCI-Lob', 'connection'=>'resource', 'type='=>'int'],
'oci_num_fields' => ['int', 'stmt'=>'resource'],
'oci_num_rows' => ['int', 'stmt'=>'resource'],
'oci_parse' => ['resource', 'connection'=>'resource', 'statement'=>'string'],
'oci_password_change' => ['bool', 'connection'=>'', 'username'=>'string', 'old_password'=>'string', 'new_password'=>'string'],
'oci_pconnect' => ['resource', 'user'=>'string', 'pass'=>'string', 'db='=>'string', 'charset='=>'string', 'session_mode='=>'int'],
'oci_register_taf_callback' => ['bool', 'connection'=>'resource', 'callback='=>'callable'],
'oci_result' => ['string', 'stmt'=>'resource', 'column'=>'mixed'],
'oci_rollback' => ['bool', 'connection'=>'resource'],
'oci_server_version' => ['string', 'connection'=>'resource'],
'oci_set_action' => ['bool', 'connection'=>'resource', 'value'=>'string'],
'oci_set_client_identifier' => ['bool', 'connection'=>'resource', 'value'=>'string'],
'oci_set_client_info' => ['bool', 'connection'=>'resource', 'value'=>'string'],
'oci_set_db_operation' => ['bool', 'connection'=>'', 'value'=>'string'],
'oci_set_edition' => ['bool', 'value'=>'string'],
'oci_set_module_name' => ['bool', 'connection'=>'resource', 'value'=>'string'],
'oci_set_prefetch' => ['bool', 'stmt'=>'resource', 'prefetch_rows'=>'int'],
'oci_statement_type' => ['string', 'stmt'=>'resource'],
'oci_unregister_taf_callback' => ['bool', 'connection'=>'resource'],
'ocifetchinto' => ['int', 'stmt'=>'', '&w_output'=>'array', 'mode='=>'int'],
'ocigetbufferinglob' => ['bool'],
'ocisetbufferinglob' => ['bool', 'flag'=>'bool'],
'octdec' => ['int', 'octal_number'=>'string'],
'odbc_autocommit' => ['mixed', 'connection_id'=>'resource', 'onoff='=>'bool'],
'odbc_binmode' => ['bool', 'result_id'=>'int', 'mode'=>'int'],
'odbc_close' => ['void', 'connection_id'=>'resource'],
'odbc_close_all' => ['void'],
'odbc_columnprivileges' => ['resource', 'connection_id'=>'resource', 'catalog'=>'string', 'schema'=>'string', 'table'=>'string', 'column'=>'string'],
'odbc_columns' => ['resource', 'connection_id'=>'resource', 'qualifier='=>'string', 'owner='=>'string', 'table_name='=>'string', 'column_name='=>'string'],
'odbc_commit' => ['bool', 'connection_id'=>'resource'],
'odbc_connect' => ['resource', 'dsn'=>'string', 'user'=>'string', 'password'=>'string', 'cursor_option='=>'int'],
'odbc_cursor' => ['string', 'result_id'=>'resource'],
'odbc_data_source' => ['array', 'connection_id'=>'resource', 'fetch_type'=>'int'],
'odbc_do' => ['resource', 'connection_id'=>'resource', 'query'=>'string', 'flags='=>'int'],
'odbc_error' => ['string', 'connection_id='=>'resource'],
'odbc_errormsg' => ['string', 'connection_id='=>'resource'],
'odbc_exec' => ['resource', 'connection_id'=>'resource', 'query'=>'string', 'flags='=>'int'],
'odbc_execute' => ['bool', 'result_id'=>'resource', 'parameters_array='=>'array'],
'odbc_fetch_array' => ['array', 'result'=>'resource', 'rownumber='=>'int'],
'odbc_fetch_into' => ['int', 'result_id'=>'resource', '&w_result_array'=>'array', 'rownumber='=>'int'],
'odbc_fetch_object' => ['object', 'result'=>'int', 'rownumber='=>'int'],
'odbc_fetch_row' => ['bool', 'result_id'=>'resource', 'row_number='=>'int'],
'odbc_field_len' => ['int', 'result_id'=>'resource', 'field_number'=>'int'],
'odbc_field_name' => ['string', 'result_id'=>'resource', 'field_number'=>'int'],
'odbc_field_num' => ['int', 'result_id'=>'resource', 'field_name'=>'string'],
'odbc_field_precision' => ['int', 'result_id'=>'resource', 'field_number'=>'int'],
'odbc_field_scale' => ['int', 'result_id'=>'resource', 'field_number'=>'int'],
'odbc_field_type' => ['string', 'result_id'=>'resource', 'field_number'=>'int'],
'odbc_foreignkeys' => ['resource', 'connection_id'=>'resource', 'pk_qualifier'=>'string', 'pk_owner'=>'string', 'pk_table'=>'string', 'fk_qualifier'=>'string', 'fk_owner'=>'string', 'fk_table'=>'string'],
'odbc_free_result' => ['bool', 'result_id'=>'resource'],
'odbc_gettypeinfo' => ['resource', 'connection_id'=>'resource', 'data_type='=>'int'],
'odbc_longreadlen' => ['bool', 'result_id'=>'int', 'length'=>'int'],
'odbc_next_result' => ['bool', 'result_id'=>'resource'],
'odbc_num_fields' => ['int', 'result_id'=>'resource'],
'odbc_num_rows' => ['int', 'result_id'=>'resource'],
'odbc_pconnect' => ['resource', 'dsn'=>'string', 'user'=>'string', 'password'=>'string', 'cursor_option='=>'int'],
'odbc_prepare' => ['resource', 'connection_id'=>'resource', 'query'=>'string'],
'odbc_primarykeys' => ['resource', 'connection_id'=>'resource', 'qualifier'=>'string', 'owner'=>'string', 'table'=>'string'],
'odbc_procedurecolumns' => ['resource', 'connection_id'=>'', 'qualifier'=>'string', 'owner'=>'string', 'proc'=>'string', 'column'=>'string'],
'odbc_procedures' => ['resource', 'connection_id'=>'', 'qualifier'=>'string', 'owner'=>'string', 'name'=>'string'],
'odbc_result' => ['mixed', 'result_id'=>'resource', 'field'=>'mixed'],
'odbc_result_all' => ['int', 'result_id'=>'resource', 'format='=>'string'],
'odbc_rollback' => ['bool', 'connection_id'=>'resource'],
'odbc_setoption' => ['bool', 'result_id'=>'resource', 'which'=>'int', 'option'=>'int', 'value'=>'int'],
'odbc_specialcolumns' => ['resource', 'connection_id'=>'resource', 'type'=>'int', 'qualifier'=>'string', 'owner'=>'string', 'table'=>'string', 'scope'=>'int', 'nullable'=>'int'],
'odbc_statistics' => ['resource', 'connection_id'=>'resource', 'qualifier'=>'string', 'owner'=>'string', 'name'=>'string', 'unique'=>'int', 'accuracy'=>'int'],
'odbc_tableprivileges' => ['resource', 'connection_id'=>'resource', 'qualifier'=>'string', 'owner'=>'string', 'name'=>'string'],
'odbc_tables' => ['resource', 'connection_id'=>'resource', 'qualifier='=>'string', 'owner='=>'string', 'name='=>'string', 'table_types='=>'string'],
'opcache_compile_file' => ['bool', 'file'=>'string'],
'opcache_get_configuration' => ['array'],
'opcache_get_status' => ['array|false', 'get_scripts='=>'bool'],
'opcache_invalidate' => ['bool', 'script'=>'string', 'force='=>'bool'],
'opcache_is_script_cached' => ['bool', 'script'=>'string'],
'opcache_reset' => ['bool'],
'openal_buffer_create' => ['resource'],
'openal_buffer_data' => ['bool', 'buffer'=>'resource', 'format'=>'int', 'data'=>'string', 'freq'=>'int'],
'openal_buffer_destroy' => ['bool', 'buffer'=>'resource'],
'openal_buffer_get' => ['int', 'buffer'=>'resource', 'property'=>'int'],
'openal_buffer_loadwav' => ['bool', 'buffer'=>'resource', 'wavfile'=>'string'],
'openal_context_create' => ['resource', 'device'=>'resource'],
'openal_context_current' => ['bool', 'context'=>'resource'],
'openal_context_destroy' => ['bool', 'context'=>'resource'],
'openal_context_process' => ['bool', 'context'=>'resource'],
'openal_context_suspend' => ['bool', 'context'=>'resource'],
'openal_device_close' => ['bool', 'device'=>'resource'],
'openal_device_open' => ['resource', 'device_desc='=>'string'],
'openal_listener_get' => ['mixed', 'property'=>'int'],
'openal_listener_set' => ['bool', 'property'=>'int', 'setting'=>'mixed'],
'openal_source_create' => ['resource'],
'openal_source_destroy' => ['bool', 'source'=>'resource'],
'openal_source_get' => ['mixed', 'source'=>'resource', 'property'=>'int'],
'openal_source_pause' => ['bool', 'source'=>'resource'],
'openal_source_play' => ['bool', 'source'=>'resource'],
'openal_source_rewind' => ['bool', 'source'=>'resource'],
'openal_source_set' => ['bool', 'source'=>'resource', 'property'=>'int', 'setting'=>'mixed'],
'openal_source_stop' => ['bool', 'source'=>'resource'],
'openal_stream' => ['resource', 'source'=>'resource', 'format'=>'int', 'rate'=>'int'],
'opendir' => ['resource|false', 'path'=>'string', 'context='=>'resource'],
'openlog' => ['bool', 'ident'=>'string', 'option'=>'int', 'facility'=>'int'],
'openssl_cipher_iv_length' => ['int|false', 'method'=>'string'],
'openssl_csr_export' => ['bool', 'csr'=>'string|resource', '&w_out'=>'string', 'notext='=>'bool'],
'openssl_csr_export_to_file' => ['bool', 'csr'=>'string|resource', 'outfilename'=>'string', 'notext='=>'bool'],
'openssl_csr_get_public_key' => ['resource|false', 'csr'=>'string|resource', 'use_shortnames='=>'bool'],
'openssl_csr_get_subject' => ['array', 'csr'=>'string|resource', 'use_shortnames='=>'bool'],
'openssl_csr_new' => ['resource|false', 'dn'=>'array', '&w_privkey'=>'resource', 'configargs='=>'array', 'extraattribs='=>'array'],
'openssl_csr_sign' => ['resource|false', 'csr'=>'string|resource', 'x509'=>'string|resource|null', 'priv_key'=>'string|resource|array', 'days'=>'int', 'config_args='=>'array', 'serial='=>'int'],
'openssl_decrypt' => ['string|false', 'data'=>'string', 'method'=>'string', 'key'=>'string', 'options='=>'int', 'iv='=>'string', 'tag='=>'string', 'aad='=>'string'],
'openssl_dh_compute_key' => ['string|false', 'pub_key'=>'string', 'dh_key'=>'resource'],
'openssl_digest' => ['string|false', 'data'=>'string', 'method'=>'string', 'raw_output='=>'bool'],
'openssl_encrypt' => ['string|false', 'data'=>'string', 'method'=>'string', 'key'=>'string', 'options='=>'int', 'iv='=>'string', '&rw_tag='=>'string', 'aad='=>'string', 'tag_length='=>'int'],
'openssl_error_string' => ['string|false'],
'openssl_free_key' => ['void', 'key_identifier'=>'resource'],
'openssl_get_cert_locations' => ['array'],
'openssl_get_cipher_methods' => ['array', 'aliases='=>'bool'],
'openssl_get_curve_names' => ['array'],
'openssl_get_md_methods' => ['array', 'aliases='=>'bool'],
'openssl_get_privatekey' => ['resource|false', 'key'=>'string', 'passphrase='=>'string'],
'openssl_get_publickey' => ['resource|false', 'cert'=>'resource|string'],
'openssl_open' => ['bool', 'sealed_data'=>'string', '&w_open_data'=>'string', 'env_key'=>'string', 'priv_key_id'=>'string|array|resource', 'method='=>'string', 'iv='=>'string'],
'openssl_pbkdf2' => ['string|false', 'password'=>'string', 'salt'=>'string', 'key_length'=>'int', 'iterations'=>'int', 'digest_algorithm'=>'string'],
'openssl_pkcs12_export' => ['bool', 'x509'=>'string|resource', '&w_out'=>'string', 'priv_key'=>'string|array|resource', 'pass'=>'string', 'args='=>'array'],
'openssl_pkcs12_export_to_file' => ['bool', 'x509'=>'string|resource', 'filename'=>'string', 'priv_key'=>'string|array|resource', 'pass'=>'string', 'args='=>'array'],
'openssl_pkcs12_read' => ['bool', 'pkcs12'=>'string', '&w_certs'=>'array', 'pass'=>'string'],
'openssl_pkcs7_decrypt' => ['bool', 'infilename'=>'string', 'outfilename'=>'string', 'recipcert'=>'string|resource', 'recipkey='=>'string|resource|array'],
'openssl_pkcs7_encrypt' => ['bool', 'infile'=>'string', 'outfile'=>'string', 'recipcerts'=>'string|resource|array', 'headers'=>'array', 'flags='=>'int', 'cipherid='=>'int'],
'openssl_pkcs7_read' => ['bool', 'infilename'=>'string', 'certs'=>'array'],
'openssl_pkcs7_sign' => ['bool', 'infile'=>'string', 'outfile'=>'string', 'signcert'=>'string|resource', 'privkey'=>'string|resource|array', 'headers'=>'array', 'flags='=>'int', 'extracerts='=>'string'],
'openssl_pkcs7_verify' => ['bool|int', 'filename'=>'string', 'flags'=>'int', 'outfilename='=>'string', 'cainfo='=>'array', 'extracerts='=>'string', 'content='=>'string', 'p7bfilename='=>'string'],
'openssl_pkey_export' => ['bool', 'key'=>'resource', '&w_out'=>'string', 'passphrase='=>'string', 'configargs='=>'array'],
'openssl_pkey_export_to_file' => ['bool', 'key'=>'resource|string|array', 'outfilename'=>'string', 'passphrase='=>'string', 'configargs='=>'array'],
'openssl_pkey_free' => ['void', 'key'=>'resource'],
'openssl_pkey_get_details' => ['array|false', 'key'=>'resource'],
'openssl_pkey_get_private' => ['resource|false', 'key'=>'string', 'passphrase='=>'string'],
'openssl_pkey_get_public' => ['resource|false', 'certificate'=>'resource|string'],
'openssl_pkey_new' => ['resource|false', 'configargs='=>'array'],
'openssl_private_decrypt' => ['bool', 'data'=>'string', '&w_decrypted'=>'string', 'key'=>'string|resource|array', 'padding='=>'int'],
'openssl_private_encrypt' => ['bool', 'data'=>'string', '&w_crypted'=>'string', 'key'=>'string|resource|array', 'padding='=>'int'],
'openssl_public_decrypt' => ['bool', 'data'=>'string', '&w_decrypted'=>'string', 'key'=>'string|resource', 'padding='=>'int'],
'openssl_public_encrypt' => ['bool', 'data'=>'string', '&w_crypted'=>'string', 'key'=>'string|resource', 'padding='=>'int'],
'openssl_random_pseudo_bytes' => ['string|false', 'length'=>'int', '&w_crypto_strong='=>'bool'],
'openssl_seal' => ['int|false', 'data'=>'string', '&w_sealed_data'=>'string', '&rw_env_keys'=>'array', 'pub_key_ids'=>'array', 'method='=>'string'],
'openssl_sign' => ['bool', 'data'=>'string', '&w_signature'=>'string', 'priv_key_id'=>'resource|string', 'signature_alg='=>'int|string'],
'openssl_spki_export' => ['string|null', 'spkac'=>'string'],
'openssl_spki_export_challenge' => ['string|null', 'spkac'=>'string'],
'openssl_spki_new' => ['string|null', 'privkey'=>'resource', 'challenge'=>'string', 'algorithm='=>'int'],
'openssl_spki_verify' => ['bool', 'spkac'=>'string'],
'openssl_verify' => ['int', 'data'=>'string', 'signature'=>'string', 'pub_key_id'=>'resource|string', 'signature_alg='=>'int|string'],
'openssl_x509_check_private_key' => ['bool', 'cert'=>'string|resource', 'key'=>'string|resource|array'],
'openssl_x509_checkpurpose' => ['bool|int', 'x509cert'=>'string|resource', 'purpose'=>'int', 'cainfo='=>'array', 'untrustedfile='=>'string'],
'openssl_x509_export' => ['bool', 'x509'=>'string|resource', '&w_output'=>'string', 'notext='=>'bool'],
'openssl_x509_export_to_file' => ['bool', 'x509'=>'string|resource', 'outfilename'=>'string', 'notext='=>'bool'],
'openssl_x509_fingerprint' => ['string|false', 'x509'=>'string|resource', 'hash_algorithm='=>'string', 'raw_output='=>'bool'],
'openssl_x509_free' => ['void', 'x509'=>'resource'],
'openssl_x509_parse' => ['array|false', 'x509cert'=>'string|resource', 'shortnames='=>'bool'],
'openssl_x509_read' => ['resource|false', 'x509certdata'=>'string|resource'],
'ord' => ['int', 'character'=>'string'],
'OuterIterator::getInnerIterator' => ['Iterator'],
'OutOfBoundsException::__clone' => ['void'],
'OutOfBoundsException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?OutOfBoundsException'],
'OutOfBoundsException::__toString' => ['string'],
'OutOfBoundsException::getCode' => ['int'],
'OutOfBoundsException::getFile' => ['string'],
'OutOfBoundsException::getLine' => ['int'],
'OutOfBoundsException::getMessage' => ['string'],
'OutOfBoundsException::getPrevious' => ['Throwable|OutOfBoundsException|null'],
'OutOfBoundsException::getTrace' => ['array'],
'OutOfBoundsException::getTraceAsString' => ['string'],
'OutOfRangeException::__clone' => ['void'],
'OutOfRangeException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?OutOfRangeException'],
'OutOfRangeException::__toString' => ['string'],
'OutOfRangeException::getCode' => ['int'],
'OutOfRangeException::getFile' => ['string'],
'OutOfRangeException::getLine' => ['int'],
'OutOfRangeException::getMessage' => ['string'],
'OutOfRangeException::getPrevious' => ['Throwable|OutOfRangeException|null'],
'OutOfRangeException::getTrace' => ['array'],
'OutOfRangeException::getTraceAsString' => ['string'],
'output_add_rewrite_var' => ['bool', 'name'=>'string', 'value'=>'string'],
'output_reset_rewrite_vars' => ['bool'],
'OverflowException::__clone' => ['void'],
'OverflowException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?OverflowException'],
'OverflowException::__toString' => ['string'],
'OverflowException::getCode' => ['int'],
'OverflowException::getFile' => ['string'],
'OverflowException::getLine' => ['int'],
'OverflowException::getMessage' => ['string'],
'OverflowException::getPrevious' => ['Throwable|OverflowException|null'],
'OverflowException::getTrace' => ['array'],
'OverflowException::getTraceAsString' => ['string'],
'overload' => ['', 'class_name'=>'string'],
'override_function' => ['bool', 'function_name'=>'string', 'function_args'=>'string', 'function_code'=>'string'],
'pack' => ['string', 'format'=>'string', '...args='=>'mixed'],
'ParentIterator::__construct' => ['void', 'it'=>'recursiveiterator'],
'ParentIterator::accept' => ['bool'],
'ParentIterator::getChildren' => ['ParentIterator'],
'ParentIterator::hasChildren' => ['bool'],
'ParentIterator::next' => ['void'],
'ParentIterator::rewind' => ['void'],
'ParentIterator::valid' => [''],
'Parle\Lexer::advance' => ['void'],
'Parle\Lexer::build' => ['void'],
'Parle\Lexer::callout' => ['void', 'id'=>'int', 'callback'=>'callable'],
'Parle\Lexer::consume' => ['void', 'data'=>'string'],
'Parle\Lexer::dump' => ['void'],
'Parle\Lexer::getToken' => ['Parle\Token'],
'Parle\Lexer::insertMacro' => ['void', 'name'=>'string', 'regex'=>'string'],
'Parle\Lexer::push' => ['void', 'regex'=>'string', 'id'=>'int'],
'Parle\Lexer::reset' => ['void', 'pos'=>'int'],
'Parle\Parser::advance' => ['void'],
'Parle\Parser::build' => ['void'],
'Parle\Parser::consume' => ['void', 'data'=>'string', 'lexer'=>'Parle\Lexer'],
'Parle\Parser::dump' => ['void'],
'Parle\Parser::errorInfo' => ['Parle\ErrorInfo'],
'Parle\Parser::left' => ['void', 'token'=>'string'],
'Parle\Parser::nonassoc' => ['void', 'token'=>'string'],
'Parle\Parser::precedence' => ['void', 'token'=>'string'],
'Parle\Parser::push' => ['int', 'name'=>'string', 'rule'=>'string'],
'Parle\Parser::reset' => ['void', 'tokenId'=>'int'],
'Parle\Parser::right' => ['void', 'token'=>'string'],
'Parle\Parser::sigil' => ['string', 'idx'=>'array'],
'Parle\Parser::token' => ['void', 'token'=>'string'],
'Parle\Parser::tokenId' => ['int', 'token'=>'string'],
'Parle\Parser::trace' => ['string'],
'Parle\Parser::validate' => ['bool', 'data'=>'string', 'lexer'=>'Parle\Lexer'],
'Parle\RLexer::advance' => ['void'],
'Parle\RLexer::build' => ['void'],
'Parle\RLexer::callout' => ['void', 'id'=>'int', 'callback'=>'callable'],
'Parle\RLexer::consume' => ['void', 'data'=>'string'],
'Parle\RLexer::dump' => ['void'],
'Parle\RLexer::getToken' => ['Parle\Token'],
'Parle\RLexer::push' => ['void', 'state'=>'string', 'regex'=>'string', 'newState'=>'string'],
'Parle\RLexer::pushState' => ['int', 'state'=>'string'],
'Parle\RLexer::reset' => ['void', 'pos'=>'int'],
'Parle\RParser::advance' => ['void'],
'Parle\RParser::build' => ['void'],
'Parle\RParser::consume' => ['void', 'data'=>'string', 'lexer'=>'Parle\Lexer'],
'Parle\RParser::dump' => ['void'],
'Parle\RParser::errorInfo' => ['Parle\ErrorInfo'],
'Parle\RParser::left' => ['void', 'token'=>'string'],
'Parle\RParser::nonassoc' => ['void', 'token'=>'string'],
'Parle\RParser::precedence' => ['void', 'token'=>'string'],
'Parle\RParser::push' => ['int', 'name'=>'string', 'rule'=>'string'],
'Parle\RParser::reset' => ['void', 'tokenId'=>'int'],
'Parle\RParser::right' => ['void', 'token'=>'string'],
'Parle\RParser::sigil' => ['string', 'idx'=>'array'],
'Parle\RParser::token' => ['void', 'token'=>'string'],
'Parle\RParser::tokenId' => ['int', 'token'=>'string'],
'Parle\RParser::trace' => ['string'],
'Parle\RParser::validate' => ['bool', 'data'=>'string', 'lexer'=>'Parle\Lexer'],
'Parle\Stack::pop' => ['void'],
'Parle\Stack::push' => ['void', 'item'=>''],
'parse_ini_file' => ['array|false', 'filename'=>'string', 'process_sections='=>'bool', 'scanner_mode='=>'int'],
'parse_ini_string' => ['array|false', 'ini_string'=>'string', 'process_sections='=>'bool', 'scanner_mode='=>'int'],
'parse_str' => ['void', 'encoded_string'=>'string', '&w_result='=>'array'],
'parse_url' => ['mixed', 'url'=>'string', 'url_component='=>'int'],
'ParseError::__clone' => ['void'],
'ParseError::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?ParseError'],
'ParseError::__toString' => ['string'],
'ParseError::getCode' => ['int'],
'ParseError::getFile' => ['string'],
'ParseError::getLine' => ['int'],
'ParseError::getMessage' => ['string'],
'ParseError::getPrevious' => ['Throwable|ParseError|null'],
'ParseError::getTrace' => ['array'],
'ParseError::getTraceAsString' => ['string'],
'parsekit_compile_file' => ['array', 'filename'=>'string', 'errors='=>'array', 'options='=>'int'],
'parsekit_compile_string' => ['array', 'phpcode'=>'string', 'errors='=>'array', 'options='=>'int'],
'parsekit_func_arginfo' => ['array', 'function'=>'mixed'],
'passthru' => ['void', 'command'=>'string', '&w_return_value='=>'int'],
'password_get_info' => ['array', 'hash'=>'string'],
'password_hash' => ['string|false', 'password'=>'string', 'algo'=>'int', 'options='=>'array'],
'password_make_salt' => ['bool', 'password'=>'string', 'hash'=>'string'],
'password_needs_rehash' => ['bool', 'hash'=>'string', 'algo'=>'int', 'options='=>'array'],
'password_verify' => ['bool', 'password'=>'string', 'hash'=>'string'],
'pathinfo' => ['array|string', 'path'=>'string', 'options='=>'int'],
'pclose' => ['int', 'fp'=>'resource'],
'pcnlt_sigwaitinfo' => ['int', 'set'=>'array', '&w_siginfo'=>'array'],
'pcntl_alarm' => ['int', 'seconds'=>'int'],
'pcntl_async_signals' => ['bool', 'on='=>'bool'],
'pcntl_exec' => ['bool', 'path'=>'string', 'args='=>'array', 'envs='=>'array'],
'pcntl_fork' => ['int'],
'pcntl_get_last_error' => ['int'],
'pcntl_getpriority' => ['int', 'pid='=>'int', 'process_identifier='=>'int'],
'pcntl_setpriority' => ['bool', 'priority'=>'int', 'pid='=>'int', 'process_identifier='=>'int'],
'pcntl_signal' => ['bool', 'signo'=>'int', 'handle'=>'callable|int', 'restart_syscalls='=>'bool'],
'pcntl_signal_dispatch' => ['bool'],
'pcntl_signal_get_handler' => ['int|string', 'signo'=>'int'],
'pcntl_sigprocmask' => ['bool', 'how'=>'int', 'set'=>'array', '&w_oldset='=>'array'],
'pcntl_sigtimedwait' => ['int', 'set'=>'array', '&w_siginfo='=>'array', 'seconds='=>'int', 'nanoseconds='=>'int'],
'pcntl_sigwaitinfo' => ['int', 'set'=>'array', '&w_siginfo='=>'array'],
'pcntl_strerror' => ['string', 'errno'=>'int'],
'pcntl_wait' => ['int', '&w_status'=>'int', 'options='=>'int', '&w_rusage='=>'array'],
'pcntl_waitpid' => ['int', 'pid'=>'int', '&w_status'=>'int', 'options='=>'int', '&w_rusage='=>'array'],
'pcntl_wexitstatus' => ['int', 'status'=>'int'],
'pcntl_wifcontinued' => ['bool', 'status'=>'int'],
'pcntl_wifexited' => ['bool', 'status'=>'int'],
'pcntl_wifsignaled' => ['bool', 'status'=>'int'],
'pcntl_wifstopped' => ['bool', 'status'=>'int'],
'pcntl_wstopsig' => ['int', 'status'=>'int'],
'pcntl_wtermsig' => ['int', 'status'=>'int'],
'PDF_activate_item' => ['bool', 'pdfdoc'=>'resource', 'id'=>'int'],
'PDF_add_launchlink' => ['bool', 'pdfdoc'=>'resource', 'llx'=>'float', 'lly'=>'float', 'urx'=>'float', 'ury'=>'float', 'filename'=>'string'],
'PDF_add_locallink' => ['bool', 'pdfdoc'=>'resource', 'lowerleftx'=>'float', 'lowerlefty'=>'float', 'upperrightx'=>'float', 'upperrighty'=>'float', 'page'=>'int', 'dest'=>'string'],
'PDF_add_nameddest' => ['bool', 'pdfdoc'=>'resource', 'name'=>'string', 'optlist'=>'string'],
'PDF_add_note' => ['bool', 'pdfdoc'=>'resource', 'llx'=>'float', 'lly'=>'float', 'urx'=>'float', 'ury'=>'float', 'contents'=>'string', 'title'=>'string', 'icon'=>'string', 'open'=>'int'],
'PDF_add_pdflink' => ['bool', 'pdfdoc'=>'resource', 'bottom_left_x'=>'float', 'bottom_left_y'=>'float', 'up_right_x'=>'float', 'up_right_y'=>'float', 'filename'=>'string', 'page'=>'int', 'dest'=>'string'],
'PDF_add_table_cell' => ['int', 'pdfdoc'=>'resource', 'table'=>'int', 'column'=>'int', 'row'=>'int', 'text'=>'string', 'optlist'=>'string'],
'PDF_add_textflow' => ['int', 'pdfdoc'=>'resource', 'textflow'=>'int', 'text'=>'string', 'optlist'=>'string'],
'PDF_add_thumbnail' => ['bool', 'pdfdoc'=>'resource', 'image'=>'int'],
'PDF_add_weblink' => ['bool', 'pdfdoc'=>'resource', 'lowerleftx'=>'float', 'lowerlefty'=>'float', 'upperrightx'=>'float', 'upperrighty'=>'float', 'url'=>'string'],
'PDF_arc' => ['bool', 'p'=>'resource', 'x'=>'float', 'y'=>'float', 'r'=>'float', 'alpha'=>'float', 'beta'=>'float'],
'PDF_arcn' => ['bool', 'p'=>'resource', 'x'=>'float', 'y'=>'float', 'r'=>'float', 'alpha'=>'float', 'beta'=>'float'],
'PDF_attach_file' => ['bool', 'pdfdoc'=>'resource', 'llx'=>'float', 'lly'=>'float', 'urx'=>'float', 'ury'=>'float', 'filename'=>'string', 'description'=>'string', 'author'=>'string', 'mimetype'=>'string', 'icon'=>'string'],
'PDF_begin_document' => ['int', 'pdfdoc'=>'resource', 'filename'=>'string', 'optlist'=>'string'],
'PDF_begin_font' => ['bool', 'pdfdoc'=>'resource', 'filename'=>'string', 'a'=>'float', 'b'=>'float', 'c'=>'float', 'd'=>'float', 'e'=>'float', 'f'=>'float', 'optlist'=>'string'],
'PDF_begin_glyph' => ['bool', 'pdfdoc'=>'resource', 'glyphname'=>'string', 'wx'=>'float', 'llx'=>'float', 'lly'=>'float', 'urx'=>'float', 'ury'=>'float'],
'PDF_begin_item' => ['int', 'pdfdoc'=>'resource', 'tag'=>'string', 'optlist'=>'string'],
'PDF_begin_layer' => ['bool', 'pdfdoc'=>'resource', 'layer'=>'int'],
'PDF_begin_page' => ['bool', 'pdfdoc'=>'resource', 'width'=>'float', 'height'=>'float'],
'PDF_begin_page_ext' => ['bool', 'pdfdoc'=>'resource', 'width'=>'float', 'height'=>'float', 'optlist'=>'string'],
'PDF_begin_pattern' => ['int', 'pdfdoc'=>'resource', 'width'=>'float', 'height'=>'float', 'xstep'=>'float', 'ystep'=>'float', 'painttype'=>'int'],
'PDF_begin_template' => ['int', 'pdfdoc'=>'resource', 'width'=>'float', 'height'=>'float'],
'PDF_begin_template_ext' => ['int', 'pdfdoc'=>'resource', 'width'=>'float', 'height'=>'float', 'optlist'=>'string'],
'PDF_circle' => ['bool', 'pdfdoc'=>'resource', 'x'=>'float', 'y'=>'float', 'r'=>'float'],
'PDF_clip' => ['bool', 'p'=>'resource'],
'PDF_close' => ['bool', 'p'=>'resource'],
'PDF_close_image' => ['bool', 'p'=>'resource', 'image'=>'int'],
'PDF_close_pdi' => ['bool', 'p'=>'resource', 'doc'=>'int'],
'PDF_close_pdi_page' => ['bool', 'p'=>'resource', 'page'=>'int'],
'PDF_closepath' => ['bool', 'p'=>'resource'],
'PDF_closepath_fill_stroke' => ['bool', 'p'=>'resource'],
'PDF_closepath_stroke' => ['bool', 'p'=>'resource'],
'PDF_concat' => ['bool', 'p'=>'resource', 'a'=>'float', 'b'=>'float', 'c'=>'float', 'd'=>'float', 'e'=>'float', 'f'=>'float'],
'PDF_continue_text' => ['bool', 'p'=>'resource', 'text'=>'string'],
'PDF_create_3dview' => ['int', 'pdfdoc'=>'resource', 'username'=>'string', 'optlist'=>'string'],
'PDF_create_action' => ['int', 'pdfdoc'=>'resource', 'type'=>'string', 'optlist'=>'string'],
'PDF_create_annotation' => ['bool', 'pdfdoc'=>'resource', 'llx'=>'float', 'lly'=>'float', 'urx'=>'float', 'ury'=>'float', 'type'=>'string', 'optlist'=>'string'],
'PDF_create_bookmark' => ['int', 'pdfdoc'=>'resource', 'text'=>'string', 'optlist'=>'string'],
'PDF_create_field' => ['bool', 'pdfdoc'=>'resource', 'llx'=>'float', 'lly'=>'float', 'urx'=>'float', 'ury'=>'float', 'name'=>'string', 'type'=>'string', 'optlist'=>'string'],
'PDF_create_fieldgroup' => ['bool', 'pdfdoc'=>'resource', 'name'=>'string', 'optlist'=>'string'],
'PDF_create_gstate' => ['int', 'pdfdoc'=>'resource', 'optlist'=>'string'],
'PDF_create_pvf' => ['bool', 'pdfdoc'=>'resource', 'filename'=>'string', 'data'=>'string', 'optlist'=>'string'],
'PDF_create_textflow' => ['int', 'pdfdoc'=>'resource', 'text'=>'string', 'optlist'=>'string'],
'PDF_curveto' => ['bool', 'p'=>'resource', 'x1'=>'float', 'y1'=>'float', 'x2'=>'float', 'y2'=>'float', 'x3'=>'float', 'y3'=>'float'],
'PDF_define_layer' => ['int', 'pdfdoc'=>'resource', 'name'=>'string', 'optlist'=>'string'],
'PDF_delete' => ['bool', 'pdfdoc'=>'resource'],
'PDF_delete_pvf' => ['int', 'pdfdoc'=>'resource', 'filename'=>'string'],
'PDF_delete_table' => ['bool', 'pdfdoc'=>'resource', 'table'=>'int', 'optlist'=>'string'],
'PDF_delete_textflow' => ['bool', 'pdfdoc'=>'resource', 'textflow'=>'int'],
'PDF_encoding_set_char' => ['bool', 'pdfdoc'=>'resource', 'encoding'=>'string', 'slot'=>'int', 'glyphname'=>'string', 'uv'=>'int'],
'PDF_end_document' => ['bool', 'pdfdoc'=>'resource', 'optlist'=>'string'],
'PDF_end_font' => ['bool', 'pdfdoc'=>'resource'],
'PDF_end_glyph' => ['bool', 'pdfdoc'=>'resource'],
'PDF_end_item' => ['bool', 'pdfdoc'=>'resource', 'id'=>'int'],
'PDF_end_layer' => ['bool', 'pdfdoc'=>'resource'],
'PDF_end_page' => ['bool', 'p'=>'resource'],
'PDF_end_page_ext' => ['bool', 'pdfdoc'=>'resource', 'optlist'=>'string'],
'PDF_end_pattern' => ['bool', 'p'=>'resource'],
'PDF_end_template' => ['bool', 'p'=>'resource'],
'PDF_endpath' => ['bool', 'p'=>'resource'],
'PDF_fill' => ['bool', 'p'=>'resource'],
'PDF_fill_imageblock' => ['int', 'pdfdoc'=>'resource', 'page'=>'int', 'blockname'=>'string', 'image'=>'int', 'optlist'=>'string'],
'PDF_fill_pdfblock' => ['int', 'pdfdoc'=>'resource', 'page'=>'int', 'blockname'=>'string', 'contents'=>'int', 'optlist'=>'string'],
'PDF_fill_stroke' => ['bool', 'p'=>'resource'],
'PDF_fill_textblock' => ['int', 'pdfdoc'=>'resource', 'page'=>'int', 'blockname'=>'string', 'text'=>'string', 'optlist'=>'string'],
'PDF_findfont' => ['int', 'p'=>'resource', 'fontname'=>'string', 'encoding'=>'string', 'embed'=>'int'],
'PDF_fit_image' => ['bool', 'pdfdoc'=>'resource', 'image'=>'int', 'x'=>'float', 'y'=>'float', 'optlist'=>'string'],
'PDF_fit_pdi_page' => ['bool', 'pdfdoc'=>'resource', 'page'=>'int', 'x'=>'float', 'y'=>'float', 'optlist'=>'string'],
'PDF_fit_table' => ['string', 'pdfdoc'=>'resource', 'table'=>'int', 'llx'=>'float', 'lly'=>'float', 'urx'=>'float', 'ury'=>'float', 'optlist'=>'string'],
'PDF_fit_textflow' => ['string', 'pdfdoc'=>'resource', 'textflow'=>'int', 'llx'=>'float', 'lly'=>'float', 'urx'=>'float', 'ury'=>'float', 'optlist'=>'string'],
'PDF_fit_textline' => ['bool', 'pdfdoc'=>'resource', 'text'=>'string', 'x'=>'float', 'y'=>'float', 'optlist'=>'string'],
'PDF_get_apiname' => ['string', 'pdfdoc'=>'resource'],
'PDF_get_buffer' => ['string', 'p'=>'resource'],
'PDF_get_errmsg' => ['string', 'pdfdoc'=>'resource'],
'PDF_get_errnum' => ['int', 'pdfdoc'=>'resource'],
'PDF_get_majorversion' => ['int'],
'PDF_get_minorversion' => ['int'],
'PDF_get_parameter' => ['string', 'p'=>'resource', 'key'=>'string', 'modifier'=>'float'],
'PDF_get_pdi_parameter' => ['string', 'p'=>'resource', 'key'=>'string', 'doc'=>'int', 'page'=>'int', 'reserved'=>'int'],
'PDF_get_pdi_value' => ['float', 'p'=>'resource', 'key'=>'string', 'doc'=>'int', 'page'=>'int', 'reserved'=>'int'],
'PDF_get_value' => ['float', 'p'=>'resource', 'key'=>'string', 'modifier'=>'float'],
'PDF_info_font' => ['float', 'pdfdoc'=>'resource', 'font'=>'int', 'keyword'=>'string', 'optlist'=>'string'],
'PDF_info_matchbox' => ['float', 'pdfdoc'=>'resource', 'boxname'=>'string', 'num'=>'int', 'keyword'=>'string'],
'PDF_info_table' => ['float', 'pdfdoc'=>'resource', 'table'=>'int', 'keyword'=>'string'],
'PDF_info_textflow' => ['float', 'pdfdoc'=>'resource', 'textflow'=>'int', 'keyword'=>'string'],
'PDF_info_textline' => ['float', 'pdfdoc'=>'resource', 'text'=>'string', 'keyword'=>'string', 'optlist'=>'string'],
'PDF_initgraphics' => ['bool', 'p'=>'resource'],
'PDF_lineto' => ['bool', 'p'=>'resource', 'x'=>'float', 'y'=>'float'],
'PDF_load_3ddata' => ['int', 'pdfdoc'=>'resource', 'filename'=>'string', 'optlist'=>'string'],
'PDF_load_font' => ['int', 'pdfdoc'=>'resource', 'fontname'=>'string', 'encoding'=>'string', 'optlist'=>'string'],
'PDF_load_iccprofile' => ['int', 'pdfdoc'=>'resource', 'profilename'=>'string', 'optlist'=>'string'],
'PDF_load_image' => ['int', 'pdfdoc'=>'resource', 'imagetype'=>'string', 'filename'=>'string', 'optlist'=>'string'],
'PDF_makespotcolor' => ['int', 'p'=>'resource', 'spotname'=>'string'],
'PDF_moveto' => ['bool', 'p'=>'resource', 'x'=>'float', 'y'=>'float'],
'PDF_new' => ['resource'],
'PDF_open_ccitt' => ['int', 'pdfdoc'=>'resource', 'filename'=>'string', 'width'=>'int', 'height'=>'int', 'bitreverse'=>'int', 'k'=>'int', 'blackls1'=>'int'],
'PDF_open_file' => ['bool', 'p'=>'resource', 'filename'=>'string'],
'PDF_open_image' => ['int', 'p'=>'resource', 'imagetype'=>'string', 'source'=>'string', 'data'=>'string', 'length'=>'int', 'width'=>'int', 'height'=>'int', 'components'=>'int', 'bpc'=>'int', 'params'=>'string'],
'PDF_open_image_file' => ['int', 'p'=>'resource', 'imagetype'=>'string', 'filename'=>'string', 'stringparam'=>'string', 'intparam'=>'int'],
'PDF_open_memory_image' => ['int', 'p'=>'resource', 'image'=>'resource'],
'PDF_open_pdi' => ['int', 'pdfdoc'=>'resource', 'filename'=>'string', 'optlist'=>'string', 'len'=>'int'],
'PDF_open_pdi_document' => ['int', 'p'=>'resource', 'filename'=>'string', 'optlist'=>'string'],
'PDF_open_pdi_page' => ['int', 'p'=>'resource', 'doc'=>'int', 'pagenumber'=>'int', 'optlist'=>'string'],
'PDF_pcos_get_number' => ['float', 'p'=>'resource', 'doc'=>'int', 'path'=>'string'],
'PDF_pcos_get_stream' => ['string', 'p'=>'resource', 'doc'=>'int', 'optlist'=>'string', 'path'=>'string'],
'PDF_pcos_get_string' => ['string', 'p'=>'resource', 'doc'=>'int', 'path'=>'string'],
'PDF_place_image' => ['bool', 'pdfdoc'=>'resource', 'image'=>'int', 'x'=>'float', 'y'=>'float', 'scale'=>'float'],
'PDF_place_pdi_page' => ['bool', 'pdfdoc'=>'resource', 'page'=>'int', 'x'=>'float', 'y'=>'float', 'sx'=>'float', 'sy'=>'float'],
'PDF_process_pdi' => ['int', 'pdfdoc'=>'resource', 'doc'=>'int', 'page'=>'int', 'optlist'=>'string'],
'PDF_rect' => ['bool', 'p'=>'resource', 'x'=>'float', 'y'=>'float', 'width'=>'float', 'height'=>'float'],
'PDF_restore' => ['bool', 'p'=>'resource'],
'PDF_resume_page' => ['bool', 'pdfdoc'=>'resource', 'optlist'=>'string'],
'PDF_rotate' => ['bool', 'p'=>'resource', 'phi'=>'float'],
'PDF_save' => ['bool', 'p'=>'resource'],
'PDF_scale' => ['bool', 'p'=>'resource', 'sx'=>'float', 'sy'=>'float'],
'PDF_set_border_color' => ['bool', 'p'=>'resource', 'red'=>'float', 'green'=>'float', 'blue'=>'float'],
'PDF_set_border_dash' => ['bool', 'pdfdoc'=>'resource', 'black'=>'float', 'white'=>'float'],
'PDF_set_border_style' => ['bool', 'pdfdoc'=>'resource', 'style'=>'string', 'width'=>'float'],
'PDF_set_gstate' => ['bool', 'pdfdoc'=>'resource', 'gstate'=>'int'],
'PDF_set_info' => ['bool', 'p'=>'resource', 'key'=>'string', 'value'=>'string'],
'PDF_set_layer_dependency' => ['bool', 'pdfdoc'=>'resource', 'type'=>'string', 'optlist'=>'string'],
'PDF_set_parameter' => ['bool', 'p'=>'resource', 'key'=>'string', 'value'=>'string'],
'PDF_set_text_pos' => ['bool', 'p'=>'resource', 'x'=>'float', 'y'=>'float'],
'PDF_set_value' => ['bool', 'p'=>'resource', 'key'=>'string', 'value'=>'float'],
'PDF_setcolor' => ['bool', 'p'=>'resource', 'fstype'=>'string', 'colorspace'=>'string', 'c1'=>'float', 'c2'=>'float', 'c3'=>'float', 'c4'=>'float'],
'PDF_setdash' => ['bool', 'pdfdoc'=>'resource', 'b'=>'float', 'w'=>'float'],
'PDF_setdashpattern' => ['bool', 'pdfdoc'=>'resource', 'optlist'=>'string'],
'PDF_setflat' => ['bool', 'pdfdoc'=>'resource', 'flatness'=>'float'],
'PDF_setfont' => ['bool', 'pdfdoc'=>'resource', 'font'=>'int', 'fontsize'=>'float'],
'PDF_setgray' => ['bool', 'p'=>'resource', 'g'=>'float'],
'PDF_setgray_fill' => ['bool', 'p'=>'resource', 'g'=>'float'],
'PDF_setgray_stroke' => ['bool', 'p'=>'resource', 'g'=>'float'],
'PDF_setlinecap' => ['bool', 'p'=>'resource', 'linecap'=>'int'],
'PDF_setlinejoin' => ['bool', 'p'=>'resource', 'value'=>'int'],
'PDF_setlinewidth' => ['bool', 'p'=>'resource', 'width'=>'float'],
'PDF_setmatrix' => ['bool', 'p'=>'resource', 'a'=>'float', 'b'=>'float', 'c'=>'float', 'd'=>'float', 'e'=>'float', 'f'=>'float'],
'PDF_setmiterlimit' => ['bool', 'pdfdoc'=>'resource', 'miter'=>'float'],
'PDF_setrgbcolor' => ['bool', 'p'=>'resource', 'red'=>'float', 'green'=>'float', 'blue'=>'float'],
'PDF_setrgbcolor_fill' => ['bool', 'p'=>'resource', 'red'=>'float', 'green'=>'float', 'blue'=>'float'],
'PDF_setrgbcolor_stroke' => ['bool', 'p'=>'resource', 'red'=>'float', 'green'=>'float', 'blue'=>'float'],
'PDF_shading' => ['int', 'pdfdoc'=>'resource', 'shtype'=>'string', 'x0'=>'float', 'y0'=>'float', 'x1'=>'float', 'y1'=>'float', 'c1'=>'float', 'c2'=>'float', 'c3'=>'float', 'c4'=>'float', 'optlist'=>'string'],
'PDF_shading_pattern' => ['int', 'pdfdoc'=>'resource', 'shading'=>'int', 'optlist'=>'string'],
'PDF_shfill' => ['bool', 'pdfdoc'=>'resource', 'shading'=>'int'],
'PDF_show' => ['bool', 'pdfdoc'=>'resource', 'text'=>'string'],
'PDF_show_boxed' => ['int', 'p'=>'resource', 'text'=>'string', 'left'=>'float', 'top'=>'float', 'width'=>'float', 'height'=>'float', 'mode'=>'string', 'feature'=>'string'],
'PDF_show_xy' => ['bool', 'p'=>'resource', 'text'=>'string', 'x'=>'float', 'y'=>'float'],
'PDF_skew' => ['bool', 'p'=>'resource', 'alpha'=>'float', 'beta'=>'float'],
'PDF_stringwidth' => ['float', 'p'=>'resource', 'text'=>'string', 'font'=>'int', 'fontsize'=>'float'],
'PDF_stroke' => ['bool', 'p'=>'resource'],
'PDF_suspend_page' => ['bool', 'pdfdoc'=>'resource', 'optlist'=>'string'],
'PDF_translate' => ['bool', 'p'=>'resource', 'tx'=>'float', 'ty'=>'float'],
'PDF_utf16_to_utf8' => ['string', 'pdfdoc'=>'resource', 'utf16string'=>'string'],
'PDF_utf32_to_utf16' => ['string', 'pdfdoc'=>'resource', 'utf32string'=>'string', 'ordering'=>'string'],
'PDF_utf8_to_utf16' => ['string', 'pdfdoc'=>'resource', 'utf8string'=>'string', 'ordering'=>'string'],
'PDO::__construct' => ['void', 'dsn'=>'string', 'username='=>'?string', 'passwd='=>'?string', 'options='=>'?array'],
'PDO::__sleep' => ['int'],
'PDO::__wakeup' => ['void'],
'PDO::beginTransaction' => ['bool'],
'PDO::commit' => ['bool'],
'PDO::cubrid_schema' => ['array', 'schema_type'=>'int', 'table_name='=>'string', 'col_name='=>'string'],
'PDO::errorCode' => ['string'],
'PDO::errorInfo' => ['array'],
'PDO::exec' => ['int', 'query'=>'string'],
'PDO::getAttribute' => ['', 'attribute'=>'int'],
'PDO::getAvailableDrivers' => ['array'],
'PDO::inTransaction' => ['bool'],
'PDO::lastInsertId' => ['string', 'seqname='=>'string'],
'PDO::pgsqlCopyFromArray' => ['bool', 'table_name'=>'string', 'rows'=>'array', 'delimiter'=>'string', 'null_as'=>'string', 'fields'=>'string'],
'PDO::pgsqlCopyFromFile' => ['bool', 'table_name'=>'string', 'filename'=>'string', 'delimiter'=>'string', 'null_as'=>'string', 'fields'=>'string'],
'PDO::pgsqlCopyToArray' => ['array', 'table_name'=>'string', 'delimiter'=>'string', 'null_as'=>'string', 'fields'=>'string'],
'PDO::pgsqlCopyToFile' => ['bool', 'table_name'=>'string', 'filename'=>'string', 'delimiter'=>'string', 'null_as'=>'string', 'fields'=>'string'],
'PDO::pgsqlGetNotify' => ['array', 'result_type'=>'int', 'ms_timeout'=>'int'],
'PDO::pgsqlGetPid' => ['int'],
'PDO::pgsqlLOBCreate' => ['string'],
'PDO::pgsqlLOBOpen' => ['resource', 'oid'=>'string', 'mode='=>'string'],
'PDO::pgsqlLOBUnlink' => ['bool', 'oid'=>'string'],
'PDO::prepare' => ['PDOStatement', 'statement'=>'string', 'options='=>'array'],
'PDO::query' => ['PDOStatement|false', 'sql'=>'string'],
'PDO::query\'1' => ['PDOStatement|false', 'sql'=>'string', 'fetch_column'=>'int', 'colno'=>'int'],
'PDO::query\'2' => ['PDOStatement|false', 'sql'=>'string', 'fetch_class'=>'int', 'classname'=>'string', 'ctorargs'=>'array'],
'PDO::query\'3' => ['PDOStatement|false', 'sql'=>'string', 'fetch_into'=>'int', 'object'=>'object'],
'PDO::quote' => ['string', 'string'=>'string', 'paramtype='=>'int'],
'PDO::rollBack' => ['bool'],
'PDO::setAttribute' => ['bool', 'attribute'=>'int', 'value'=>''],
'PDO::sqliteCreateAggregate' => ['bool', 'function_name'=>'string', 'step_func'=>'callable', 'finalize_func'=>'callable', 'num_args='=>'int'],
'PDO::sqliteCreateCollation' => ['bool', 'name'=>'string', 'callback'=>'callable'],
'PDO::sqliteCreateFunction' => ['bool', 'function_name'=>'string', 'callback'=>'callable', 'num_args='=>'int'],
'pdo_drivers' => ['array'],
'PDOException::getCode' => [''],
'PDOException::getFile' => [''],
'PDOException::getLine' => [''],
'PDOException::getMessage' => [''],
'PDOException::getPrevious' => [''],
'PDOException::getTrace' => [''],
'PDOException::getTraceAsString' => [''],
'PDOStatement::__sleep' => ['int'],
'PDOStatement::__wakeup' => ['void'],
'PDOStatement::bindColumn' => ['bool', 'column'=>'mixed', '&rw_param'=>'mixed', 'type='=>'int', 'maxlen='=>'int', 'driverdata='=>'mixed'],
'PDOStatement::bindParam' => ['bool', 'paramno'=>'mixed', '&rw_param'=>'mixed', 'type='=>'int', 'maxlen='=>'int', 'driverdata='=>'mixed'],
'PDOStatement::bindValue' => ['bool', 'paramno'=>'mixed', 'param'=>'mixed', 'type='=>'int'],
'PDOStatement::closeCursor' => ['bool'],
'PDOStatement::columnCount' => ['int'],
'PDOStatement::debugDumpParams' => ['void'],
'PDOStatement::errorCode' => ['string'],
'PDOStatement::errorInfo' => ['array'],
'PDOStatement::execute' => ['bool', 'bound_input_params='=>'?array'],
'PDOStatement::fetch' => ['mixed', 'how='=>'int', 'orientation='=>'int', 'offset='=>'int'],
'PDOStatement::fetchAll' => ['array|false', 'how='=>'int', 'fetch_argument='=>'int|string|callable', 'ctor_args='=>'?array'],
'PDOStatement::fetchColumn' => ['string|false', 'column_number='=>'int'],
'PDOStatement::fetchObject' => ['mixed', 'class_name='=>'string', 'ctor_args='=>'?array'],
'PDOStatement::getAttribute' => ['mixed', 'attribute'=>'int'],
'PDOStatement::getColumnMeta' => ['array', 'column'=>'int'],
'PDOStatement::nextRowset' => ['bool'],
'PDOStatement::rowCount' => ['int'],
'PDOStatement::setAttribute' => ['bool', 'attribute'=>'int', 'value'=>'mixed'],
'PDOStatement::setFetchMode' => ['bool', 'mode'=>'int'],
'PDOStatement::setFetchMode\'1' => ['bool', 'fetch_column'=>'int', 'colno'=>'int'],
'PDOStatement::setFetchMode\'2' => ['bool', 'fetch_class'=>'int', 'classname'=>'string', 'ctorargs'=>'array'],
'PDOStatement::setFetchMode\'3' => ['bool', 'fetch_into'=>'int', 'object'=>'object'],
'pfsockopen' => ['resource', 'hostname'=>'string', 'port='=>'int', '&w_errno='=>'int', '&w_errstr='=>'string', 'timeout='=>'float'],
'pg_affected_rows' => ['int', 'result'=>'resource'],
'pg_cancel_query' => ['bool', 'connection'=>'resource'],
'pg_client_encoding' => ['string', 'connection='=>'resource'],
'pg_close' => ['bool', 'connection='=>'resource'],
'pg_connect' => ['resource|false', 'connection_string'=>'string', 'connect_type='=>'int'],
'pg_connect_poll' => ['int', 'connection'=>'resource'],
'pg_connection_busy' => ['bool', 'connection'=>'resource'],
'pg_connection_reset' => ['bool', 'connection'=>'resource'],
'pg_connection_status' => ['int', 'connection'=>'resource'],
'pg_consume_input' => ['bool', 'connection'=>'resource'],
'pg_convert' => ['array', 'db'=>'resource', 'table'=>'string', 'values'=>'array', 'options='=>'int'],
'pg_copy_from' => ['bool', 'connection'=>'resource', 'table_name'=>'string', 'rows'=>'array', 'delimiter='=>'string', 'null_as='=>'string'],
'pg_copy_to' => ['array', 'connection'=>'resource', 'table_name'=>'string', 'delimiter='=>'string', 'null_as='=>'string'],
'pg_dbname' => ['string', 'connection='=>'resource'],
'pg_delete' => ['mixed', 'db'=>'resource', 'table'=>'string', 'ids'=>'array', 'options='=>'int'],
'pg_end_copy' => ['bool', 'connection='=>'resource'],
'pg_escape_bytea' => ['string', 'connection'=>'resource', 'data'=>'string'],
'pg_escape_bytea\'1' => ['string', 'data'=>'string'],
'pg_escape_identifier' => ['string', 'connection'=>'resource', 'data'=>'string'],
'pg_escape_identifier\'1' => ['string', 'data'=>'string'],
'pg_escape_literal' => ['string', 'connection'=>'resource', 'data'=>'string'],
'pg_escape_literal\'1' => ['string', 'data'=>'string'],
'pg_escape_string' => ['string', 'connection'=>'resource', 'data'=>'string'],
'pg_escape_string\'1' => ['string', 'data'=>'string'],
'pg_execute' => ['resource|false', 'connection'=>'resource', 'stmtname'=>'string', 'params'=>'array'],
'pg_execute\'1' => ['resource|false', 'stmtname'=>'string', 'params'=>'array'],
'pg_fetch_all' => ['array', 'result'=>'resource', 'result_type='=>'int'],
'pg_fetch_all_columns' => ['array', 'result'=>'resource', 'column_number='=>'int'],
'pg_fetch_array' => ['array', 'result'=>'resource', 'row='=>'?int', 'result_type='=>'int'],
'pg_fetch_assoc' => ['array', 'result'=>'resource', 'row='=>'?int'],
'pg_fetch_object' => ['object', 'result'=>'', 'row='=>'?int', 'result_type='=>'int'],
'pg_fetch_object\'1' => ['object', 'result'=>'', 'row='=>'?int', 'class_name='=>'string', 'ctor_params='=>'array'],
'pg_fetch_result' => ['', 'result'=>'', 'field_name'=>'string|int'],
'pg_fetch_result\'1' => ['', 'result'=>'', 'row_number'=>'int', 'field_name'=>'string|int'],
'pg_fetch_row' => ['array', 'result'=>'resource', 'row='=>'?int', 'result_type='=>'int'],
'pg_field_is_null' => ['int', 'result'=>'', 'field_name_or_number'=>'string|int'],
'pg_field_is_null\'1' => ['int', 'result'=>'', 'row'=>'int', 'field_name_or_number'=>'string|int'],
'pg_field_name' => ['string', 'result'=>'resource', 'field_number'=>'int'],
'pg_field_num' => ['int', 'result'=>'resource', 'field_name'=>'string'],
'pg_field_prtlen' => ['int', 'result'=>'', 'field_name_or_number'=>''],
'pg_field_prtlen\'1' => ['int', 'result'=>'', 'row'=>'int', 'field_name_or_number'=>'string|int'],
'pg_field_size' => ['int', 'result'=>'resource', 'field_number'=>'int'],
'pg_field_table' => ['mixed', 'result'=>'resource', 'field_number'=>'int', 'oid_only='=>'bool'],
'pg_field_type' => ['string', 'result'=>'resource', 'field_number'=>'int'],
'pg_field_type_oid' => ['string', 'result'=>'resource', 'field_number'=>'int'],
'pg_flush' => ['mixed', 'connection'=>'resource'],
'pg_free_result' => ['bool', 'result'=>'resource'],
'pg_get_notify' => ['array', 'connection'=>'resource', 'result_type='=>'int'],
'pg_get_pid' => ['int|false', 'connection'=>'resource'],
'pg_get_result' => ['resource|false', 'connection='=>'resource'],
'pg_host' => ['string', 'connection='=>'resource'],
'pg_insert' => ['mixed', 'db'=>'resource', 'table'=>'string', 'values'=>'array', 'options='=>'int'],
'pg_last_error' => ['string', 'connection='=>'resource', 'operation='=>'int'],
'pg_last_notice' => ['string', 'connection'=>'resource', 'option='=>'int'],
'pg_last_oid' => ['string', 'result'=>'resource'],
'pg_lo_close' => ['bool', 'large_object'=>'resource'],
'pg_lo_create' => ['int', 'connection='=>'resource', 'large_object_oid='=>''],
'pg_lo_export' => ['bool', 'connection'=>'resource', 'oid'=>'int', 'filename'=>'string'],
'pg_lo_export\'1' => ['bool', 'oid'=>'int', 'pathname'=>'string'],
'pg_lo_import' => ['int', 'connection'=>'resource', 'pathname'=>'string', 'oid'=>''],
'pg_lo_import\'1' => ['int', 'pathname'=>'string', 'oid'=>''],
'pg_lo_open' => ['resource|false', 'connection'=>'resource', 'oid'=>'int', 'mode'=>'string'],
'pg_lo_read' => ['string', 'large_object'=>'resource', 'len='=>'int'],
'pg_lo_read_all' => ['int', 'large_object'=>'resource'],
'pg_lo_seek' => ['bool', 'large_object'=>'resource', 'offset'=>'int', 'whence='=>'int'],
'pg_lo_tell' => ['int', 'large_object'=>'resource'],
'pg_lo_truncate' => ['bool', 'large_object'=>'resource', 'size'=>'int'],
'pg_lo_unlink' => ['bool', 'connection'=>'resource', 'oid'=>'int'],
'pg_lo_write' => ['int', 'large_object'=>'resource', 'data'=>'string', 'len='=>'int'],
'pg_meta_data' => ['array', 'db'=>'resource', 'table'=>'string', 'extended='=>'bool'],
'pg_num_fields' => ['int', 'result'=>'resource'],
'pg_num_rows' => ['int', 'result'=>'resource'],
'pg_options' => ['string', 'connection='=>'resource'],
'pg_parameter_status' => ['string|false', 'connection'=>'resource', 'param_name'=>'string'],
'pg_parameter_status\'1' => ['string|false', 'param_name'=>'string'],
'pg_pconnect' => ['resource|false', 'connection_string'=>'string', 'host='=>'string', 'port='=>'string|int', 'options='=>'string', 'tty='=>'string', 'database='=>'string'],
'pg_ping' => ['bool', 'connection='=>'resource'],
'pg_port' => ['int', 'connection='=>'resource'],
'pg_prepare' => ['resource|false', 'connection'=>'resource', 'stmtname'=>'string', 'query'=>'string'],
'pg_prepare\'1' => ['resource|false', 'stmtname'=>'string', 'query'=>'string'],
'pg_put_line' => ['bool', 'connection'=>'resource', 'data'=>'string'],
'pg_put_line\'1' => ['bool', 'data'=>'string'],
'pg_query' => ['resource|false', 'connection'=>'resource', 'query'=>'string'],
'pg_query\'1' => ['resource|false', 'query'=>'string'],
'pg_query_params' => ['resource|false', 'connection'=>'resource', 'query'=>'string', 'params'=>'array'],
'pg_query_params\'1' => ['resource|false', 'query'=>'string', 'params'=>'array'],
'pg_result_error' => ['string|false', 'result'=>'resource'],
'pg_result_error_field' => ['string|?false', 'result'=>'resource', 'fieldcode'=>'int'],
'pg_result_seek' => ['bool', 'result'=>'resource', 'offset'=>'int'],
'pg_result_status' => ['mixed', 'result'=>'resource', 'result_type='=>'int'],
'pg_select' => ['mixed', 'db'=>'resource', 'table'=>'string', 'ids'=>'array', 'options='=>'int', 'result_type='=>'int'],
'pg_send_execute' => ['bool', 'connection'=>'resource', 'stmtname'=>'string', 'params'=>'array'],
'pg_send_prepare' => ['bool', 'connection'=>'resource', 'stmtname'=>'string', 'query'=>'string'],
'pg_send_query' => ['bool', 'connection'=>'resource', 'query'=>'string'],
'pg_send_query_params' => ['bool', 'connection'=>'resource', 'query'=>'string', 'params'=>'array'],
'pg_set_client_encoding' => ['int', 'connection'=>'resource', 'encoding'=>'string'],
'pg_set_client_encoding\'1' => ['int', 'encoding'=>'string'],
'pg_set_error_verbosity' => ['int', 'connection'=>'resource', 'verbosity'=>'int'],
'pg_set_error_verbosity\'1' => ['int', 'verbosity'=>'int'],
'pg_socket' => ['resource|false', 'connection'=>'resource'],
'pg_trace' => ['bool', 'filename'=>'string', 'mode='=>'string', 'connection='=>'resource'],
'pg_transaction_status' => ['int', 'connection'=>'resource'],
'pg_tty' => ['string', 'connection='=>'resource'],
'pg_tty\'1' => ['string'],
'pg_unescape_bytea' => ['string', 'data'=>'string'],
'pg_untrace' => ['bool', 'connection='=>'resource'],
'pg_untrace\'1' => ['bool'],
'pg_update' => ['mixed', 'db'=>'resource', 'table'=>'string', 'fields'=>'array', 'ids'=>'array', 'options='=>'int'],
'pg_version' => ['array', 'connection='=>'resource'],
'Phar::__construct' => ['void', 'fname'=>'string', 'flags='=>'int', 'alias='=>'string'],
'Phar::addEmptyDir' => ['', 'dirname'=>'string'],
'Phar::addFile' => ['', 'file'=>'string', 'localname='=>'string'],
'Phar::addFromString' => ['', 'localname'=>'string', 'contents'=>'string'],
'Phar::apiVersion' => ['string'],
'Phar::buildFromDirectory' => ['array', 'base_dir'=>'string', 'regex='=>'string'],
'Phar::buildFromIterator' => ['array', 'iter'=>'iterator', 'base_directory='=>'string'],
'Phar::canCompress' => ['bool', 'method='=>'int'],
'Phar::canWrite' => ['bool'],
'Phar::compress' => ['object', 'compression'=>'int', 'extension='=>'string'],
'Phar::compressAllFilesBZIP2' => ['bool'],
'Phar::compressAllFilesGZ' => ['bool'],
'Phar::compressFiles' => ['', 'compression'=>'int'],
'Phar::convertToData' => ['PharData', 'format='=>'int', 'compression='=>'int', 'extension='=>'string'],
'Phar::convertToExecutable' => ['Phar', 'format='=>'int', 'compression='=>'int', 'extension='=>'string'],
'Phar::copy' => ['bool', 'oldfile'=>'string', 'newfile'=>'string'],
'Phar::count' => ['int'],
'Phar::createDefaultStub' => ['string', 'indexfile='=>'string', 'webindexfile='=>'string'],
'Phar::decompress' => ['object', 'extension='=>'string'],
'Phar::decompressFiles' => ['bool'],
'Phar::delete' => ['bool', 'entry'=>'string'],
'Phar::delMetadata' => ['bool'],
'Phar::extractTo' => ['bool', 'pathto'=>'string', 'files='=>'string|array', 'overwrite='=>'bool'],
'Phar::getAlias' => ['string'],
'Phar::getMetadata' => ['mixed'],
'Phar::getModified' => ['bool'],
'Phar::getPath' => ['string'],
'Phar::getSignature' => ['array'],
'Phar::getStub' => ['string'],
'Phar::getSupportedCompression' => ['array'],
'Phar::getSupportedSignatures' => ['array'],
'Phar::getVersion' => ['string'],
'Phar::hasMetadata' => ['bool'],
'Phar::interceptFileFuncs' => [''],
'Phar::isBuffering' => ['bool'],
'Phar::isCompressed' => [''],
'Phar::isFileFormat' => ['bool', 'format'=>'int'],
'Phar::isValidPharFilename' => ['bool', 'filename'=>'string', 'executable='=>'bool'],
'Phar::isWritable' => ['bool'],
'Phar::loadPhar' => ['bool', 'filename'=>'string', 'alias='=>'string'],
'Phar::mapPhar' => ['bool', 'alias='=>'string', 'dataoffset='=>'int'],
'Phar::mount' => ['void', 'pharpath'=>'string', 'externalpath'=>'string'],
'Phar::mungServer' => ['', 'munglist'=>'array'],
'Phar::offsetExists' => ['bool', 'offset'=>'string'],
'Phar::offsetGet' => ['int', 'offset'=>'string'],
'Phar::offsetSet' => ['', 'offset'=>'string', 'value'=>'string'],
'Phar::offsetUnset' => ['bool', 'offset'=>'string'],
'Phar::running' => ['string', 'retphar='=>'bool'],
'Phar::setAlias' => ['bool', 'alias'=>'string'],
'Phar::setDefaultStub' => ['bool', 'index='=>'string', 'webindex='=>'string'],
'Phar::setMetadata' => ['', 'metadata'=>''],
'Phar::setSignatureAlgorithm' => ['', 'sigtype'=>'int', 'privatekey='=>'string'],
'Phar::setStub' => ['bool', 'stub'=>'string'],
'Phar::startBuffering' => [''],
'Phar::stopBuffering' => [''],
'Phar::uncompressAllFiles' => ['bool'],
'Phar::unlinkArchive' => ['bool', 'archive'=>'string'],
'Phar::webPhar' => ['', 'alias='=>'string', 'index='=>'string', 'f404='=>'string', 'mimetypes='=>'array', 'rewrites='=>'array'],
'PharData::__construct' => ['void', 'fname'=>'string', 'flags='=>'int', 'alias='=>'string', 'format='=>'int'],
'PharData::addEmptyDir' => ['bool', 'dirname'=>'string'],
'PharData::addFile' => ['', 'file'=>'string', 'localname='=>'string'],
'PharData::addFromString' => ['bool', 'localname'=>'string', 'contents'=>'string'],
'PharData::buildFromDirectory' => ['array', 'base_dir'=>'string', 'regex='=>'string'],
'PharData::buildFromIterator' => ['array', 'iter'=>'iterator', 'base_directory='=>'string'],
'PharData::compress' => ['object', 'compression'=>'int', 'extension='=>'string'],
'PharData::compressFiles' => ['bool', 'compression'=>'int'],
'PharData::convertToData' => ['PharData', 'format='=>'int', 'compression='=>'int', 'extension='=>'string'],
'PharData::convertToExecutable' => ['Phar', 'format='=>'int', 'compression='=>'int', 'extension='=>'string'],
'PharData::copy' => ['bool', 'oldfile'=>'string', 'newfile'=>'string'],
'PharData::decompress' => ['object', 'extension='=>'string'],
'PharData::decompressFiles' => ['bool'],
'PharData::delete' => ['bool', 'entry'=>'string'],
'PharData::delMetadata' => ['bool'],
'PharData::extractTo' => ['bool', 'pathto'=>'string', 'files='=>'string|array', 'overwrite='=>'bool'],
'PharData::isWritable' => ['bool'],
'PharData::offsetSet' => ['', 'offset'=>'string', 'value'=>'string'],
'PharData::offsetUnset' => ['bool', 'offset'=>'string'],
'PharData::setAlias' => ['bool', 'alias'=>'string'],
'PharData::setDefaultStub' => ['bool', 'index='=>'string', 'webindex='=>'string'],
'PharData::setStub' => ['bool', 'stub'=>'string'],
'PharFileInfo::__construct' => ['void', 'entry'=>'string'],
'PharFileInfo::chmod' => ['void', 'permissions'=>'int'],
'PharFileInfo::compress' => ['bool', 'compression'=>'int'],
'PharFileInfo::decompress' => ['bool'],
'PharFileInfo::delMetadata' => ['bool'],
'PharFileInfo::getCompressedSize' => ['int'],
'PharFileInfo::getContent' => ['string'],
'PharFileInfo::getCRC32' => ['int'],
'PharFileInfo::getMetadata' => ['mixed'],
'PharFileInfo::getPharFlags' => ['int'],
'PharFileInfo::hasMetadata' => ['bool'],
'PharFileInfo::isCompressed' => ['bool', 'compression_type='=>'int'],
'PharFileInfo::isCompressedBZIP2' => ['bool'],
'PharFileInfo::isCompressedGZ' => ['bool'],
'PharFileInfo::isCRCChecked' => ['bool'],
'PharFileInfo::setCompressedBZIP2' => ['bool'],
'PharFileInfo::setCompressedGZ' => ['bool'],
'PharFileInfo::setMetadata' => ['void', 'metadata'=>'mixed'],
'PharFileInfo::setUncompressed' => ['bool'],
'phdfs::__construct' => ['void', 'ip'=>'string', 'port'=>'string'],
'phdfs::__destruct' => [''],
'phdfs::connect' => ['bool'],
'phdfs::copy' => ['bool', 'source_file'=>'string', 'destination_file'=>'string'],
'phdfs::create_directory' => ['bool', 'path'=>'string'],
'phdfs::delete' => ['bool', 'path'=>'string'],
'phdfs::disconnect' => ['bool'],
'phdfs::exists' => ['bool', 'path'=>'string'],
'phdfs::file_info' => ['array', 'path'=>'string'],
'phdfs::list_directory' => ['array', 'path'=>'string'],
'phdfs::read' => ['string', 'path'=>'string', 'length='=>'string'],
'phdfs::rename' => ['bool', 'old_path'=>'string', 'new_path'=>'string'],
'phdfs::tell' => ['int', 'path'=>'string'],
'phdfs::write' => ['bool', 'path'=>'string', 'buffer'=>'string', 'mode='=>'string'],
'php_check_syntax' => ['bool', 'filename'=>'string', 'error_message='=>'string'],
'php_ini_loaded_file' => ['string'],
'php_ini_scanned_files' => ['string'],
'php_logo_guid' => ['string'],
'php_sapi_name' => ['string'],
'php_strip_whitespace' => ['string', 'file_name'=>'string'],
'php_uname' => ['string', 'mode='=>'string'],
'php_user_filter::filter' => ['int', 'in'=>'resource', 'out'=>'resource', '&rw_consumed'=>'int', 'closing'=>'bool'],
'php_user_filter::onClose' => ['void'],
'php_user_filter::onCreate' => ['bool'],
'phpcredits' => ['bool', 'flag='=>'int'],
'phpdbg_break' => [''],
'phpdbg_break_file' => ['', 'file'=>'string', 'line'=>'int'],
'phpdbg_break_function' => ['', 'function'=>'string'],
'phpdbg_break_method' => ['', 'class'=>'string', 'method'=>'string'],
'phpdbg_clear' => [''],
'phpdbg_color' => ['', 'element'=>'int', 'color'=>'string'],
'phpdbg_end_oplog' => [''],
'phpdbg_prompt' => ['', 'prompt'=>'string'],
'phpdbg_start_oplog' => [''],
'phpinfo' => ['bool', 'what='=>'int'],
'phpversion' => ['string|false', 'extension='=>'string'],
'pht\AtomicInteger::__construct' => ['void', 'value='=>'int'],
'pht\AtomicInteger::dec' => ['void'],
'pht\AtomicInteger::get' => ['int'],
'pht\AtomicInteger::inc' => ['void'],
'pht\AtomicInteger::lock' => ['void'],
'pht\AtomicInteger::set' => ['void', 'value'=>'int'],
'pht\AtomicInteger::unlock' => ['void'],
'pht\HashTable::lock' => ['void'],
'pht\HashTable::size' => ['int'],
'pht\HashTable::unlock' => ['void'],
'pht\Queue::front' => ['mixed'],
'pht\Queue::lock' => ['void'],
'pht\Queue::pop' => ['mixed'],
'pht\Queue::push' => ['void', 'value'=>'mixed'],
'pht\Queue::size' => ['int'],
'pht\Queue::unlock' => ['void'],
'pht\Runnable::run' => ['void'],
'pht\Vector::__construct' => ['void', 'size='=>'int', 'value='=>'mixed'],
'pht\Vector::deleteAt' => ['void', 'offset'=>'int'],
'pht\Vector::insertAt' => ['void', 'value'=>'mixed', 'offset'=>'int'],
'pht\Vector::lock' => ['void'],
'pht\Vector::pop' => ['mixed'],
'pht\Vector::push' => ['void', 'value'=>'mixed'],
'pht\Vector::resize' => ['void', 'size'=>'int', 'value='=>'mixed'],
'pht\Vector::shift' => ['mixed'],
'pht\Vector::size' => ['int'],
'pht\Vector::unlock' => ['void'],
'pht\Vector::unshift' => ['void', 'value'=>'mixed'],
'pht\Vector::updateAt' => ['void', 'value'=>'mixed', 'offset'=>'int'],
'pi' => ['float'],
'png2wbmp' => ['bool', 'pngname'=>'string', 'wbmpname'=>'string', 'dest_height'=>'int', 'dest_width'=>'int', 'threshold'=>'int'],
'pointObj::__construct' => ['void'],
'pointObj::distanceToLine' => ['float', 'p1'=>'pointObj', 'p2'=>'pointObj'],
'pointObj::distanceToPoint' => ['float', 'poPoint'=>'pointObj'],
'pointObj::distanceToShape' => ['float', 'shape'=>'shapeObj'],
'pointObj::draw' => ['int', 'map'=>'MapObj', 'layer'=>'layerObj', 'img'=>'imageObj', 'class_index'=>'int', 'text'=>'string'],
'pointObj::ms_newPointObj' => ['pointObj'],
'pointObj::project' => ['int', 'in'=>'projectionObj', 'out'=>'projectionObj'],
'pointObj::setXY' => ['int', 'x'=>'float', 'y'=>'float', 'm'=>'float'],
'pointObj::setXYZ' => ['int', 'x'=>'float', 'y'=>'float', 'z'=>'float', 'm'=>'float'],
'Pool::__construct' => ['void', 'size'=>'int', 'class'=>'string', 'ctor='=>'array'],
'Pool::collect' => ['void', 'collector'=>'Callable'],
'Pool::resize' => ['void', 'size'=>'int'],
'Pool::shutdown' => ['void'],
'Pool::submit' => ['int', 'task'=>'Threaded'],
'Pool::submitTo' => ['int', 'worker'=>'int', 'task'=>'Threaded'],
'popen' => ['resource|false', 'command'=>'string', 'mode'=>'string'],
'pos' => ['mixed', 'array_arg'=>'array'],
'posix_access' => ['bool', 'file'=>'string', 'mode='=>'int'],
'posix_ctermid' => ['string'],
'posix_errno' => ['int'],
'posix_get_last_error' => ['int'],
'posix_getcwd' => ['string'],
'posix_getegid' => ['int'],
'posix_geteuid' => ['int'],
'posix_getgid' => ['int'],
'posix_getgrgid' => ['array', 'gid'=>'int'],
'posix_getgrnam' => ['array|false', 'groupname'=>'string'],
'posix_getgroups' => ['array'],
'posix_getlogin' => ['string'],
'posix_getpgid' => ['int', 'pid'=>'int'],
'posix_getpgrp' => ['int'],
'posix_getpid' => ['int'],
'posix_getppid' => ['int'],
'posix_getpwnam' => ['array|false', 'groupname'=>'string'],
'posix_getpwuid' => ['array', 'uid'=>'int'],
'posix_getrlimit' => ['array'],
'posix_getsid' => ['int', 'pid'=>'int'],
'posix_getuid' => ['int'],
'posix_initgroups' => ['bool', 'name'=>'string', 'base_group_id'=>'int'],
'posix_isatty' => ['bool', 'fd'=>'resource|int'],
'posix_kill' => ['bool', 'pid'=>'int', 'sig'=>'int'],
'posix_mkfifo' => ['bool', 'pathname'=>'string', 'mode'=>'int'],
'posix_mknod' => ['bool', 'pathname'=>'string', 'mode'=>'int', 'major='=>'int', 'minor='=>'int'],
'posix_setegid' => ['bool', 'uid'=>'int'],
'posix_seteuid' => ['bool', 'uid'=>'int'],
'posix_setgid' => ['bool', 'uid'=>'int'],
'posix_setpgid' => ['bool', 'pid'=>'int', 'pgid'=>'int'],
'posix_setrlimit' => ['bool', 'resource'=>'int', 'softlimit'=>'int', 'hardlimit'=>'int'],
'posix_setsid' => ['int'],
'posix_setuid' => ['bool', 'uid'=>'int'],
'posix_strerror' => ['string', 'errno'=>'int'],
'posix_times' => ['array'],
'posix_ttyname' => ['string|false', 'fd'=>'resource|int'],
'posix_uname' => ['array'],
'pow' => ['float|int', 'base'=>'int|float', 'exponent'=>'int|float'],
'preg_filter' => ['mixed', 'regex'=>'mixed', 'replace'=>'mixed', 'subject'=>'mixed', 'limit='=>'int', '&w_count='=>'int'],
'preg_grep' => ['array', 'regex'=>'string', 'input'=>'array', 'flags='=>'int'],
'preg_last_error' => ['int'],
'preg_match' => ['int|false', 'pattern'=>'string', 'subject'=>'string', '&w_subpatterns='=>'string[]', 'flags='=>'int', 'offset='=>'int'],
'preg_match_all' => ['int|false', 'pattern'=>'string', 'subject'=>'string', '&w_subpatterns='=>'array', 'flags='=>'int', 'offset='=>'int'],
'preg_quote' => ['string', 'str'=>'string', 'delim_char='=>'string'],
'preg_replace' => ['string|array|null', 'regex'=>'string|array', 'replace'=>'string|array', 'subject'=>'string|array', 'limit='=>'int', '&w_count='=>'int'],
'preg_replace_callback' => ['string|array|null', 'regex'=>'string|array', 'callback'=>'callable', 'subject'=>'string|array', 'limit='=>'int', '&w_count='=>'int'],
'preg_replace_callback_array' => ['string|array|null', 'pattern'=>'array', 'subject'=>'string|array', 'limit='=>'int', '&w_count='=>'int'],
'preg_split' => ['array|false', 'pattern'=>'string', 'subject'=>'string', 'limit='=>'?int', 'flags='=>'int'],
'prev' => ['mixed', '&rw_array_arg'=>'array|object'],
'print' => ['int', 'arg'=>'string'],
'print_r' => ['string|true', 'var'=>'mixed', 'return='=>'bool'],
'printf' => ['int', 'format'=>'string', '...args='=>'string|int|float'],
'proc_close' => ['int', 'process'=>'resource'],
'proc_get_status' => ['array', 'process'=>'resource'],
'proc_nice' => ['bool', 'priority'=>'int'],
'proc_open' => ['resource|false', 'command'=>'string', 'descriptorspec'=>'array', '&w_pipes'=>'resource[]', 'cwd='=>'?string', 'env='=>'?array', 'other_options='=>'array'],
'proc_terminate' => ['bool', 'process'=>'resource', 'signal='=>'int'],
'projectionObj::__construct' => ['void', 'projectionString'=>'string'],
'projectionObj::getUnits' => ['int'],
'projectionObj::ms_newProjectionObj' => ['projectionObj', 'projectionString'=>'string'],
'property_exists' => ['bool', 'object_or_class'=>'object|string', 'property_name'=>'string'],
'ps_add_bookmark' => ['int', 'psdoc'=>'resource', 'text'=>'string', 'parent='=>'int', 'open='=>'int'],
'ps_add_launchlink' => ['bool', 'psdoc'=>'resource', 'llx'=>'float', 'lly'=>'float', 'urx'=>'float', 'ury'=>'float', 'filename'=>'string'],
'ps_add_locallink' => ['bool', 'psdoc'=>'resource', 'llx'=>'float', 'lly'=>'float', 'urx'=>'float', 'ury'=>'float', 'page'=>'int', 'dest'=>'string'],
'ps_add_note' => ['bool', 'psdoc'=>'resource', 'llx'=>'float', 'lly'=>'float', 'urx'=>'float', 'ury'=>'float', 'contents'=>'string', 'title'=>'string', 'icon'=>'string', 'open'=>'int'],
'ps_add_pdflink' => ['bool', 'psdoc'=>'resource', 'llx'=>'float', 'lly'=>'float', 'urx'=>'float', 'ury'=>'float', 'filename'=>'string', 'page'=>'int', 'dest'=>'string'],
'ps_add_weblink' => ['bool', 'psdoc'=>'resource', 'llx'=>'float', 'lly'=>'float', 'urx'=>'float', 'ury'=>'float', 'url'=>'string'],
'ps_arc' => ['bool', 'psdoc'=>'resource', 'x'=>'float', 'y'=>'float', 'radius'=>'float', 'alpha'=>'float', 'beta'=>'float'],
'ps_arcn' => ['bool', 'psdoc'=>'resource', 'x'=>'float', 'y'=>'float', 'radius'=>'float', 'alpha'=>'float', 'beta'=>'float'],
'ps_begin_page' => ['bool', 'psdoc'=>'resource', 'width'=>'float', 'height'=>'float'],
'ps_begin_pattern' => ['int', 'psdoc'=>'resource', 'width'=>'float', 'height'=>'float', 'xstep'=>'float', 'ystep'=>'float', 'painttype'=>'int'],
'ps_begin_template' => ['int', 'psdoc'=>'resource', 'width'=>'float', 'height'=>'float'],
'ps_circle' => ['bool', 'psdoc'=>'resource', 'x'=>'float', 'y'=>'float', 'radius'=>'float'],
'ps_clip' => ['bool', 'psdoc'=>'resource'],
'ps_close' => ['bool', 'psdoc'=>'resource'],
'ps_close_image' => ['void', 'psdoc'=>'resource', 'imageid'=>'int'],
'ps_closepath' => ['bool', 'psdoc'=>'resource'],
'ps_closepath_stroke' => ['bool', 'psdoc'=>'resource'],
'ps_continue_text' => ['bool', 'psdoc'=>'resource', 'text'=>'string'],
'ps_curveto' => ['bool', 'psdoc'=>'resource', 'x1'=>'float', 'y1'=>'float', 'x2'=>'float', 'y2'=>'float', 'x3'=>'float', 'y3'=>'float'],
'ps_delete' => ['bool', 'psdoc'=>'resource'],
'ps_end_page' => ['bool', 'psdoc'=>'resource'],
'ps_end_pattern' => ['bool', 'psdoc'=>'resource'],
'ps_end_template' => ['bool', 'psdoc'=>'resource'],
'ps_fill' => ['bool', 'psdoc'=>'resource'],
'ps_fill_stroke' => ['bool', 'psdoc'=>'resource'],
'ps_findfont' => ['int', 'psdoc'=>'resource', 'fontname'=>'string', 'encoding'=>'string', 'embed='=>'bool'],
'ps_get_buffer' => ['string', 'psdoc'=>'resource'],
'ps_get_parameter' => ['string', 'psdoc'=>'resource', 'name'=>'string', 'modifier='=>'float'],
'ps_get_value' => ['float', 'psdoc'=>'resource', 'name'=>'string', 'modifier='=>'float'],
'ps_hyphenate' => ['array', 'psdoc'=>'resource', 'text'=>'string'],
'ps_include_file' => ['bool', 'psdoc'=>'resource', 'file'=>'string'],
'ps_lineto' => ['bool', 'psdoc'=>'resource', 'x'=>'float', 'y'=>'float'],
'ps_makespotcolor' => ['int', 'psdoc'=>'resource', 'name'=>'string', 'reserved='=>'int'],
'ps_moveto' => ['bool', 'psdoc'=>'resource', 'x'=>'float', 'y'=>'float'],
'ps_new' => ['resource'],
'ps_open_file' => ['bool', 'psdoc'=>'resource', 'filename='=>'string'],
'ps_open_image' => ['int', 'psdoc'=>'resource', 'type'=>'string', 'source'=>'string', 'data'=>'string', 'length'=>'int', 'width'=>'int', 'height'=>'int', 'components'=>'int', 'bpc'=>'int', 'params'=>'string'],
'ps_open_image_file' => ['int', 'psdoc'=>'resource', 'type'=>'string', 'filename'=>'string', 'stringparam='=>'string', 'intparam='=>'int'],
'ps_open_memory_image' => ['int', 'psdoc'=>'resource', 'gd'=>'int'],
'ps_place_image' => ['bool', 'psdoc'=>'resource', 'imageid'=>'int', 'x'=>'float', 'y'=>'float', 'scale'=>'float'],
'ps_rect' => ['bool', 'psdoc'=>'resource', 'x'=>'float', 'y'=>'float', 'width'=>'float', 'height'=>'float'],
'ps_restore' => ['bool', 'psdoc'=>'resource'],
'ps_rotate' => ['bool', 'psdoc'=>'resource', 'rot'=>'float'],
'ps_save' => ['bool', 'psdoc'=>'resource'],
'ps_scale' => ['bool', 'psdoc'=>'resource', 'x'=>'float', 'y'=>'float'],
'ps_set_border_color' => ['bool', 'psdoc'=>'resource', 'red'=>'float', 'green'=>'float', 'blue'=>'float'],
'ps_set_border_dash' => ['bool', 'psdoc'=>'resource', 'black'=>'float', 'white'=>'float'],
'ps_set_border_style' => ['bool', 'psdoc'=>'resource', 'style'=>'string', 'width'=>'float'],
'ps_set_info' => ['bool', 'p'=>'resource', 'key'=>'string', 'val'=>'string'],
'ps_set_parameter' => ['bool', 'psdoc'=>'resource', 'name'=>'string', 'value'=>'string'],
'ps_set_text_pos' => ['bool', 'psdoc'=>'resource', 'x'=>'float', 'y'=>'float'],
'ps_set_value' => ['bool', 'psdoc'=>'resource', 'name'=>'string', 'value'=>'float'],
'ps_setcolor' => ['bool', 'psdoc'=>'resource', 'type'=>'string', 'colorspace'=>'string', 'c1'=>'float', 'c2'=>'float', 'c3'=>'float', 'c4'=>'float'],
'ps_setdash' => ['bool', 'psdoc'=>'resource', 'on'=>'float', 'off'=>'float'],
'ps_setflat' => ['bool', 'psdoc'=>'resource', 'value'=>'float'],
'ps_setfont' => ['bool', 'psdoc'=>'resource', 'fontid'=>'int', 'size'=>'float'],
'ps_setgray' => ['bool', 'psdoc'=>'resource', 'gray'=>'float'],
'ps_setlinecap' => ['bool', 'psdoc'=>'resource', 'type'=>'int'],
'ps_setlinejoin' => ['bool', 'psdoc'=>'resource', 'type'=>'int'],
'ps_setlinewidth' => ['bool', 'psdoc'=>'resource', 'width'=>'float'],
'ps_setmiterlimit' => ['bool', 'psdoc'=>'resource', 'value'=>'float'],
'ps_setoverprintmode' => ['bool', 'psdoc'=>'resource', 'mode'=>'int'],
'ps_setpolydash' => ['bool', 'psdoc'=>'resource', 'arr'=>'float'],
'ps_shading' => ['int', 'psdoc'=>'resource', 'type'=>'string', 'x0'=>'float', 'y0'=>'float', 'x1'=>'float', 'y1'=>'float', 'c1'=>'float', 'c2'=>'float', 'c3'=>'float', 'c4'=>'float', 'optlist'=>'string'],
'ps_shading_pattern' => ['int', 'psdoc'=>'resource', 'shadingid'=>'int', 'optlist'=>'string'],
'ps_shfill' => ['bool', 'psdoc'=>'resource', 'shadingid'=>'int'],
'ps_show' => ['bool', 'psdoc'=>'resource', 'text'=>'string'],
'ps_show2' => ['bool', 'psdoc'=>'resource', 'text'=>'string', 'len'=>'int'],
'ps_show_boxed' => ['int', 'psdoc'=>'resource', 'text'=>'string', 'left'=>'float', 'bottom'=>'float', 'width'=>'float', 'height'=>'float', 'hmode'=>'string', 'feature='=>'string'],
'ps_show_xy' => ['bool', 'psdoc'=>'resource', 'text'=>'string', 'x'=>'float', 'y'=>'float'],
'ps_show_xy2' => ['bool', 'psdoc'=>'resource', 'text'=>'string', 'len'=>'int', 'xcoor'=>'float', 'ycoor'=>'float'],
'ps_string_geometry' => ['array', 'psdoc'=>'resource', 'text'=>'string', 'fontid='=>'int', 'size='=>'float'],
'ps_stringwidth' => ['float', 'psdoc'=>'resource', 'text'=>'string', 'fontid='=>'int', 'size='=>'float'],
'ps_stroke' => ['bool', 'psdoc'=>'resource'],
'ps_symbol' => ['bool', 'psdoc'=>'resource', 'ord'=>'int'],
'ps_symbol_name' => ['string', 'psdoc'=>'resource', 'ord'=>'int', 'fontid='=>'int'],
'ps_symbol_width' => ['float', 'psdoc'=>'resource', 'ord'=>'int', 'fontid='=>'int', 'size='=>'float'],
'ps_translate' => ['bool', 'psdoc'=>'resource', 'x'=>'float', 'y'=>'float'],
'pspell_add_to_personal' => ['bool', 'pspell'=>'int', 'word'=>'string'],
'pspell_add_to_session' => ['bool', 'pspell'=>'int', 'word'=>'string'],
'pspell_check' => ['bool', 'pspell'=>'int', 'word'=>'string'],
'pspell_clear_session' => ['bool', 'pspell'=>'int'],
'pspell_config_create' => ['int', 'language'=>'string', 'spelling='=>'string', 'jargon='=>'string', 'encoding='=>'string'],
'pspell_config_data_dir' => ['bool', 'conf'=>'int', 'directory'=>'string'],
'pspell_config_dict_dir' => ['bool', 'conf'=>'int', 'directory'=>'string'],
'pspell_config_ignore' => ['bool', 'conf'=>'int', 'ignore'=>'int'],
'pspell_config_mode' => ['bool', 'conf'=>'int', 'mode'=>'int'],
'pspell_config_personal' => ['bool', 'conf'=>'int', 'personal'=>'string'],
'pspell_config_repl' => ['bool', 'conf'=>'int', 'repl'=>'string'],
'pspell_config_runtogether' => ['bool', 'conf'=>'int', 'runtogether'=>'bool'],
'pspell_config_save_repl' => ['bool', 'conf'=>'int', 'save'=>'bool'],
'pspell_new' => ['int', 'language'=>'string', 'spelling='=>'string', 'jargon='=>'string', 'encoding='=>'string', 'mode='=>'int'],
'pspell_new_config' => ['int', 'config'=>'int'],
'pspell_new_personal' => ['int', 'personal'=>'string', 'language'=>'string', 'spelling='=>'string', 'jargon='=>'string', 'encoding='=>'string', 'mode='=>'int'],
'pspell_save_wordlist' => ['bool', 'pspell'=>'int'],
'pspell_store_replacement' => ['bool', 'pspell'=>'int', 'misspell'=>'string', 'correct'=>'string'],
'pspell_suggest' => ['array', 'pspell'=>'int', 'word'=>'string'],
'putenv' => ['bool', 'setting'=>'string'],
'px_close' => ['bool', 'pxdoc'=>'resource'],
'px_create_fp' => ['bool', 'pxdoc'=>'resource', 'file'=>'resource', 'fielddesc'=>'array'],
'px_date2string' => ['string', 'pxdoc'=>'resource', 'value'=>'int', 'format'=>'string'],
'px_delete' => ['bool', 'pxdoc'=>'resource'],
'px_delete_record' => ['bool', 'pxdoc'=>'resource', 'num'=>'int'],
'px_get_field' => ['array', 'pxdoc'=>'resource', 'fieldno'=>'int'],
'px_get_info' => ['array', 'pxdoc'=>'resource'],
'px_get_parameter' => ['string', 'pxdoc'=>'resource', 'name'=>'string'],
'px_get_record' => ['array', 'pxdoc'=>'resource', 'num'=>'int', 'mode='=>'int'],
'px_get_schema' => ['array', 'pxdoc'=>'resource', 'mode='=>'int'],
'px_get_value' => ['float', 'pxdoc'=>'resource', 'name'=>'string'],
'px_insert_record' => ['int', 'pxdoc'=>'resource', 'data'=>'array'],
'px_new' => ['resource'],
'px_numfields' => ['int', 'pxdoc'=>'resource'],
'px_numrecords' => ['int', 'pxdoc'=>'resource'],
'px_open_fp' => ['bool', 'pxdoc'=>'resource', 'file'=>'resource'],
'px_put_record' => ['bool', 'pxdoc'=>'resource', 'record'=>'array', 'recpos='=>'int'],
'px_retrieve_record' => ['array', 'pxdoc'=>'resource', 'num'=>'int', 'mode='=>'int'],
'px_set_blob_file' => ['bool', 'pxdoc'=>'resource', 'filename'=>'string'],
'px_set_parameter' => ['bool', 'pxdoc'=>'resource', 'name'=>'string', 'value'=>'string'],
'px_set_tablename' => ['void', 'pxdoc'=>'resource', 'name'=>'string'],
'px_set_targetencoding' => ['bool', 'pxdoc'=>'resource', 'encoding'=>'string'],
'px_set_value' => ['bool', 'pxdoc'=>'resource', 'name'=>'string', 'value'=>'float'],
'px_timestamp2string' => ['string', 'pxdoc'=>'resource', 'value'=>'float', 'format'=>'string'],
'px_update_record' => ['bool', 'pxdoc'=>'resource', 'data'=>'array', 'num'=>'int'],
'qdom_error' => ['string'],
'qdom_tree' => ['QDomDocument', 'doc'=>'string'],
'querymapObj::convertToString' => ['string'],
'querymapObj::free' => ['void'],
'querymapObj::set' => ['int', 'property_name'=>'string', 'new_value'=>''],
'querymapObj::updateFromString' => ['int', 'snippet'=>'string'],
'QuickHashIntHash::__construct' => ['void', 'size'=>'int', 'options='=>'int'],
'QuickHashIntHash::add' => ['bool', 'key'=>'int', 'value='=>'int'],
'QuickHashIntHash::delete' => ['bool', 'key'=>'int'],
'QuickHashIntHash::exists' => ['bool', 'key'=>'int'],
'QuickHashIntHash::get' => ['int', 'key'=>'int'],
'QuickHashIntHash::getSize' => ['int'],
'QuickHashIntHash::loadFromFile' => ['QuickHashIntHash', 'filename'=>'string', 'options='=>'int'],
'QuickHashIntHash::loadFromString' => ['QuickHashIntHash', 'contents'=>'string', 'options='=>'int'],
'QuickHashIntHash::saveToFile' => ['void', 'filename'=>'string'],
'QuickHashIntHash::saveToString' => ['string'],
'QuickHashIntHash::set' => ['bool', 'key'=>'int', 'value'=>'int'],
'QuickHashIntHash::update' => ['bool', 'key'=>'int', 'value'=>'int'],
'QuickHashIntSet::__construct' => ['void', 'size'=>'int', 'options='=>'int'],
'QuickHashIntSet::add' => ['bool', 'key'=>'int'],
'QuickHashIntSet::delete' => ['bool', 'key'=>'int'],
'QuickHashIntSet::exists' => ['bool', 'key'=>'int'],
'QuickHashIntSet::getSize' => ['int'],
'QuickHashIntSet::loadFromFile' => ['QuickHashIntSet', 'filename'=>'string', 'size='=>'int', 'options='=>'int'],
'QuickHashIntSet::loadFromString' => ['QuickHashIntSet', 'contents'=>'string', 'size='=>'int', 'options='=>'int'],
'QuickHashIntSet::saveToFile' => ['void', 'filename'=>'string'],
'QuickHashIntSet::saveToString' => ['string'],
'QuickHashIntStringHash::__construct' => ['void', 'size'=>'int', 'options='=>'int'],
'QuickHashIntStringHash::add' => ['bool', 'key'=>'int', 'value'=>'string'],
'QuickHashIntStringHash::delete' => ['bool', 'key'=>'int'],
'QuickHashIntStringHash::exists' => ['bool', 'key'=>'int'],
'QuickHashIntStringHash::get' => ['mixed', 'key'=>'int'],
'QuickHashIntStringHash::getSize' => ['int'],
'QuickHashIntStringHash::loadFromFile' => ['QuickHashIntStringHash', 'filename'=>'string', 'size='=>'int', 'options='=>'int'],
'QuickHashIntStringHash::loadFromString' => ['QuickHashIntStringHash', 'contents'=>'string', 'size='=>'int', 'options='=>'int'],
'QuickHashIntStringHash::saveToFile' => ['void', 'filename'=>'string'],
'QuickHashIntStringHash::saveToString' => ['string'],
'QuickHashIntStringHash::set' => ['int', 'key'=>'int', 'value'=>'string'],
'QuickHashIntStringHash::update' => ['bool', 'key'=>'int', 'value'=>'string'],
'QuickHashStringIntHash::__construct' => ['void', 'size'=>'int', 'options='=>'int'],
'QuickHashStringIntHash::add' => ['bool', 'key'=>'string', 'value'=>'int'],
'QuickHashStringIntHash::delete' => ['bool', 'key'=>'string'],
'QuickHashStringIntHash::exists' => ['bool', 'key'=>'string'],
'QuickHashStringIntHash::get' => ['mixed', 'key'=>'string'],
'QuickHashStringIntHash::getSize' => ['int'],
'QuickHashStringIntHash::loadFromFile' => ['QuickHashStringIntHash', 'filename'=>'string', 'size='=>'int', 'options='=>'int'],
'QuickHashStringIntHash::loadFromString' => ['QuickHashStringIntHash', 'contents'=>'string', 'size='=>'int', 'options='=>'int'],
'QuickHashStringIntHash::saveToFile' => ['void', 'filename'=>'string'],
'QuickHashStringIntHash::saveToString' => ['string'],
'QuickHashStringIntHash::set' => ['int', 'key'=>'string', 'value'=>'int'],
'QuickHashStringIntHash::update' => ['bool', 'key'=>'string', 'value'=>'int'],
'quoted_printable_decode' => ['string', 'str'=>'string'],
'quoted_printable_encode' => ['string', 'str'=>'string'],
'quotemeta' => ['string', 'str'=>'string'],
'rad2deg' => ['float', 'number'=>'float'],
'radius_acct_open' => ['resource'],
'radius_add_server' => ['bool', 'radius_handle'=>'resource', 'hostname'=>'string', 'port'=>'int', 'secret'=>'string', 'timeout'=>'int', 'max_tries'=>'int'],
'radius_auth_open' => ['resource'],
'radius_close' => ['bool', 'radius_handle'=>'resource'],
'radius_config' => ['bool', 'radius_handle'=>'resource', 'file'=>'string'],
'radius_create_request' => ['bool', 'radius_handle'=>'resource', 'type'=>'int'],
'radius_cvt_addr' => ['string', 'data'=>'string'],
'radius_cvt_int' => ['int', 'data'=>'string'],
'radius_cvt_string' => ['string', 'data'=>'string'],
'radius_demangle' => ['string', 'radius_handle'=>'resource', 'mangled'=>'string'],
'radius_demangle_mppe_key' => ['string', 'radius_handle'=>'resource', 'mangled'=>'string'],
'radius_get_attr' => ['mixed', 'radius_handle'=>'resource'],
'radius_get_tagged_attr_data' => ['string', 'data'=>'string'],
'radius_get_tagged_attr_tag' => ['int', 'data'=>'string'],
'radius_get_vendor_attr' => ['array', 'data'=>'string'],
'radius_put_addr' => ['bool', 'radius_handle'=>'resource', 'type'=>'int', 'addr'=>'string'],
'radius_put_attr' => ['bool', 'radius_handle'=>'resource', 'type'=>'int', 'value'=>'string'],
'radius_put_int' => ['bool', 'radius_handle'=>'resource', 'type'=>'int', 'value'=>'int'],
'radius_put_string' => ['bool', 'radius_handle'=>'resource', 'type'=>'int', 'value'=>'string'],
'radius_put_vendor_addr' => ['bool', 'radius_handle'=>'resource', 'vendor'=>'int', 'type'=>'int', 'addr'=>'string'],
'radius_put_vendor_attr' => ['bool', 'radius_handle'=>'resource', 'vendor'=>'int', 'type'=>'int', 'value'=>'string'],
'radius_put_vendor_int' => ['bool', 'radius_handle'=>'resource', 'vendor'=>'int', 'type'=>'int', 'value'=>'int'],
'radius_put_vendor_string' => ['bool', 'radius_handle'=>'resource', 'vendor'=>'int', 'type'=>'int', 'value'=>'string'],
'radius_request_authenticator' => ['string', 'radius_handle'=>'resource'],
'radius_salt_encrypt_attr' => ['string', 'radius_handle'=>'resource', 'data'=>'string'],
'radius_send_request' => ['int', 'radius_handle'=>'resource'],
'radius_server_secret' => ['string', 'radius_handle'=>'resource'],
'radius_strerror' => ['string', 'radius_handle'=>'resource'],
'rand' => ['int', 'min'=>'int', 'max'=>'int'],
'rand\'1' => ['int'],
'random_bytes' => ['string', 'length'=>'int'],
'random_int' => ['int', 'min'=>'int', 'max'=>'int'],
'range' => ['array', 'low'=>'mixed', 'high'=>'mixed', 'step='=>'int|float'],
'RangeException::__clone' => ['void'],
'RangeException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?RangeException'],
'RangeException::__toString' => ['string'],
'RangeException::getCode' => ['int'],
'RangeException::getFile' => ['string'],
'RangeException::getLine' => ['int'],
'RangeException::getMessage' => ['string'],
'RangeException::getPrevious' => ['Throwable|RangeException|null'],
'RangeException::getTrace' => ['array'],
'RangeException::getTraceAsString' => ['string'],
'rar_allow_broken_set' => ['bool', 'rarfile'=>'RarArchive', 'allow_broken'=>'bool'],
'rar_broken_is' => ['bool', 'rarfile'=>'rararchive'],
'rar_close' => ['bool', 'rarfile'=>'rararchive'],
'rar_comment_get' => ['string', 'rarfile'=>'rararchive'],
'rar_entry_get' => ['RarEntry', 'entryname'=>'string', 'rarfile'=>'rararchive'],
'rar_list' => ['RarArchive', 'rarfile'=>'rararchive'],
'rar_open' => ['RarArchive', 'filename'=>'string', 'password='=>'string', 'volume_callback='=>'callable'],
'rar_solid_is' => ['bool', 'rarfile'=>'rararchive'],
'rar_wrapper_cache_stats' => ['string'],
'RarArchive::__toString' => ['string'],
'RarArchive::close' => ['bool', 'rarfile'=>'rararchive'],
'RarArchive::getComment' => ['string', 'rarfile'=>'rararchive'],
'RarArchive::getEntries' => ['RarArchive', 'rarfile'=>'rararchive'],
'RarArchive::getEntry' => ['RarEntry', 'entryname'=>'string', 'rarfile'=>'rararchive'],
'RarArchive::isBroken' => ['bool', 'rarfile'=>'rararchive'],
'RarArchive::isSolid' => ['bool', 'rarfile'=>'rararchive'],
'RarArchive::open' => ['RarArchive', 'filename'=>'string', 'password='=>'string', 'volume_callback='=>'callable'],
'RarArchive::setAllowBroken' => ['bool', 'allow_broken'=>'bool', 'rarfile'=>'rararchive'],
'RarEntry::__toString' => ['string'],
'RarEntry::extract' => ['bool', 'dir'=>'string', 'filepath='=>'string', 'password='=>'string', 'extended_data='=>'bool'],
'RarEntry::getAttr' => ['int'],
'RarEntry::getCrc' => ['string'],
'RarEntry::getFileTime' => ['string'],
'RarEntry::getHostOs' => ['int'],
'RarEntry::getMethod' => ['int'],
'RarEntry::getName' => ['string'],
'RarEntry::getPackedSize' => ['int'],
'RarEntry::getStream' => ['resource', 'password='=>'string'],
'RarEntry::getUnpackedSize' => ['int'],
'RarEntry::getVersion' => ['int'],
'RarEntry::isDirectory' => ['bool'],
'RarEntry::isEncrypted' => ['bool'],
'RarException::getCode' => ['int'],
'RarException::getFile' => ['string'],
'RarException::getLine' => ['int'],
'RarException::getMessage' => ['string'],
'RarException::getPrevious' => ['Exception|Throwable'],
'RarException::getTrace' => ['array'],
'RarException::getTraceAsString' => ['string'],
'RarException::isUsingExceptions' => ['bool'],
'RarException::setUsingExceptions' => ['RarEntry', 'using_exceptions'=>'bool'],
'rawurldecode' => ['string', 'str'=>'string'],
'rawurlencode' => ['string', 'str'=>'string'],
'read_exif_data' => ['array', 'filename'=>'string', 'sections_needed='=>'string', 'sub_arrays='=>'bool', 'read_thumbnail='=>'bool'],
'readdir' => ['string|false', 'dir_handle='=>'resource'],
'readfile' => ['int|false', 'filename'=>'string', 'use_include_path='=>'bool', 'context='=>'resource'],
'readgzfile' => ['int|false', 'filename'=>'string', 'use_include_path='=>'int'],
'readline' => ['string', 'prompt='=>'?string'],
'readline_add_history' => ['bool', 'prompt'=>'string'],
'readline_callback_handler_install' => ['bool', 'prompt'=>'string', 'callback'=>'callable'],
'readline_callback_handler_remove' => ['bool'],
'readline_callback_read_char' => ['void'],
'readline_clear_history' => ['bool'],
'readline_completion_function' => ['bool', 'funcname'=>'callable'],
'readline_info' => ['mixed', 'varname='=>'string', 'newvalue='=>'string'],
'readline_list_history' => ['array'],
'readline_on_new_line' => ['void'],
'readline_read_history' => ['bool', 'filename='=>'string'],
'readline_redisplay' => ['void'],
'readline_write_history' => ['bool', 'filename='=>'string'],
'readlink' => ['string', 'filename'=>'string'],
'realpath' => ['string|false', 'path'=>'string'],
'realpath_cache_get' => ['array'],
'realpath_cache_size' => ['int'],
'recode' => ['string', 'request'=>'string', 'str'=>'string'],
'recode_file' => ['bool', 'request'=>'string', 'input'=>'resource', 'output'=>'resource'],
'recode_string' => ['string', 'request'=>'string', 'str'=>'string'],
'rectObj::__construct' => ['void'],
'rectObj::draw' => ['int', 'map'=>'MapObj', 'layer'=>'layerObj', 'img'=>'imageObj', 'class_index'=>'int', 'text'=>'string'],
'rectObj::fit' => ['float', 'width'=>'int', 'height'=>'int'],
'rectObj::ms_newRectObj' => ['rectObj'],
'rectObj::project' => ['int', 'in'=>'projectionObj', 'out'=>'projectionObj'],
'rectObj::set' => ['int', 'property_name'=>'string', 'new_value'=>''],
'rectObj::setextent' => ['void', 'minx'=>'float', 'miny'=>'float', 'maxx'=>'float', 'maxy'=>'float'],
'RecursiveArrayIterator::getChildren' => ['RecursiveArrayIterator'],
'RecursiveArrayIterator::hasChildren' => ['bool'],
'RecursiveCachingIterator::__construct' => ['void', 'it'=>'Iterator', 'flags'=>''],
'RecursiveCachingIterator::getChildren' => ['RecursiveCachingIterator'],
'RecursiveCachingIterator::hasChildren' => ['bool'],
'RecursiveCallbackFilterIterator::__construct' => ['void', 'it'=>'recursiveiterator', 'func'=>'callable'],
'RecursiveCallbackFilterIterator::getChildren' => ['RecursiveCallbackFilterIterator'],
'RecursiveCallbackFilterIterator::hasChildren' => ['void'],
'RecursiveDirectoryIterator::__construct' => ['void', 'path'=>'string', 'flags='=>'int'],
'RecursiveDirectoryIterator::getChildren' => ['object'],
'RecursiveDirectoryIterator::getSubPath' => ['string'],
'RecursiveDirectoryIterator::getSubPathname' => ['string'],
'RecursiveDirectoryIterator::hasChildren' => ['bool', 'allow_links='=>'bool'],
'RecursiveDirectoryIterator::key' => ['string'],
'RecursiveDirectoryIterator::next' => ['void'],
'RecursiveDirectoryIterator::rewind' => ['void'],
'RecursiveFilterIterator::__construct' => ['void', 'it'=>'recursiveiterator'],
'RecursiveFilterIterator::getChildren' => ['RecursiveFilterIterator'],
'RecursiveFilterIterator::hasChildren' => ['bool'],
'RecursiveIterator::getChildren' => ['RecursiveIterator'],
'RecursiveIterator::hasChildren' => ['bool'],
'RecursiveIteratorIterator::__construct' => ['void', 'it'=>'RecursiveIterator|IteratorAggregate', 'mode='=>'int', 'flags='=>'int'],
'RecursiveIteratorIterator::beginChildren' => ['void'],
'RecursiveIteratorIterator::beginIteration' => ['RecursiveIterator'],
'RecursiveIteratorIterator::callGetChildren' => ['RecursiveIterator'],
'RecursiveIteratorIterator::callHasChildren' => ['bool'],
'RecursiveIteratorIterator::current' => ['mixed'],
'RecursiveIteratorIterator::endChildren' => ['void'],
'RecursiveIteratorIterator::endIteration' => ['RecursiveIterator'],
'RecursiveIteratorIterator::getDepth' => ['int'],
'RecursiveIteratorIterator::getInnerIterator' => ['RecursiveIterator'],
'RecursiveIteratorIterator::getMaxDepth' => ['int|false'],
'RecursiveIteratorIterator::getSubIterator' => ['RecursiveIterator', 'level='=>'int'],
'RecursiveIteratorIterator::key' => ['mixed'],
'RecursiveIteratorIterator::next' => ['void'],
'RecursiveIteratorIterator::nextElement' => ['void'],
'RecursiveIteratorIterator::rewind' => ['void'],
'RecursiveIteratorIterator::setMaxDepth' => ['void', 'max_depth='=>'int'],
'RecursiveIteratorIterator::valid' => ['bool'],
'RecursiveRegexIterator::__construct' => ['void', 'it'=>'recursiveiterator', 'regex='=>'string', 'mode='=>'int', 'flags='=>'int', 'preg_flags='=>'int'],
'RecursiveRegexIterator::getChildren' => ['RecursiveRegexIterator'],
'RecursiveRegexIterator::hasChildren' => ['bool'],
'RecursiveTreeIterator::__construct' => ['void', 'it'=>'recursiveiterator|iteratoraggregate', 'flags'=>'int', 'cit_flags'=>'int', 'mode'=>'int'],
'RecursiveTreeIterator::beginChildren' => ['void'],
'RecursiveTreeIterator::beginIteration' => ['RecursiveIterator'],
'RecursiveTreeIterator::callGetChildren' => ['RecursiveIterator'],
'RecursiveTreeIterator::callHasChildren' => ['bool'],
'RecursiveTreeIterator::current' => ['string'],
'RecursiveTreeIterator::endChildren' => ['void'],
'RecursiveTreeIterator::endIteration' => ['void'],
'RecursiveTreeIterator::getEntry' => ['string'],
'RecursiveTreeIterator::getPostfix' => ['string'],
'RecursiveTreeIterator::getPrefix' => ['string'],
'RecursiveTreeIterator::key' => ['string'],
'RecursiveTreeIterator::next' => ['void'],
'RecursiveTreeIterator::nextElement' => ['void'],
'RecursiveTreeIterator::rewind' => ['void'],
'RecursiveTreeIterator::setPostfix' => ['void', 'prefix'=>'string'],
'RecursiveTreeIterator::setPrefixPart' => ['void', 'part'=>'int', 'prefix'=>'string'],
'RecursiveTreeIterator::valid' => ['bool'],
'Redis::__construct' => ['void'],
'Redis::_prefix' => ['string', 'value'=>'mixed'],
'Redis::_serialize' => ['mixed', 'value'=>'mixed'],
'Redis::_unserialize' => ['mixed', 'value'=>'string'],
'Redis::append' => ['int', 'key'=>'string', 'value'=>'string'],
'Redis::auth' => ['bool', 'password'=>'string'],
'Redis::bgRewriteAOF' => ['bool'],
'Redis::bgSave' => ['bool'],
'Redis::bitCount' => ['int', 'key'=>'string'],
'Redis::bitOp' => ['int', 'operation'=>'string', '...args'=>'string'],
'Redis::bitpos' => ['int', 'key'=>'string', 'bit'=>'int', 'start='=>'int', 'end='=>'int'],
'Redis::blPop' => ['array', 'keys'=>'array', 'timeout'=>'int'],
'Redis::brPop' => ['array', 'keys'=>'array', 'timeout'=>'int'],
'Redis::brpoplpush' => ['string|false', 'srcKey'=>'string', 'dstKey'=>'string', 'timeout'=>'int'],
'Redis::clearLastError' => ['bool'],
'Redis::client' => ['mixed', 'command'=>'string', 'arg='=>'string'],
'Redis::close' => ['void'],
'Redis::config' => ['string', 'key'=>'string', 'value='=>'string'],
'Redis::connect' => ['bool', 'host'=>'string', 'port='=>'int', 'timeout='=>'float', 'retry_interval='=>'?int'],
'Redis::dbSize' => ['int'],
'Redis::decr' => ['int', 'key'=>'string'],
'Redis::decrBy' => ['int', 'key'=>'string', 'value'=>'int'],
'Redis::decrByFloat' => ['float', 'key'=>'string', 'value'=>'float'],
'Redis::del' => ['bool', 'key'=>'string', '...args'=>'string'],
'Redis::del\'1' => ['bool', 'key'=>'string[]'],
'Redis::delete' => ['bool', 'key'=>'string', '...args'=>'string'],
'Redis::delete\'1' => ['bool', 'key'=>'string[]'],
'Redis::discard' => [''],
'Redis::dump' => ['string|false', 'key'=>'string'],
'Redis::echo' => ['string', 'message'=>'string'],
'Redis::eval' => ['mixed', 'script'=>'', 'args='=>'', 'numKeys='=>''],
'Redis::evalSha' => ['mixed', 'scriptSha'=>'string', 'args='=>'array', 'numKeys='=>'int'],
'Redis::evaluate' => ['mixed', 'script'=>'string', 'args='=>'array', 'numKeys='=>'int'],
'Redis::evaluateSha' => ['', 'scriptSha'=>'string', 'args='=>'array', 'numKeys='=>'int'],
'Redis::exec' => ['array'],
'Redis::exists' => ['bool', 'key'=>'string'],
'Redis::expire' => ['bool', 'key'=>'string', 'ttl'=>'int'],
'Redis::expireAt' => ['bool', 'key'=>'string', 'expiry'=>'int'],
'Redis::flushAll' => ['bool'],
'Redis::flushDb' => ['bool'],
'Redis::get' => ['string|false', 'key'=>'string'],
'Redis::getBit' => ['int', 'key'=>'string', 'offset'=>'int'],
'Redis::getKeys' => ['array', 'pattern'=>'string'],
'Redis::getLastError' => ['null|string'],
'Redis::getMode' => ['int'],
'Redis::getMultiple' => ['array', 'keys'=>'string[]'],
'Redis::getOption' => ['int', 'name'=>'int'],
'Redis::getRange' => ['int', 'key'=>'string', 'start'=>'int', 'end'=>'int'],
'Redis::getSet' => ['string', 'key'=>'string', 'string'=>'string'],
'Redis::hDel' => ['int|false', 'key'=>'string', 'hashKey1'=>'string', 'hashKey2='=>'string', 'hashKeyN='=>'string'],
'Redis::hExists' => ['bool', 'key'=>'string', 'hashKey'=>'string'],
'Redis::hGet' => ['string|false', 'key'=>'string', 'hashKey'=>'string'],
'Redis::hGetAll' => ['array', 'key'=>'string'],
'Redis::hIncrBy' => ['int', 'key'=>'string', 'hashKey'=>'string', 'value'=>'int'],
'Redis::hIncrByFloat' => ['float', 'key'=>'string', 'field'=>'string', 'increment'=>'float'],
'Redis::hKeys' => ['array', 'key'=>'string'],
'Redis::hLen' => ['int|false', 'key'=>'string'],
'Redis::hMGet' => ['array', 'key'=>'string', 'hashKeys'=>'array'],
'Redis::hMSet' => ['bool', 'key'=>'string', 'hashKeys'=>'array'],
'Redis::hScan' => ['array', 'key'=>'string', 'iterator'=>'int', 'pattern='=>'string', 'count='=>'int'],
'Redis::hSet' => ['int|false', 'key'=>'string', 'hashKey'=>'string', 'value'=>'string'],
'Redis::hSetNx' => ['bool', 'key'=>'string', 'hashKey'=>'string', 'value'=>'string'],
'Redis::hVals' => ['array', 'key'=>'string'],
'Redis::incr' => ['int', 'key'=>'string'],
'Redis::incrBy' => ['int', 'key'=>'string', 'value'=>'int'],
'Redis::incrByFloat' => ['float', 'key'=>'string'],
'Redis::info' => ['array', 'option='=>'string'],
'Redis::keys' => ['array', 'pattern'=>'string'],
'Redis::lastSave' => ['int'],
'Redis::lGet' => ['', 'key'=>'string', 'index'=>'int'],
'Redis::lGetRange' => ['', 'key'=>'string', 'start'=>'int', 'end'=>'int'],
'Redis::lIndex' => ['string|false', 'key'=>'string', 'index'=>'int'],
'Redis::lInsert' => ['int', 'key'=>'string', 'position'=>'int', 'pivot'=>'string', 'value'=>'string'],
'Redis::listTrim' => ['', 'key'=>'string', 'start'=>'int', 'stop'=>'int'],
'Redis::lLen' => ['int|false', 'key'=>'string'],
'Redis::lPop' => ['string', 'key'=>'string'],
'Redis::lPush' => ['bool|int', 'key'=>'string', 'value1'=>'string', 'value2='=>'string', 'valueN='=>'string'],
'Redis::lPushx' => ['int', 'key'=>'string', 'value'=>'string'],
'Redis::lRange' => ['array', 'key'=>'string', 'start'=>'int', 'end'=>'int'],
'Redis::lRem' => ['int|false', 'key'=>'string', 'value'=>'string', 'count'=>'int'],
'Redis::lRemove' => ['', 'key'=>'string', 'value'=>'string', 'count'=>'int'],
'Redis::lSet' => ['bool', 'key'=>'string', 'index'=>'int', 'value'=>'string'],
'Redis::lSize' => ['', 'key'=>'string'],
'Redis::lTrim' => ['array|false', 'key'=>'string', 'start'=>'int', 'stop'=>'int'],
'Redis::mGet' => ['array', 'keys'=>'string[]'],
'Redis::migrate' => ['bool', 'host'=>'string', 'port'=>'int', 'db'=>'int', 'timeout'=>'int', 'copy='=>'bool', 'replace='=>'bool'],
'Redis::move' => ['bool', 'key'=>'string', 'dbindex'=>'int'],
'Redis::mSet' => ['bool', 'pairs'=>'array'],
'Redis::mSetNx' => ['bool', 'pairs'=>'array'],
'Redis::multi' => ['Redis', 'mode='=>'int'],
'Redis::object' => ['string|long|false', 'info'=>'string', 'key'=>'string'],
'Redis::open' => ['bool', 'host'=>'string', 'port='=>'int', 'timeout='=>'float', 'retry_interval='=>'?int'],
'Redis::pconnect' => ['bool', 'host'=>'string', 'port='=>'int', 'timeout='=>'float', 'persistent_id='=>'string', 'retry_interval='=>'?int'],
'Redis::persist' => ['bool', 'key'=>'string'],
'Redis::pExpire' => ['bool', 'key'=>'string', 'ttl'=>'int'],
'Redis::pexpireAt' => ['bool', 'key'=>'string', 'expiry'=>'int'],
'Redis::pfAdd' => ['bool', 'key'=>'string', 'elements'=>'array'],
'Redis::pfCount' => ['int', 'key'=>'array|string'],
'Redis::pfMerge' => ['bool', 'destkey'=>'string', 'sourcekeys'=>'array'],
'Redis::ping' => ['string'],
'Redis::popen' => ['bool', 'host'=>'string', 'port='=>'int', 'timeout='=>'float', 'persistent_id='=>'string', 'retry_interval='=>'?int'],
'Redis::psetex' => ['bool', 'key'=>'string', 'ttl'=>'int', 'value'=>'string'],
'Redis::psubscribe' => ['', 'patterns'=>'array', 'callback'=>'array|string'],
'Redis::pttl' => ['int|false', 'key'=>'string'],
'Redis::publish' => ['int', 'channel'=>'string', 'message'=>'string'],
'Redis::pubsub' => ['array|int', 'keyword'=>'string', 'argument'=>'array|string'],
'Redis::randomKey' => ['string'],
'Redis::rawCommand' => ['mixed', 'command'=>'string', 'arguments'=>'mixed'],
'Redis::rename' => ['bool', 'srckey'=>'string', 'dstkey'=>'string'],
'Redis::renameKey' => ['bool', 'srckey'=>'string', 'dstkey'=>'string'],
'Redis::renameNx' => ['bool', 'srckey'=>'string', 'dstkey'=>'string'],
'Redis::resetStat' => ['bool'],
'Redis::restore' => ['bool', 'key'=>'string', 'ttl'=>'int', 'value'=>'string'],
'Redis::rPop' => ['string', 'key'=>'string'],
'Redis::rpoplpush' => ['string', 'srcKey'=>'string', 'dstKey'=>'string'],
'Redis::rPush' => ['bool|int', 'key'=>'string', 'value1'=>'string', 'value2='=>'string', 'valueN='=>'string'],
'Redis::rPushx' => ['int', 'key'=>'string', 'value'=>'string'],
'Redis::sAdd' => ['int|false', 'key'=>'string', 'value1'=>'string', 'value2='=>'string', 'valueN='=>'string'],
'Redis::sAddArray' => ['bool', 'key'=>'string', 'values'=>'array'],
'Redis::save' => ['bool'],
'Redis::scan' => ['array|false', '&rw_iterator'=>'?int', 'pattern='=>'?string', 'count='=>'?int'],
'Redis::sCard' => ['int', 'key'=>'string'],
'Redis::sContains' => ['', 'key'=>'string', 'value'=>'string'],
'Redis::script' => ['mixed', 'command'=>'string', 'script'=>'string'],
'Redis::sDiff' => ['array', 'key1'=>'string', 'key2'=>'string', 'keyN='=>'string'],
'Redis::sDiffStore' => ['int|false', 'dstKey'=>'string', 'key1'=>'string', 'key2'=>'string', 'keyN='=>'string'],
'Redis::select' => ['bool', 'dbindex'=>'int'],
'Redis::set' => ['bool', 'key'=>'string', 'value'=>'string', 'options='=>'array'],
'Redis::set\'1' => ['bool', 'key'=>'string', 'value'=>'string', 'timeout='=>'int'],
'Redis::setBit' => ['int', 'key'=>'string', 'offset'=>'int', 'value'=>'int'],
'Redis::setEx' => ['bool', 'key'=>'string', 'ttl'=>'int', 'value'=>'string'],
'Redis::setex' => ['bool', 'key'=>'string', 'ttl'=>'int', 'value'=>'string'],
'Redis::setNx' => ['bool', 'key'=>'string', 'value'=>'string'],
'Redis::setnx' => ['bool', 'key'=>'string', 'value'=>'string'],
'Redis::setOption' => ['bool', 'name'=>'int', 'value'=>'string'],
'Redis::setRange' => ['int', 'key'=>'string', 'offset'=>'int', 'end'=>'int'],
'Redis::setTimeout' => ['', 'key'=>'string', 'ttl'=>'int'],
'Redis::sGetMembers' => ['', 'key'=>'string'],
'Redis::sInter' => ['array|false', 'key1'=>'string', 'key2'=>'string', 'keyN='=>'string'],
'Redis::sInterStore' => ['int|false', 'dstKey'=>'string', 'key1'=>'string', 'key2'=>'string', 'keyN='=>'string'],
'Redis::sIsMember' => ['bool', 'key'=>'string', 'value'=>'string'],
'Redis::slave' => ['bool', 'host'=>'string', 'port'=>'int'],
'Redis::slave\'1' => ['bool', 'host'=>'string', 'port'=>'int'],
'Redis::slaveof' => ['bool', 'host='=>'string', 'port='=>'int'],
'Redis::slowLog' => ['mixed', 'operation'=>'string', 'length='=>'int'],
'Redis::sMembers' => ['array', 'key'=>'string'],
'Redis::sMove' => ['bool', 'srcKey'=>'string', 'dstKey'=>'string', 'member'=>'string'],
'Redis::sort' => ['array|int', 'options='=>'?array'],
'Redis::sPop' => ['string|false', 'key'=>'string'],
'Redis::sRandMember' => ['array|string|false', 'key'=>'string', 'count='=>'int'],
'Redis::sRem' => ['int', 'key'=>'string', 'member1'=>'string', 'member2='=>'string', 'memberN='=>'string'],
'Redis::sRemove' => ['', 'key'=>'string', 'member1'=>'string', 'member2='=>'string', 'memberN='=>'string'],
'Redis::sScan' => ['array|bool', 'key'=>'string', 'iterator'=>'int', 'pattern='=>'string', 'count='=>'int'],
'Redis::strLen' => ['int', 'key'=>'string'],
'Redis::subscribe' => ['', 'channels'=>'array', 'callback'=>'string'],
'Redis::substr' => ['', 'key'=>'string', 'start'=>'int', 'end'=>'int'],
'Redis::sUnion' => ['array', 'key1'=>'string', 'key2'=>'string', 'keyN='=>'string'],
'Redis::sUnionStore' => ['int', 'dstKey'=>'string', 'key1'=>'string', 'key2'=>'string', 'keyN='=>'string'],
'Redis::time' => ['array'],
'Redis::ttl' => ['int|false', 'key'=>'string'],
'Redis::type' => ['int', 'key'=>'string'],
'Redis::unwatch' => [''],
'Redis::wait' => ['int', 'numSlaves'=>'int', 'timeout'=>'int'],
'Redis::watch' => ['void', 'key'=>'string'],
'Redis::zAdd' => ['int', 'key'=>'string', 'score1'=>'float', 'value1'=>'string', 'score2='=>'float', 'value2='=>'string', 'scoreN='=>'float', 'valueN='=>'string'],
'Redis::zCard' => ['int', 'key'=>'string'],
'Redis::zCount' => ['int', 'key'=>'string', 'start'=>'string', 'end'=>'string'],
'Redis::zDelete' => ['int', 'key'=>'string', 'member1'=>'string', 'member2='=>'string', 'memberN='=>'string'],
'Redis::zDeleteRangeByRank' => ['', 'key'=>'string', 'start'=>'int', 'end'=>'int'],
'Redis::zDeleteRangeByScore' => ['', 'key'=>'string', 'start'=>'float', 'end'=>'float'],
'Redis::zIncrBy' => ['float', 'key'=>'string', 'value'=>'float', 'member'=>'string'],
'Redis::zInter' => ['int', 'Output'=>'string', 'ZSetKeys'=>'array', 'Weights='=>'?array', 'aggregateFunction='=>'string'],
'Redis::zRange' => ['array', 'key'=>'string', 'start'=>'int', 'end'=>'int', 'withscores='=>'bool'],
'Redis::zRangeByLex' => ['array|false', 'key'=>'string', 'min'=>'int', 'max'=>'int', 'offset='=>'int', 'limit='=>'int'],
'Redis::zRangeByScore' => ['array', 'key'=>'string', 'start'=>'int', 'end'=>'int', 'options='=>'array'],
'Redis::zRank' => ['int', 'key'=>'string', 'member'=>'string'],
'Redis::zRem' => ['int', 'key'=>'string', 'member1'=>'string', 'member2='=>'string', 'memberN='=>'string'],
'Redis::zRemRangeByRank' => ['int', 'key'=>'string', 'start'=>'int', 'end'=>'int'],
'Redis::zRemRangeByScore' => ['int', 'key'=>'string', 'start'=>'float|string', 'end'=>'float|string'],
'Redis::zRevRange' => ['array', 'key'=>'string', 'start'=>'int', 'end'=>'int', 'withscore='=>'bool'],
'Redis::zRevRangeByLex' => ['array', 'key'=>'string', 'min'=>'int', 'max'=>'int', 'offset='=>'int', 'limit='=>'int'],
'Redis::zRevRangeByScore' => ['array', 'key'=>'string', 'start'=>'int', 'end'=>'int', 'options='=>'array'],
'Redis::zRevRank' => ['int', 'key'=>'string', 'member'=>'string'],
'Redis::zScan' => ['array|bool', 'key'=>'string', 'iterator'=>'int', 'pattern='=>'string', 'count='=>'int'],
'Redis::zScore' => ['float', 'key'=>'string', 'member'=>'string'],
'Redis::zSize' => ['', 'key'=>'string'],
'Redis::zUnion' => ['int', 'Output'=>'string', 'ZSetKeys'=>'array', 'Weights='=>'?array', 'aggregateFunction='=>'string'],
'RedisArray::__construct' => ['void', 'name='=>'string', 'hosts='=>'?array', 'opts='=>'?array'],
'RedisArray::_function' => ['string'],
'RedisArray::_hosts' => ['array'],
'RedisArray::_rehash' => [''],
'RedisArray::_target' => ['string', 'key'=>'string'],
'RedisCluster::__construct' => ['void', 'name'=>'string', 'seeds'=>'array', 'timeout='=>'float', 'readTimeout='=>'float', 'persistent='=>'bool|false'],
'RedisCluster::_masters' => ['array'],
'RedisCluster::_prefix' => ['string', 'value'=>'mixed'],
'RedisCluster::_serialize' => ['mixed', 'value'=>'mixed'],
'RedisCluster::_unserialize' => ['mixed', 'value'=>'string'],
'RedisCluster::append' => ['int', 'key'=>'string', 'value'=>'string'],
'RedisCluster::bgrewriteaof' => ['bool', 'nodeParams'=>'string'],
'RedisCluster::bgsave' => ['bool', 'nodeParams'=>'string'],
'RedisCluster::bitCount' => ['int', 'key'=>'string'],
'RedisCluster::bitOp' => ['int', 'operation'=>'string', 'retKey'=>'string', 'key1'=>'string', 'key2'=>'string', 'key3='=>'string'],
'RedisCluster::bitpos' => ['int', 'key'=>'string', 'bit'=>'int', 'start='=>'int', 'end='=>'int'],
'RedisCluster::blPop' => ['array', 'keys'=>'array', 'timeout'=>'int'],
'RedisCluster::brPop' => ['array', 'keys'=>'array', 'timeout'=>'int'],
'RedisCluster::brpoplpush' => ['string', 'srcKey'=>'string', 'dstKey'=>'string', 'timeout'=>'int'],
'RedisCluster::clearLastError' => ['bool'],
'RedisCluster::client' => ['', 'nodeParams'=>'string', 'subCmd'=>'', 'args'=>''],
'RedisCluster::close' => [''],
'RedisCluster::cluster' => ['mixed', 'nodeParams'=>'string', 'command'=>'string', 'arguments'=>'mixed'],
'RedisCluster::command' => ['mixed'],
'RedisCluster::config' => ['array', 'nodeParams'=>'string', 'operation'=>'string', 'key'=>'string', 'value'=>'string'],
'RedisCluster::dbSize' => ['int', 'nodeParams'=>'string'],
'RedisCluster::decr' => ['int', 'key'=>'string'],
'RedisCluster::decrBy' => ['int', 'key'=>'string', 'value'=>'int'],
'RedisCluster::del' => ['int', 'key1'=>'int', 'key2='=>'string', 'key3='=>'string'],
'RedisCluster::discard' => [''],
'RedisCluster::dump' => ['string', 'key'=>'string'],
'RedisCluster::echo' => ['mixed', 'nodeParams'=>'string', 'msg'=>'string'],
'RedisCluster::eval' => ['mixed', 'script'=>'', 'args='=>'', 'numKeys='=>''],
'RedisCluster::evalSha' => ['mixed', 'scriptSha'=>'string', 'args='=>'array', 'numKeys='=>'int'],
'RedisCluster::exec' => ['array|void'],
'RedisCluster::exists' => ['bool', 'key'=>'string'],
'RedisCluster::expire' => ['bool', 'key'=>'string', 'ttl'=>'int'],
'RedisCluster::expireAt' => ['bool', 'key'=>'string', 'timestamp'=>'int'],
'RedisCluster::flushAll' => ['bool', 'nodeParams'=>'string'],
'RedisCluster::flushDB' => ['bool', 'nodeParams'=>'string'],
'RedisCluster::geoAdd' => ['', 'key'=>'string', 'longitude'=>'float', 'latitude'=>'float', 'member'=>'string'],
'RedisCluster::geoDist' => ['', 'key'=>'string', 'member1'=>'string', 'member2'=>'string', 'unit='=>'string'],
'RedisCluster::geohash' => ['', 'key'=>'', 'member1'=>'', 'member2='=>'mixed', 'memberN='=>'mixed'],
'RedisCluster::geopos' => ['', 'key'=>'', 'member1'=>'', 'member2='=>'mixed', 'memberN='=>'mixed'],
'RedisCluster::geoRadius' => ['', 'key'=>'string', 'longitude'=>'float', 'latitude'=>'float', 'radius'=>'float', 'radiusUnit'=>'string', 'options'=>'array'],
'RedisCluster::geoRadiusByMember' => ['', 'key'=>'string', 'member'=>'string', 'radius'=>'float', 'radiusUnit'=>'string', 'options'=>'array'],
'RedisCluster::get' => ['bool|string', 'key'=>'string'],
'RedisCluster::getBit' => ['int', 'key'=>'string', 'offset'=>'int'],
'RedisCluster::getLastError' => ['string'],
'RedisCluster::getMode' => ['int'],
'RedisCluster::getOption' => ['int', 'name'=>'string'],
'RedisCluster::getRange' => ['string', 'key'=>'string', 'start'=>'int', 'end'=>'int'],
'RedisCluster::getSet' => ['string', 'key'=>'string', 'value'=>'string'],
'RedisCluster::hDel' => ['int', 'key'=>'string', 'hashKey1'=>'string', 'hashKey2='=>'string', 'hashKeyN='=>'string'],
'RedisCluster::hExists' => ['bool', 'key'=>'string', 'hashKey'=>'string'],
'RedisCluster::hGet' => ['string', 'key'=>'string', 'hashKey'=>'string'],
'RedisCluster::hGetAll' => ['array', 'key'=>'string'],
'RedisCluster::hIncrBy' => ['int', 'key'=>'string', 'hashKey'=>'string', 'value'=>'int'],
'RedisCluster::hIncrByFloat' => ['float', 'key'=>'string', 'field'=>'string', 'increment'=>'float'],
'RedisCluster::hKeys' => ['array', 'key'=>'string'],
'RedisCluster::hLen' => ['int', 'key'=>'string'],
'RedisCluster::hMGet' => ['array', 'key'=>'string', 'hashKeys'=>'array'],
'RedisCluster::hMSet' => ['bool', 'key'=>'string', 'hashKeys'=>'array'],
'RedisCluster::hScan' => ['array', 'key'=>'string', '&iterator'=>'int', 'pattern='=>'string', 'count='=>'int'],
'RedisCluster::hSet' => ['int', 'key'=>'string', 'hashKey'=>'string', 'value'=>'string'],
'RedisCluster::hSetNx' => ['bool', 'key'=>'string', 'hashKey'=>'string', 'value'=>'string'],
'RedisCluster::hVals' => ['array', 'key'=>'string'],
'RedisCluster::incr' => ['int', 'key'=>'string'],
'RedisCluster::incrBy' => ['int', 'key'=>'string', 'value'=>'int'],
'RedisCluster::incrByFloat' => ['float', 'key'=>'string', 'increment'=>'float'],
'RedisCluster::info' => ['string', 'option='=>'string'],
'RedisCluster::keys' => ['array', 'pattern'=>'string'],
'RedisCluster::lastSave' => ['int', 'nodeParams'=>'string'],
'RedisCluster::lGet' => ['', 'key'=>'string', 'index'=>'int'],
'RedisCluster::lIndex' => ['string', 'key'=>'string', 'index'=>'int'],
'RedisCluster::lInsert' => ['int', 'key'=>'string', 'position'=>'int', 'pivot'=>'string', 'value'=>'string'],
'RedisCluster::lLen' => ['int', 'key'=>'string'],
'RedisCluster::lPop' => ['string', 'key'=>'string'],
'RedisCluster::lPush' => ['int', 'key'=>'string', 'value1'=>'string', 'value2='=>'string', 'valueN='=>'string'],
'RedisCluster::lPushx' => ['int', 'key'=>'string', 'value'=>'string'],
'RedisCluster::lRange' => ['array', 'key'=>'string', 'start'=>'int', 'end'=>'int'],
'RedisCluster::lRem' => ['int', 'key'=>'string', 'value'=>'string', 'count'=>'int'],
'RedisCluster::lSet' => ['bool', 'key'=>'string', 'index'=>'int', 'value'=>'string'],
'RedisCluster::lTrim' => ['array', 'key'=>'string', 'start'=>'int', 'stop'=>'int'],
'RedisCluster::mget' => ['array', 'array'=>'array'],
'RedisCluster::mset' => ['bool', 'array'=>'array'],
'RedisCluster::msetnx' => ['int', 'array'=>'array'],
'RedisCluster::multi' => ['Redis', 'mode='=>'int'],
'RedisCluster::object' => ['string', 'string='=>'string', 'key='=>'string'],
'RedisCluster::persist' => ['bool', 'key'=>'string'],
'RedisCluster::pExpire' => ['bool', 'key'=>'string', 'ttl'=>'int'],
'RedisCluster::pExpireAt' => ['bool', 'key'=>'string', 'timestamp'=>'int'],
'RedisCluster::pfAdd' => ['bool', 'key'=>'string', 'elements'=>'array'],
'RedisCluster::pfCount' => ['int', 'key'=>'string'],
'RedisCluster::pfMerge' => ['bool', 'destKey'=>'string', 'sourceKeys'=>'array'],
'RedisCluster::ping' => ['string', 'nodeParams'=>'string'],
'RedisCluster::psetex' => ['bool', 'key'=>'string', 'ttl'=>'int', 'value'=>'string'],
'RedisCluster::psubscribe' => ['mixed', 'patterns'=>'array', 'callback'=>'string'],
'RedisCluster::pttl' => ['int', 'key'=>'string'],
'RedisCluster::publish' => ['int', 'channel'=>'string', 'message'=>'string'],
'RedisCluster::pubsub' => ['array', 'nodeParams'=>'string', 'keyword'=>'string', 'argument'=>'string'],
'RedisCluster::punSubscribe' => ['', 'channels'=>'', 'callback'=>''],
'RedisCluster::randomKey' => ['string', 'nodeParams'=>'string'],
'RedisCluster::rawCommand' => ['mixed', 'nodeParams'=>'string', 'command'=>'string', 'arguments'=>'mixed'],
'RedisCluster::rename' => ['bool', 'srcKey'=>'string', 'dstKey'=>'string'],
'RedisCluster::renameNx' => ['bool', 'srcKey'=>'string', 'dstKey'=>'string'],
'RedisCluster::restore' => ['bool', 'key'=>'string', 'ttl'=>'int', 'value'=>'string'],
'RedisCluster::role' => ['array', 'nodeParams'=>'string'],
'RedisCluster::rPop' => ['string', 'key'=>'string'],
'RedisCluster::rpoplpush' => ['string', 'srcKey'=>'string', 'dstKey'=>'string'],
'RedisCluster::rPush' => ['int', 'key'=>'string', 'value1'=>'string', 'value2='=>'string', 'valueN='=>'string'],
'RedisCluster::rPushx' => ['int', 'key'=>'string', 'value'=>'string'],
'RedisCluster::sAdd' => ['int', 'key'=>'string', 'value1'=>'string', 'value2='=>'string', 'valueN='=>'string'],
'RedisCluster::sAddArray' => ['int', 'key'=>'string', 'valueArray'=>'array'],
'RedisCluster::save' => ['bool', 'nodeParams'=>'string'],
'RedisCluster::scan' => ['array', '&iterator'=>'int', 'pattern='=>'string', 'count='=>'int'],
'RedisCluster::sCard' => ['int', 'key'=>'string'],
'RedisCluster::script' => ['mixed', 'nodeParams'=>'string', 'command'=>'string', 'script'=>'string'],
'RedisCluster::sDiff' => ['array', 'key1'=>'string', 'key2'=>'string', 'keyN='=>'string'],
'RedisCluster::sDiffStore' => ['int', 'dstKey'=>'string', 'key1'=>'string', 'key2'=>'string', 'keyN='=>'string'],
'RedisCluster::set' => ['bool', 'key'=>'string', 'value'=>'string', 'timeout='=>'array|int'],
'RedisCluster::setBit' => ['int', 'key'=>'string', 'offset'=>'int', 'value'=>'bool|int'],
'RedisCluster::setex' => ['bool', 'key'=>'string', 'ttl'=>'int', 'value'=>'string'],
'RedisCluster::setnx' => ['bool', 'key'=>'string', 'value'=>'string'],
'RedisCluster::setOption' => ['bool', 'name'=>'string', 'value'=>'string'],
'RedisCluster::setRange' => ['string', 'key'=>'string', 'offset'=>'int', 'value'=>'string'],
'RedisCluster::sInter' => ['array', 'key1'=>'string', 'key2'=>'string', 'keyN='=>'string'],
'RedisCluster::sInterStore' => ['int', 'dstKey'=>'string', 'key1'=>'string', 'key2'=>'string', 'keyN='=>'string'],
'RedisCluster::sIsMember' => ['bool', 'key'=>'string', 'value'=>'string'],
'RedisCluster::slowLog' => ['', 'nodeParams'=>'string', 'command'=>'string', 'argument'=>'mixed'],
'RedisCluster::sMembers' => ['array', 'key'=>'string'],
'RedisCluster::sMove' => ['bool', 'srcKey'=>'string', 'dstKey'=>'string', 'member'=>'string'],
'RedisCluster::sort' => ['array', 'key'=>'string', 'option='=>'array'],
'RedisCluster::sPop' => ['string', 'key'=>'string'],
'RedisCluster::sRandMember' => ['array|string', 'key'=>'string', 'count='=>'int'],
'RedisCluster::sRem' => ['int', 'key'=>'string', 'member1'=>'string', 'member2='=>'string', 'memberN='=>'string'],
'RedisCluster::sScan' => ['array', 'key'=>'string', '&iterator'=>'int', 'pattern='=>'null', 'count='=>'int'],
'RedisCluster::strlen' => ['int', 'key'=>'string'],
'RedisCluster::subscribe' => ['mixed', 'channels'=>'array', 'callback'=>'string'],
'RedisCluster::sUnion' => ['array', 'key1'=>'string', 'key2'=>'string', 'keyN='=>'string'],
'RedisCluster::sUnionStore' => ['int', 'dstKey'=>'string', 'key1'=>'string', 'key2'=>'string', 'keyN='=>'string'],
'RedisCluster::time' => ['array', 'nodeParams'=>'string'],
'RedisCluster::ttl' => ['int', 'key'=>'string'],
'RedisCluster::type' => ['int', 'key'=>'string'],
'RedisCluster::unSubscribe' => ['', 'channels'=>'', 'callback'=>''],
'RedisCluster::unwatch' => [''],
'RedisCluster::watch' => ['void', 'key'=>'string'],
'RedisCluster::zAdd' => ['int', 'key'=>'string', 'score1'=>'float', 'value1'=>'string', 'score2='=>'float', 'value2='=>'string', 'scoreN='=>'float', 'valueN='=>'string'],
'RedisCluster::zCard' => ['int', 'key'=>'string'],
'RedisCluster::zCount' => ['int', 'key'=>'string', 'start'=>'string', 'end'=>'string'],
'RedisCluster::zIncrBy' => ['float', 'key'=>'string', 'value'=>'float', 'member'=>'string'],
'RedisCluster::zInterStore' => ['int', 'Output'=>'string', 'ZSetKeys'=>'array', 'Weights='=>'?array', 'aggregateFunction='=>'string'],
'RedisCluster::zLexCount' => ['int', 'key'=>'string', 'min'=>'int', 'max'=>'int'],
'RedisCluster::zRange' => ['array', 'key'=>'string', 'start'=>'int', 'end'=>'int', 'withscores='=>'bool'],
'RedisCluster::zRangeByLex' => ['array', 'key'=>'string', 'min'=>'int', 'max'=>'int', 'offset='=>'int', 'limit='=>'int'],
'RedisCluster::zRangeByScore' => ['array', 'key'=>'string', 'start'=>'int', 'end'=>'int', 'options='=>'array'],
'RedisCluster::zRank' => ['int', 'key'=>'string', 'member'=>'string'],
'RedisCluster::zRem' => ['int', 'key'=>'string', 'member1'=>'string', 'member2='=>'string', 'memberN='=>'string'],
'RedisCluster::zRemRangeByLex' => ['array', 'key'=>'string', 'min'=>'int', 'max'=>'int'],
'RedisCluster::zRemRangeByRank' => ['int', 'key'=>'string', 'start'=>'int', 'end'=>'int'],
'RedisCluster::zRemRangeByScore' => ['int', 'key'=>'string', 'start'=>'float|string', 'end'=>'float|string'],
'RedisCluster::zRevRange' => ['array', 'key'=>'string', 'start'=>'int', 'end'=>'int', 'withscore='=>'bool'],
'RedisCluster::zRevRangeByLex' => ['array', 'key'=>'string', 'min'=>'int', 'max'=>'int', 'offset='=>'int', 'limit='=>'int'],
'RedisCluster::zRevRangeByScore' => ['array', 'key'=>'string', 'start'=>'int', 'end'=>'int', 'options='=>'array'],
'RedisCluster::zRevRank' => ['int', 'key'=>'string', 'member'=>'string'],
'RedisCluster::zScan' => ['array', 'key'=>'string', '&iterator'=>'int', 'pattern='=>'string', 'count='=>'int'],
'RedisCluster::zScore' => ['float', 'key'=>'string', 'member'=>'string'],
'RedisCluster::zUnionStore' => ['int', 'Output'=>'string', 'ZSetKeys'=>'array', 'Weights='=>'?array', 'aggregateFunction='=>'string'],
'Reflection::export' => ['string|null', 'r'=>'reflector', 'return='=>'bool'],
'Reflection::getModifierNames' => ['array', 'modifiers'=>'int'],
'ReflectionClass::__clone' => ['void'],
'ReflectionClass::__construct' => ['void', 'argument'=>''],
'ReflectionClass::__toString' => ['string'],
'ReflectionClass::export' => ['string|null', 'argument'=>'string|object', 'return='=>'bool'],
'ReflectionClass::getConstant' => ['mixed', 'name'=>'string'],
'ReflectionClass::getConstants' => ['array'],
'ReflectionClass::getConstructor' => ['ReflectionMethod|null'],
'ReflectionClass::getDefaultProperties' => ['array'],
'ReflectionClass::getDocComment' => ['string|false'],
'ReflectionClass::getEndLine' => ['int|false'],
'ReflectionClass::getExtension' => ['ReflectionExtension|null'],
'ReflectionClass::getExtensionName' => ['string|false'],
'ReflectionClass::getFileName' => ['string|false'],
'ReflectionClass::getInterfaceNames' => ['string[]'],
'ReflectionClass::getInterfaces' => ['array'],
'ReflectionClass::getMethod' => ['ReflectionMethod', 'name'=>'string'],
'ReflectionClass::getMethods' => ['ReflectionMethod[]', 'filter='=>'int'],
'ReflectionClass::getModifiers' => ['int'],
'ReflectionClass::getName' => ['string'],
'ReflectionClass::getNamespaceName' => ['string'],
'ReflectionClass::getParentClass' => ['ReflectionClass|false'],
'ReflectionClass::getProperties' => ['ReflectionProperty[]', 'filter='=>'int'],
'ReflectionClass::getProperty' => ['ReflectionProperty', 'name'=>'string'],
'ReflectionClass::getReflectionConstant' => ['ReflectionClassConstant', 'name'=>'string'],
'ReflectionClass::getReflectionConstants' => ['array'],
'ReflectionClass::getShortName' => ['string'],
'ReflectionClass::getStartLine' => ['int|false'],
'ReflectionClass::getStaticProperties' => ['ReflectionProperty[]'],
'ReflectionClass::getStaticPropertyValue' => ['mixed', 'name'=>'string', 'default='=>'mixed'],
'ReflectionClass::getTraitAliases' => ['array'],
'ReflectionClass::getTraitNames' => ['array'],
'ReflectionClass::getTraits' => ['array'],
'ReflectionClass::hasConstant' => ['bool', 'name'=>'string'],
'ReflectionClass::hasMethod' => ['bool', 'name'=>'string'],
'ReflectionClass::hasProperty' => ['bool', 'name'=>'string'],
'ReflectionClass::implementsInterface' => ['bool', 'interface_name'=>'string|reflectionclass'],
'ReflectionClass::inNamespace' => ['bool'],
'ReflectionClass::isAbstract' => ['bool'],
'ReflectionClass::isAnonymous' => ['bool'],
'ReflectionClass::isCloneable' => ['bool'],
'ReflectionClass::isFinal' => ['bool'],
'ReflectionClass::isInstance' => ['bool', 'object'=>'object'],
'ReflectionClass::isInstantiable' => ['bool'],
'ReflectionClass::isInterface' => ['bool'],
'ReflectionClass::isInternal' => ['bool'],
'ReflectionClass::isIterable' => ['bool'],
'ReflectionClass::isIterateable' => ['bool'],
'ReflectionClass::isSubclassOf' => ['bool', 'class'=>'string|reflectionclass'],
'ReflectionClass::isTrait' => ['bool'],
'ReflectionClass::isUserDefined' => ['bool'],
'ReflectionClass::newInstance' => ['object', 'args='=>'mixed', '...args='=>'mixed'],
'ReflectionClass::newInstanceArgs' => ['object', 'args='=>'array'],
'ReflectionClass::newInstanceWithoutConstructor' => ['object'],
'ReflectionClass::setStaticPropertyValue' => ['void', 'name'=>'string', 'value'=>'string'],
'ReflectionClassConstant::__construct' => ['void', 'class'=>'mixed', 'name'=>'string'],
'ReflectionClassConstant::__toString' => ['string'],
'ReflectionClassConstant::export' => ['string', 'class'=>'mixed', 'name'=>'string', 'return='=>'bool'],
'ReflectionClassConstant::getDeclaringClass' => ['ReflectionClass'],
'ReflectionClassConstant::getDocComment' => ['string|false'],
'ReflectionClassConstant::getModifiers' => ['int'],
'ReflectionClassConstant::getName' => ['string'],
'ReflectionClassConstant::getValue' => ['mixed'],
'ReflectionClassConstant::isPrivate' => ['bool'],
'ReflectionClassConstant::isProtected' => ['bool'],
'ReflectionClassConstant::isPublic' => ['bool'],
'ReflectionExtension::__clone' => ['void'],
'ReflectionExtension::__construct' => ['void', 'name'=>'string'],
'ReflectionExtension::__toString' => ['string'],
'ReflectionExtension::export' => ['string|null', 'name'=>'string', 'return='=>'bool'],
'ReflectionExtension::getClasses' => ['array'],
'ReflectionExtension::getClassNames' => ['array'],
'ReflectionExtension::getConstants' => ['array'],
'ReflectionExtension::getDependencies' => ['array'],
'ReflectionExtension::getFunctions' => ['array'],
'ReflectionExtension::getINIEntries' => ['array'],
'ReflectionExtension::getName' => ['string'],
'ReflectionExtension::getVersion' => ['string'],
'ReflectionExtension::info' => ['void'],
'ReflectionExtension::isPersistent' => ['void'],
'ReflectionExtension::isTemporary' => ['bool'],
'ReflectionFunction::__construct' => ['void', 'name'=>'string|Closure'],
'ReflectionFunction::__toString' => ['string'],
'ReflectionFunction::export' => ['string|null', 'name'=>'string', 'return='=>'bool'],
'ReflectionFunction::getClosure' => ['?Closure'],
'ReflectionFunction::getClosureScopeClass' => ['ReflectionClass'],
'ReflectionFunction::getClosureThis' => ['bool'],
'ReflectionFunction::getDocComment' => ['string|false'],
'ReflectionFunction::getEndLine' => ['int|false'],
'ReflectionFunction::getExtension' => ['ReflectionExtension|null'],
'ReflectionFunction::getExtensionName' => ['string|false'],
'ReflectionFunction::getFileName' => ['string|false'],
'ReflectionFunction::getName' => ['string'],
'ReflectionFunction::getNamespaceName' => ['string'],
'ReflectionFunction::getNumberOfParameters' => ['int'],
'ReflectionFunction::getNumberOfRequiredParameters' => ['int'],
'ReflectionFunction::getParameters' => ['array'],
'ReflectionFunction::getReturnType' => ['?ReflectionType'],
'ReflectionFunction::getShortName' => ['string'],
'ReflectionFunction::getStartLine' => ['int|false'],
'ReflectionFunction::getStaticVariables' => ['array'],
'ReflectionFunction::inNamespace' => ['bool'],
'ReflectionFunction::invoke' => ['mixed', '...args='=>'mixed'],
'ReflectionFunction::invokeArgs' => ['mixed', 'args'=>'array'],
'ReflectionFunction::isClosure' => ['bool'],
'ReflectionFunction::isDeprecated' => ['bool'],
'ReflectionFunction::isDisabled' => ['bool'],
'ReflectionFunction::isGenerator' => ['bool'],
'ReflectionFunction::isInternal' => ['bool'],
'ReflectionFunction::isUserDefined' => ['bool'],
'ReflectionFunction::isVariadic' => ['bool'],
'ReflectionFunction::returnsReference' => ['bool'],
'ReflectionFunctionAbstract::__clone' => ['void'],
'ReflectionFunctionAbstract::__toString' => ['string'],
'ReflectionFunctionAbstract::getClosureScopeClass' => ['ReflectionClass'],
'ReflectionFunctionAbstract::getClosureThis' => ['object'],
'ReflectionFunctionAbstract::getDocComment' => ['string|false'],
'ReflectionFunctionAbstract::getEndLine' => ['int|false'],
'ReflectionFunctionAbstract::getExtension' => ['ReflectionExtension'],
'ReflectionFunctionAbstract::getExtensionName' => ['string'],
'ReflectionFunctionAbstract::getFileName' => ['string|false'],
'ReflectionFunctionAbstract::getName' => ['string'],
'ReflectionFunctionAbstract::getNamespaceName' => ['string'],
'ReflectionFunctionAbstract::getNumberOfParameters' => ['int'],
'ReflectionFunctionAbstract::getNumberOfRequiredParameters' => ['int'],
'ReflectionFunctionAbstract::getParameters' => ['array'],
'ReflectionFunctionAbstract::getReturnType' => ['?ReflectionType'],
'ReflectionFunctionAbstract::getShortName' => ['string'],
'ReflectionFunctionAbstract::getStartLine' => ['int|false'],
'ReflectionFunctionAbstract::getStaticVariables' => ['array'],
'ReflectionFunctionAbstract::hasReturnType' => ['bool'],
'ReflectionFunctionAbstract::inNamespace' => ['bool'],
'ReflectionFunctionAbstract::isClosure' => ['bool'],
'ReflectionFunctionAbstract::isDeprecated' => ['bool'],
'ReflectionFunctionAbstract::isGenerator' => ['bool'],
'ReflectionFunctionAbstract::isInternal' => ['bool'],
'ReflectionFunctionAbstract::isUserDefined' => ['bool'],
'ReflectionFunctionAbstract::isVariadic' => ['bool'],
'ReflectionFunctionAbstract::returnsReference' => ['bool'],
'ReflectionGenerator::__construct' => ['void', 'generator'=>'object'],
'ReflectionGenerator::getExecutingFile' => ['string'],
'ReflectionGenerator::getExecutingGenerator' => ['Generator'],
'ReflectionGenerator::getExecutingLine' => ['int'],
'ReflectionGenerator::getFunction' => ['ReflectionFunctionAbstract'],
'ReflectionGenerator::getThis' => ['object'],
'ReflectionGenerator::getTrace' => ['array', 'options'=>'int'],
'ReflectionMethod::__construct' => ['void', 'class'=>'string|object', 'name'=>'string'],
'ReflectionMethod::__construct\'1' => ['void', 'class_method'=>'string'],
'ReflectionMethod::__toString' => ['string'],
'ReflectionMethod::export' => ['string|null', 'class'=>'string', 'name'=>'string', 'return='=>'bool'],
'ReflectionMethod::getClosure' => ['?Closure', 'object'=>'?object'],
'ReflectionMethod::getDeclaringClass' => ['ReflectionClass'],
'ReflectionMethod::getModifiers' => ['int'],
'ReflectionMethod::getPrototype' => ['ReflectionMethod'],
'ReflectionMethod::invoke' => ['mixed', 'object'=>'?object', '...args='=>'mixed'],
'ReflectionMethod::invokeArgs' => ['mixed', 'object'=>'?object', 'args'=>'array'],
'ReflectionMethod::isAbstract' => ['bool'],
'ReflectionMethod::isConstructor' => ['bool'],
'ReflectionMethod::isDestructor' => ['bool'],
'ReflectionMethod::isFinal' => ['bool'],
'ReflectionMethod::isPrivate' => ['bool'],
'ReflectionMethod::isProtected' => ['bool'],
'ReflectionMethod::isPublic' => ['bool'],
'ReflectionMethod::isStatic' => ['bool'],
'ReflectionMethod::setAccessible' => ['void', 'visible'=>'bool'],
'ReflectionNamedType::getName' => ['string'],
'ReflectionObject::__construct' => ['void', 'argument'=>'object'],
'ReflectionObject::export' => ['string|null', 'argument'=>'object', 'return='=>'bool'],
'ReflectionParameter::__clone' => ['void'],
'ReflectionParameter::__construct' => ['void', 'function'=>'', 'parameter'=>''],
'ReflectionParameter::__toString' => ['string'],
'ReflectionParameter::allowsNull' => ['bool'],
'ReflectionParameter::canBePassedByValue' => ['bool'],
'ReflectionParameter::export' => ['string|null', 'function'=>'string', 'parameter'=>'string', 'return='=>'bool'],
'ReflectionParameter::getClass' => ['ReflectionClass|null'],
'ReflectionParameter::getDeclaringClass' => ['ReflectionClass|null'],
'ReflectionParameter::getDeclaringFunction' => ['ReflectionFunctionAbstract'],
'ReflectionParameter::getDefaultValue' => ['mixed'],
'ReflectionParameter::getDefaultValueConstantName' => ['string'],
'ReflectionParameter::getName' => ['string'],
'ReflectionParameter::getPosition' => ['int'],
'ReflectionParameter::getType' => ['ReflectionType|null'],
'ReflectionParameter::hasType' => ['bool'],
'ReflectionParameter::isArray' => ['bool'],
'ReflectionParameter::isCallable' => ['bool'],
'ReflectionParameter::isDefaultValueAvailable' => ['bool'],
'ReflectionParameter::isDefaultValueConstant' => ['bool'],
'ReflectionParameter::isOptional' => ['bool'],
'ReflectionParameter::isPassedByReference' => ['bool'],
'ReflectionParameter::isVariadic' => ['bool'],
'ReflectionProperty::__clone' => ['void'],
'ReflectionProperty::__construct' => ['void', 'class'=>'', 'name'=>'string'],
'ReflectionProperty::__toString' => ['string'],
'ReflectionProperty::export' => ['string|null', 'class'=>'mixed', 'name'=>'string', 'return='=>'bool'],
'ReflectionProperty::getDeclaringClass' => ['ReflectionClass'],
'ReflectionProperty::getDocComment' => ['string|false'],
'ReflectionProperty::getModifiers' => ['int'],
'ReflectionProperty::getName' => ['string'],
'ReflectionProperty::getValue' => ['mixed', 'object='=>'object'],
'ReflectionProperty::isDefault' => ['bool'],
'ReflectionProperty::isPrivate' => ['bool'],
'ReflectionProperty::isProtected' => ['bool'],
'ReflectionProperty::isPublic' => ['bool'],
'ReflectionProperty::isStatic' => ['bool'],
'ReflectionProperty::setAccessible' => ['void', 'visible'=>'bool'],
'ReflectionProperty::setValue' => ['void', 'object'=>'object', 'value'=>''],
'ReflectionProperty::setValue\'1' => ['void', 'value'=>''],
'ReflectionType::__toString' => ['string'],
'ReflectionType::allowsNull' => ['bool'],
'ReflectionType::getName' => ['string'],
'ReflectionType::isBuiltin' => ['bool'],
'ReflectionZendExtension::__clone' => ['void'],
'ReflectionZendExtension::__construct' => ['void', 'name'=>'string'],
'ReflectionZendExtension::__toString' => ['string'],
'ReflectionZendExtension::export' => ['string|null', 'name'=>'string', 'return='=>'bool'],
'ReflectionZendExtension::getAuthor' => ['string'],
'ReflectionZendExtension::getCopyright' => ['string'],
'ReflectionZendExtension::getName' => ['string'],
'ReflectionZendExtension::getURL' => ['string'],
'ReflectionZendExtension::getVersion' => ['string'],
'Reflector::__toString' => ['string'],
'Reflector::export' => ['?string'],
'RegexIterator::__construct' => ['void', 'it'=>'iterator', 'regex'=>'string', 'mode='=>'int', 'flags='=>'int', 'preg_flags='=>'int'],
'RegexIterator::accept' => ['bool'],
'RegexIterator::getFlags' => ['int'],
'RegexIterator::getMode' => ['int'],
'RegexIterator::getPregFlags' => ['int'],
'RegexIterator::getRegex' => ['string'],
'RegexIterator::setFlags' => ['bool', 'new_flags'=>'int'],
'RegexIterator::setMode' => ['bool', 'new_mode'=>'int'],
'RegexIterator::setPregFlags' => ['bool', 'new_flags'=>'int'],
'register_event_handler' => ['bool', 'event_handler_func'=>'event_handler_func', 'handler_register_name'=>'handler_register_name', 'event_type_mask'=>'event_type_mask'],
'register_shutdown_function' => ['void', 'function'=>'callable', '...parameter='=>'mixed'],
'register_tick_function' => ['bool', 'function'=>'callable', '...args='=>'mixed'],
'rename' => ['bool', 'old_name'=>'string', 'new_name'=>'string', 'context='=>'resource'],
'rename_function' => ['bool', 'original_name'=>'string', 'new_name'=>'string'],
'reset' => ['mixed', '&rw_array_arg'=>'array|object'],
'ResourceBundle::__construct' => ['void', 'locale'=>'string', 'bundlename'=>'string', 'fallback='=>'bool'],
'ResourceBundle::count' => ['int'],
'ResourceBundle::create' => ['?ResourceBundle', 'locale'=>'string', 'bundlename'=>'string', 'fallback='=>'bool'],
'ResourceBundle::get' => ['', 'index'=>'string|int'],
'ResourceBundle::getErrorCode' => ['int'],
'ResourceBundle::getErrorMessage' => ['string'],
'ResourceBundle::getLocales' => ['array', 'bundlename'=>'string'],
'resourcebundle_count' => ['int', 'r'=>'resourcebundle'],
'resourcebundle_create' => ['?ResourceBundle', 'locale'=>'string', 'bundlename'=>'string', 'fallback='=>'bool'],
'resourcebundle_get' => ['', 'r'=>'resourcebundle', 'index'=>'string|int'],
'resourcebundle_get_error_code' => ['int', 'r'=>'resourcebundle'],
'resourcebundle_get_error_message' => ['string', 'r'=>'resourcebundle'],
'resourcebundle_locales' => ['array', 'bundlename'=>'string'],
'restore_error_handler' => ['bool'],
'restore_exception_handler' => ['bool'],
'restore_include_path' => ['void'],
'rewind' => ['bool', 'fp'=>'resource'],
'rewinddir' => ['void', 'dir_handle='=>'resource'],
'rmdir' => ['bool', 'dirname'=>'string', 'context='=>'resource'],
'round' => ['float', 'number'=>'float', 'precision='=>'int', 'mode='=>'int'],
'rpm_close' => ['bool', 'rpmr'=>'resource'],
'rpm_get_tag' => ['mixed', 'rpmr'=>'resource', 'tagnum'=>'int'],
'rpm_is_valid' => ['bool', 'filename'=>'string'],
'rpm_open' => ['resource', 'filename'=>'string'],
'rpm_version' => ['string'],
'rrd_create' => ['bool', 'filename'=>'string', 'options'=>'array'],
'rrd_error' => ['string'],
'rrd_fetch' => ['array', 'filename'=>'string', 'options'=>'array'],
'rrd_first' => ['int', 'file'=>'string', 'raaindex='=>'int'],
'rrd_graph' => ['array', 'filename'=>'string', 'options'=>'array'],
'rrd_info' => ['array', 'filename'=>'string'],
'rrd_last' => ['int', 'filename'=>'string'],
'rrd_lastupdate' => ['array', 'filename'=>'string'],
'rrd_restore' => ['bool', 'xml_file'=>'string', 'rrd_file'=>'string', 'options='=>'array'],
'rrd_tune' => ['bool', 'filename'=>'string', 'options'=>'array'],
'rrd_update' => ['bool', 'filename'=>'string', 'options'=>'array'],
'rrd_version' => ['string'],
'rrd_xport' => ['array', 'options'=>'array'],
'rrdc_disconnect' => ['void'],
'RRDCreator::__construct' => ['void', 'path'=>'string', 'starttime='=>'string', 'step='=>'int'],
'RRDCreator::addArchive' => ['void', 'description'=>'string'],
'RRDCreator::addDataSource' => ['void', 'description'=>'string'],
'RRDCreator::save' => ['bool'],
'RRDGraph::__construct' => ['void', 'path'=>'string'],
'RRDGraph::save' => ['array'],
'RRDGraph::saveVerbose' => ['array'],
'RRDGraph::setOptions' => ['void', 'options'=>'array'],
'RRDUpdater::__construct' => ['void', 'path'=>'string'],
'RRDUpdater::update' => ['bool', 'values'=>'array', 'time='=>'string'],
'rsort' => ['bool', '&rw_array_arg'=>'array', 'sort_flags='=>'int'],
'rtrim' => ['string', 'str'=>'string', 'character_mask='=>'string'],
'runkit_class_adopt' => ['bool', 'classname'=>'string', 'parentname'=>'string'],
'runkit_class_emancipate' => ['bool', 'classname'=>'string'],
'runkit_constant_add' => ['bool', 'constname'=>'string', 'value'=>'mixed'],
'runkit_constant_redefine' => ['bool', 'constname'=>'string', 'newvalue'=>'mixed'],
'runkit_constant_remove' => ['bool', 'constname'=>'string'],
'runkit_function_add' => ['bool', 'funcname'=>'string', 'arglist'=>'string', 'code'=>'string', 'doccomment='=>'?string'],
'runkit_function_add\'1' => ['bool', 'funcname'=>'string', 'closure'=>'Closure', 'doccomment='=>'?string'],
'runkit_function_copy' => ['bool', 'funcname'=>'string', 'targetname'=>'string'],
'runkit_function_redefine' => ['bool', 'funcname'=>'string', 'arglist'=>'string', 'code'=>'string', 'doccomment='=>'?string'],
'runkit_function_redefine\'1' => ['bool', 'funcname'=>'string', 'closure'=>'Closure', 'doccomment='=>'?string'],
'runkit_function_remove' => ['bool', 'funcname'=>'string'],
'runkit_function_rename' => ['bool', 'funcname'=>'string', 'newname'=>'string'],
'runkit_import' => ['bool', 'filename'=>'string', 'flags='=>'int'],
'runkit_lint' => ['bool', 'code'=>'string'],
'runkit_lint_file' => ['bool', 'filename'=>'string'],
'runkit_method_add' => ['bool', 'classname'=>'string', 'methodname'=>'string', 'args'=>'string', 'code'=>'string', 'flags='=>'int', 'doccomment='=>'?string'],
'runkit_method_add\'1' => ['bool', 'classname'=>'string', 'methodname'=>'string', 'closure'=>'Closure', 'flags='=>'int', 'doccomment='=>'?string'],
'runkit_method_copy' => ['bool', 'dclass'=>'string', 'dmethod'=>'string', 'sclass'=>'string', 'smethod='=>'string'],
'runkit_method_redefine' => ['bool', 'classname'=>'string', 'methodname'=>'string', 'args'=>'string', 'code'=>'string', 'flags='=>'int', 'doccomment='=>'?string'],
'runkit_method_redefine\'1' => ['bool', 'classname'=>'string', 'methodname'=>'string', 'closure'=>'Closure', 'flags='=>'int', 'doccomment='=>'?string'],
'runkit_method_remove' => ['bool', 'classname'=>'string', 'methodname'=>'string'],
'runkit_method_rename' => ['bool', 'classname'=>'string', 'methodname'=>'string', 'newname'=>'string'],
'runkit_return_value_used' => ['bool'],
'Runkit_Sandbox::__construct' => ['void', 'options='=>'array'],
'runkit_sandbox_output_handler' => ['mixed', 'sandbox'=>'object', 'callback='=>'mixed'],
'Runkit_Sandbox_Parent' => [''],
'Runkit_Sandbox_Parent::__construct' => ['void'],
'runkit_superglobals' => ['array'],
'RuntimeException::__clone' => ['void'],
'RuntimeException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?RuntimeException'],
'RuntimeException::__toString' => ['string'],
'RuntimeException::getCode' => ['int'],
'RuntimeException::getFile' => ['string'],
'RuntimeException::getLine' => ['int'],
'RuntimeException::getMessage' => ['string'],
'RuntimeException::getPrevious' => ['Throwable|RuntimeException|null'],
'RuntimeException::getTrace' => ['array'],
'RuntimeException::getTraceAsString' => ['string'],
'SAMConnection::commit' => ['bool'],
'SAMConnection::connect' => ['bool', 'protocol'=>'string', 'properties='=>'array'],
'SAMConnection::disconnect' => ['bool'],
'SAMConnection::errno' => ['int'],
'SAMConnection::error' => ['string'],
'SAMConnection::isConnected' => ['bool'],
'SAMConnection::peek' => ['SAMMessage', 'target'=>'string', 'properties='=>'array'],
'SAMConnection::peekAll' => ['array', 'target'=>'string', 'properties='=>'array'],
'SAMConnection::receive' => ['SAMMessage', 'target'=>'string', 'properties='=>'array'],
'SAMConnection::remove' => ['SAMMessage', 'target'=>'string', 'properties='=>'array'],
'SAMConnection::rollback' => ['bool'],
'SAMConnection::send' => ['string', 'target'=>'string', 'msg'=>'sammessage', 'properties='=>'array'],
'SAMConnection::setDebug' => ['', 'switch'=>'bool'],
'SAMConnection::subscribe' => ['string', 'targettopic'=>'string'],
'SAMConnection::unsubscribe' => ['bool', 'subscriptionid'=>'string', 'targettopic='=>'string'],
'SAMMessage::body' => ['string'],
'SAMMessage::header' => ['object'],
'sapi_windows_cp_conv' => ['string', 'in_codepage'=>'int|string', 'out_codepage'=>'int|string', 'subject'=>'string'],
'sapi_windows_cp_get' => ['int'],
'sapi_windows_cp_is_utf8' => ['bool'],
'sapi_windows_cp_set' => ['bool', 'code_page'=>'int'],
'sapi_windows_vt100_support' => ['bool', 'stream'=>'resource', 'enable='=>'bool'],
'SCA::createDataObject' => ['SDO_DataObject', 'type_namespace_uri'=>'string', 'type_name'=>'string'],
'SCA::getService' => ['', 'target'=>'string', 'binding='=>'string', 'config='=>'array'],
'SCA_LocalProxy::createDataObject' => ['SDO_DataObject', 'type_namespace_uri'=>'string', 'type_name'=>'string'],
'SCA_SoapProxy::createDataObject' => ['SDO_DataObject', 'type_namespace_uri'=>'string', 'type_name'=>'string'],
'scalebarObj::convertToString' => ['string'],
'scalebarObj::free' => ['void'],
'scalebarObj::set' => ['int', 'property_name'=>'string', 'new_value'=>''],
'scalebarObj::setImageColor' => ['int', 'red'=>'int', 'green'=>'int', 'blue'=>'int'],
'scalebarObj::updateFromString' => ['int', 'snippet'=>'string'],
'scandir' => ['array|false', 'dir'=>'string', 'sorting_order='=>'int', 'context='=>'resource'],
'SDO_DAS_ChangeSummary::beginLogging' => [''],
'SDO_DAS_ChangeSummary::endLogging' => [''],
'SDO_DAS_ChangeSummary::getChangedDataObjects' => ['SDO_List'],
'SDO_DAS_ChangeSummary::getChangeType' => ['int', 'dataobject'=>'sdo_dataobject'],
'SDO_DAS_ChangeSummary::getOldContainer' => ['SDO_DataObject', 'data_object'=>'sdo_dataobject'],
'SDO_DAS_ChangeSummary::getOldValues' => ['SDO_List', 'data_object'=>'sdo_dataobject'],
'SDO_DAS_ChangeSummary::isLogging' => ['bool'],
'SDO_DAS_DataFactory::addPropertyToType' => ['', 'parent_type_namespace_uri'=>'string', 'parent_type_name'=>'string', 'property_name'=>'string', 'type_namespace_uri'=>'string', 'type_name'=>'string', 'options='=>'array'],
'SDO_DAS_DataFactory::addType' => ['', 'type_namespace_uri'=>'string', 'type_name'=>'string', 'options='=>'array'],
'SDO_DAS_DataFactory::getDataFactory' => ['SDO_DAS_DataFactory'],
'SDO_DAS_DataObject::getChangeSummary' => ['SDO_DAS_ChangeSummary'],
'SDO_DAS_Relational::__construct' => ['void', 'database_metadata'=>'array', 'application_root_type='=>'string', 'sdo_containment_references_metadata='=>'array'],
'SDO_DAS_Relational::applyChanges' => ['', 'database_handle'=>'pdo', 'root_data_object'=>'sdodataobject'],
'SDO_DAS_Relational::createRootDataObject' => ['SDODataObject'],
'SDO_DAS_Relational::executePreparedQuery' => ['SDODataObject', 'database_handle'=>'pdo', 'prepared_statement'=>'pdostatement', 'value_list'=>'array', 'column_specifier='=>'array'],
'SDO_DAS_Relational::executeQuery' => ['SDODataObject', 'database_handle'=>'pdo', 'sql_statement'=>'string', 'column_specifier='=>'array'],
'SDO_DAS_Setting::getListIndex' => ['int'],
'SDO_DAS_Setting::getPropertyIndex' => ['int'],
'SDO_DAS_Setting::getPropertyName' => ['string'],
'SDO_DAS_Setting::getValue' => [''],
'SDO_DAS_Setting::isSet' => ['bool'],
'SDO_DAS_XML::addTypes' => ['', 'xsd_file'=>'string'],
'SDO_DAS_XML::create' => ['SDO_DAS_XML', 'xsd_file='=>'mixed', 'key='=>'string'],
'SDO_DAS_XML::createDataObject' => ['SDO_DataObject', 'namespace_uri'=>'string', 'type_name'=>'string'],
'SDO_DAS_XML::createDocument' => ['SDO_DAS_XML_Document', 'document_element_name'=>'string', 'document_element_namespace_uri'=>'string', 'dataobject='=>'sdo_dataobject'],
'SDO_DAS_XML::loadFile' => ['SDO_XMLDocument', 'xml_file'=>'string'],
'SDO_DAS_XML::loadString' => ['SDO_DAS_XML_Document', 'xml_string'=>'string'],
'SDO_DAS_XML::saveFile' => ['', 'xdoc'=>'sdo_xmldocument', 'xml_file'=>'string', 'indent='=>'int'],
'SDO_DAS_XML::saveString' => ['string', 'xdoc'=>'sdo_xmldocument', 'indent='=>'int'],
'SDO_DAS_XML_Document::getRootDataObject' => ['SDO_DataObject'],
'SDO_DAS_XML_Document::getRootElementName' => ['string'],
'SDO_DAS_XML_Document::getRootElementURI' => ['string'],
'SDO_DAS_XML_Document::setEncoding' => ['', 'encoding'=>'string'],
'SDO_DAS_XML_Document::setXMLDeclaration' => ['', 'xmldeclatation'=>'bool'],
'SDO_DAS_XML_Document::setXMLVersion' => ['', 'xmlversion'=>'string'],
'SDO_DataFactory::create' => ['void', 'type_namespace_uri'=>'string', 'type_name'=>'string'],
'SDO_DataObject::clear' => ['void'],
'SDO_DataObject::createDataObject' => ['SDO_DataObject', 'identifier'=>''],
'SDO_DataObject::getContainer' => ['SDO_DataObject'],
'SDO_DataObject::getSequence' => ['SDO_Sequence'],
'SDO_DataObject::getTypeName' => ['string'],
'SDO_DataObject::getTypeNamespaceURI' => ['string'],
'SDO_Exception::getCause' => [''],
'SDO_List::insert' => ['void', 'value'=>'mixed', 'index='=>'int'],
'SDO_Model_Property::getContainingType' => ['SDO_Model_Type'],
'SDO_Model_Property::getDefault' => [''],
'SDO_Model_Property::getName' => ['string'],
'SDO_Model_Property::getType' => ['SDO_Model_Type'],
'SDO_Model_Property::isContainment' => ['bool'],
'SDO_Model_Property::isMany' => ['bool'],
'SDO_Model_ReflectionDataObject::__construct' => ['void', 'data_object'=>'sdo_dataobject'],
'SDO_Model_ReflectionDataObject::export' => ['mixed', 'rdo'=>'sdo_model_reflectiondataobject', 'return='=>'bool'],
'SDO_Model_ReflectionDataObject::getContainmentProperty' => ['SDO_Model_Property'],
'SDO_Model_ReflectionDataObject::getInstanceProperties' => ['array'],
'SDO_Model_ReflectionDataObject::getType' => ['SDO_Model_Type'],
'SDO_Model_Type::getBaseType' => ['SDO_Model_Type'],
'SDO_Model_Type::getName' => ['string'],
'SDO_Model_Type::getNamespaceURI' => ['string'],
'SDO_Model_Type::getProperties' => ['array'],
'SDO_Model_Type::getProperty' => ['SDO_Model_Property', 'identifier'=>''],
'SDO_Model_Type::isAbstractType' => ['bool'],
'SDO_Model_Type::isDataType' => ['bool'],
'SDO_Model_Type::isInstance' => ['bool', 'data_object'=>'sdo_dataobject'],
'SDO_Model_Type::isOpenType' => ['bool'],
'SDO_Model_Type::isSequencedType' => ['bool'],
'SDO_Sequence::getProperty' => ['SDO_Model_Property', 'sequence_index'=>'int'],
'SDO_Sequence::insert' => ['void', 'value'=>'mixed', 'sequenceindex='=>'int', 'propertyidentifier='=>'mixed'],
'SDO_Sequence::move' => ['void', 'toindex'=>'int', 'fromindex'=>'int'],
'SeekableIterator::seek' => ['void', 'position'=>'int'],
'sem_acquire' => ['bool', 'sem_identifier'=>'resource', 'nowait='=>'bool'],
'sem_get' => ['resource', 'key'=>'int', 'max_acquire='=>'int', 'perm='=>'int', 'auto_release='=>'int'],
'sem_release' => ['bool', 'sem_identifier'=>'resource'],
'sem_remove' => ['bool', 'sem_identifier'=>'resource'],
'Serializable::serialize' => ['string'],
'Serializable::unserialize' => ['void', 'serialized'=>''],
'serialize' => ['string', 'variable'=>'mixed'],
'ServerRequest::withInput' => ['ServerRequest', 'input'=>'mixed'],
'ServerRequest::withoutParams' => ['ServerRequest', 'params'=>'int|string'],
'ServerRequest::withParam' => ['ServerRequest', 'key'=>'int|string', 'val'=>'mixed'],
'ServerRequest::withParams' => ['ServerRequest', 'params'=>'mixed'],
'ServerRequest::withUrl' => ['ServerRequest', 'url'=>'array'],
'ServerResponse::addHeader' => ['void', 'label'=>'string', 'value'=>'string'],
'ServerResponse::date' => ['string', 'date'=>'string|DateTimeInterface'],
'ServerResponse::getHeader' => ['string', 'label'=>'string'],
'ServerResponse::getHeaders' => ['string[]'],
'ServerResponse::getStatus' => ['int'],
'ServerResponse::getVersion' => ['string'],
'ServerResponse::setHeader' => ['void', 'label'=>'string', 'value'=>'string'],
'ServerResponse::setStatus' => ['void', 'status'=>'int'],
'ServerResponse::setVersion' => ['void', 'version'=>'string'],
'session_abort' => ['bool'],
'session_cache_expire' => ['int', 'new_cache_expire='=>'int'],
'session_cache_limiter' => ['string', 'new_cache_limiter='=>'string'],
'session_commit' => ['bool'],
'session_create_id' => ['string', 'prefix='=>'string'],
'session_decode' => ['bool', 'data'=>'string'],
'session_destroy' => ['bool'],
'session_encode' => ['string'],
'session_gc' => ['int'],
'session_get_cookie_params' => ['array'],
'session_id' => ['string', 'newid='=>'string'],
'session_is_registered' => ['bool', 'name'=>'string'],
'session_module_name' => ['string', 'newname='=>'string'],
'session_name' => ['string', 'newname='=>'string'],
'session_pgsql_add_error' => ['bool', 'error_level'=>'int', 'error_message='=>'string'],
'session_pgsql_get_error' => ['array', 'with_error_message='=>'bool'],
'session_pgsql_get_field' => ['string'],
'session_pgsql_reset' => ['bool'],
'session_pgsql_set_field' => ['bool', 'value'=>'string'],
'session_pgsql_status' => ['array'],
'session_regenerate_id' => ['bool', 'delete_old_session='=>'bool'],
'session_register' => ['bool', 'name'=>'mixed', '...args='=>'mixed'],
'session_register_shutdown' => ['void'],
'session_reset' => ['bool'],
'session_save_path' => ['string', 'newname='=>'string'],
'session_set_cookie_params' => ['bool', 'lifetime'=>'int', 'path='=>'string', 'domain='=>'?string', 'secure='=>'bool', 'httponly='=>'bool'],
'session_set_save_handler' => ['bool', 'open'=>'callable', 'close'=>'callable', 'read'=>'callable', 'write'=>'callable', 'destroy'=>'callable', 'gc'=>'callable', 'create_sid='=>'callable', 'validate_sid='=>'callable', 'update_timestamp='=>'callable'],
'session_set_save_handler\'1' => ['bool', 'sessionhandler'=>'SessionHandlerInterface', 'register_shutdown='=>'bool'],
'session_start' => ['bool', 'options='=>'array'],
'session_status' => ['int'],
'session_unregister' => ['bool', 'name'=>'string'],
'session_unset' => ['bool'],
'session_write_close' => ['bool'],
'SessionHandler::close' => ['bool'],
'SessionHandler::create_sid' => ['char'],
'SessionHandler::destroy' => ['bool', 'id'=>'string'],
'SessionHandler::gc' => ['bool', 'maxlifetime'=>'int'],
'SessionHandler::open' => ['bool', 'save_path'=>'string', 'session_name'=>'string'],
'SessionHandler::read' => ['string', 'id'=>'string'],
'SessionHandler::updateTimestamp' => ['bool', 'session_id'=>'string', 'session_data'=>'string'],
'SessionHandler::validateId' => ['bool', 'session_id'=>'string'],
'SessionHandler::write' => ['bool', 'id'=>'string', 'data'=>'string'],
'SessionHandlerInterface::close' => ['bool'],
'SessionHandlerInterface::destroy' => ['bool', 'session_id'=>'string'],
'SessionHandlerInterface::gc' => ['bool', 'maxlifetime'=>'int'],
'SessionHandlerInterface::open' => ['bool', 'save_path'=>'string', 'name'=>'string'],
'SessionHandlerInterface::read' => ['string', 'session_id'=>'string'],
'SessionHandlerInterface::write' => ['bool', 'session_id'=>'string', 'session_data'=>'string'],
'SessionIdInterface::create_sid' => ['string'],
'SessionUpdateTimestampHandler::updateTimestamp' => ['bool', 'id'=>'string', 'data'=>'string'],
'SessionUpdateTimestampHandler::validateId' => ['char', 'id'=>'string'],
'SessionUpdateTimestampHandlerInterface::updateTimestamp' => ['bool', 'key'=>'string', 'val'=>'string'],
'SessionUpdateTimestampHandlerInterface::validateId' => ['bool', 'key'=>'string'],
'set_error_handler' => ['?callable', 'error_handler'=>'callable', 'error_types='=>'int'],
'set_exception_handler' => ['?callable', 'exception_handler'=>'callable'],
'set_file_buffer' => ['int', 'fp'=>'resource', 'buffer'=>'int'],
'set_include_path' => ['string', 'new_include_path'=>'string'],
'set_magic_quotes_runtime' => ['bool', 'new_setting'=>'bool'],
'set_time_limit' => ['bool', 'seconds'=>'int'],
'setcookie' => ['bool', 'name'=>'string', 'value='=>'string', 'expires='=>'int', 'path='=>'string', 'domain='=>'string', 'secure='=>'bool', 'httponly='=>'bool'],
'setLeftFill' => ['void', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'a='=>'int'],
'setLine' => ['void', 'width'=>'int', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'a='=>'int'],
'setlocale' => ['string|false', 'category'=>'int', 'locale'=>'string', '...args='=>'string'],
'setlocale\'1' => ['string|false', 'category'=>'int', 'locale'=>'?array'],
'setproctitle' => ['void', 'title'=>'string'],
'setrawcookie' => ['bool', 'name'=>'string', 'value='=>'string', 'expires='=>'int', 'path='=>'string', 'domain='=>'string', 'secure='=>'bool', 'httponly='=>'bool'],
'setRightFill' => ['void', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'a='=>'int'],
'setthreadtitle' => ['bool', 'title'=>'string'],
'settype' => ['bool', '&rw_var'=>'mixed', 'type'=>'string'],
'sha1' => ['string', 'str'=>'string', 'raw_output='=>'bool'],
'sha1_file' => ['string|false', 'filename'=>'string', 'raw_output='=>'bool'],
'sha256' => ['string', 'str'=>'string', 'raw_output='=>'bool'],
'sha256_file' => ['string', 'filename'=>'string', 'raw_output='=>'bool'],
'shapefileObj::__construct' => ['void', 'filename'=>'string', 'type'=>'int'],
'shapefileObj::addPoint' => ['int', 'point'=>'pointObj'],
'shapefileObj::addShape' => ['int', 'shape'=>'shapeObj'],
'shapefileObj::free' => ['void'],
'shapefileObj::getExtent' => ['rectObj', 'i'=>'int'],
'shapefileObj::getPoint' => ['shapeObj', 'i'=>'int'],
'shapefileObj::getShape' => ['shapeObj', 'i'=>'int'],
'shapefileObj::getTransformed' => ['shapeObj', 'map'=>'MapObj', 'i'=>'int'],
'shapefileObj::ms_newShapefileObj' => ['shapefileObj', 'filename'=>'string', 'type'=>'int'],
'shapeObj::__construct' => ['void', 'type'=>'int'],
'shapeObj::add' => ['int', 'line'=>'lineObj'],
'shapeObj::boundary' => ['shapeObj'],
'shapeObj::contains' => ['bool', 'point'=>'pointObj'],
'shapeObj::containsShape' => ['int', 'shape2'=>'shapeObj'],
'shapeObj::convexhull' => ['shapeObj'],
'shapeObj::crosses' => ['int', 'shape'=>'shapeObj'],
'shapeObj::difference' => ['shapeObj', 'shape'=>'shapeObj'],
'shapeObj::disjoint' => ['int', 'shape'=>'shapeObj'],
'shapeObj::draw' => ['int', 'map'=>'MapObj', 'layer'=>'layerObj', 'img'=>'imageObj'],
'shapeObj::equals' => ['int', 'shape'=>'shapeObj'],
'shapeObj::free' => ['void'],
'shapeObj::getArea' => ['float'],
'shapeObj::getCentroid' => ['pointObj'],
'shapeObj::getLabelPoint' => ['pointObj'],
'shapeObj::getLength' => ['float'],
'shapeObj::getPointUsingMeasure' => ['pointObj', 'm'=>'float'],
'shapeObj::getValue' => ['string', 'layer'=>'layerObj', 'filedname'=>'string'],
'shapeObj::intersection' => ['shapeObj', 'shape'=>'shapeObj'],
'shapeObj::intersects' => ['bool', 'shape'=>'shapeObj'],
'shapeObj::line' => ['lineObj', 'i'=>'int'],
'shapeObj::ms_shapeObjFromWkt' => ['shapeObj', 'wkt'=>'string'],
'shapeObj::overlaps' => ['int', 'shape'=>'shapeObj'],
'shapeObj::project' => ['int', 'in'=>'projectionObj', 'out'=>'projectionObj'],
'shapeObj::set' => ['int', 'property_name'=>'string', 'new_value'=>''],
'shapeObj::setBounds' => ['int'],
'shapeObj::simplify' => ['shapeObj', 'tolerance'=>'float'],
'shapeObj::symdifference' => ['shapeObj', 'shape'=>'shapeObj'],
'shapeObj::topologyPreservingSimplify' => ['shapeObj', 'tolerance'=>'float'],
'shapeObj::touches' => ['int', 'shape'=>'shapeObj'],
'shapeObj::toWkt' => ['string'],
'shapeObj::union' => ['shapeObj', 'shape'=>'shapeObj'],
'shapeObj::within' => ['int', 'shape2'=>'shapeObj'],
'shell_exec' => ['?string', 'cmd'=>'string'],
'shm_attach' => ['resource', 'key'=>'int', 'memsize='=>'int', 'perm='=>'int'],
'shm_detach' => ['bool', 'shm_identifier'=>'resource'],
'shm_get_var' => ['mixed', 'id'=>'resource', 'variable_key'=>'int'],
'shm_has_var' => ['bool', 'shm_identifier'=>'resource', 'variable_key'=>'int'],
'shm_put_var' => ['bool', 'shm_identifier'=>'resource', 'variable_key'=>'int', 'variable'=>'mixed'],
'shm_remove' => ['bool', 'shm_identifier'=>'resource'],
'shm_remove_var' => ['bool', 'shm_identifier'=>'resource', 'variable_key'=>'int'],
'shmop_close' => ['void', 'shmid'=>'resource'],
'shmop_delete' => ['bool', 'shmid'=>'resource'],
'shmop_open' => ['resource', 'key'=>'int', 'flags'=>'string', 'mode'=>'int', 'size'=>'int'],
'shmop_read' => ['string', 'shmid'=>'resource', 'start'=>'int', 'count'=>'int'],
'shmop_size' => ['int', 'shmid'=>'resource'],
'shmop_write' => ['int', 'shmid'=>'resource', 'data'=>'string', 'offset'=>'int'],
'show_source' => ['', 'file_name'=>'', 'return'=>''],
'shuffle' => ['bool', '&rw_array_arg'=>'array'],
'signeurlpaiement' => ['string', 'clent'=>'string', 'data'=>'string'],
'similar_text' => ['int', 'str1'=>'string', 'str2'=>'string', '&w_percent='=>'float'],
'simplexml_import_dom' => ['SimpleXMLElement|false', 'node'=>'DOMNode', 'class_name='=>'string'],
'simplexml_load_file' => ['SimpleXMLElement|false', 'filename'=>'string', 'class_name='=>'string', 'options='=>'int', 'ns='=>'string', 'is_prefix='=>'bool'],
'simplexml_load_string' => ['SimpleXMLElement|false', 'data'=>'string', 'class_name='=>'string', 'options='=>'int', 'ns='=>'string', 'is_prefix='=>'bool'],
'SimpleXMLElement::__construct' => ['void', 'data'=>'string', 'options='=>'int', 'data_is_url='=>'bool', 'ns='=>'string', 'is_prefix='=>'bool'],
'SimpleXMLElement::__toString' => ['string'],
'SimpleXMLElement::__get' => ['SimpleXMLElement', 'name'=>'string'],
'SimpleXMLElement::addAttribute' => ['void', 'name'=>'string', 'value='=>'string', 'ns='=>'string'],
'SimpleXMLElement::addChild' => ['SimpleXMLElement', 'name'=>'string', 'value='=>'string', 'ns='=>'string'],
'SimpleXMLElement::asXML' => ['string|bool', 'filename='=>'string'],
'SimpleXMLElement::attributes' => ['SimpleXMLElement|null', 'ns='=>'string', 'is_prefix='=>'bool'],
'SimpleXMLElement::children' => ['SimpleXMLElement', 'ns='=>'string', 'is_prefix='=>'bool'],
'SimpleXMLElement::count' => ['int'],
'SimpleXMLElement::getDocNamespaces' => ['string[]', 'recursive='=>'bool', 'from_root='=>'bool'],
'SimpleXMLElement::getName' => ['string'],
'SimpleXMLElement::getNamespaces' => ['string[]', 'recursive='=>'bool'],
'SimpleXMLElement::registerXPathNamespace' => ['bool', 'prefix'=>'string', 'ns'=>'string'],
'SimpleXMLElement::xpath' => ['SimpleXMLElement[]|false', 'path'=>'string'],
'SimpleXMLIterator::current' => ['SimpleXMLIterator|null'],
'SimpleXMLIterator::getChildren' => ['SimpleXMLIterator'],
'SimpleXMLIterator::hasChildren' => ['bool'],
'SimpleXMLIterator::key' => ['string|false'],
'SimpleXMLIterator::next' => ['void'],
'SimpleXMLIterator::rewind' => ['void'],
'SimpleXMLIterator::valid' => ['bool'],
'sin' => ['float', 'number'=>'float'],
'sinh' => ['float', 'number'=>'float'],
'sizeof' => ['int', 'var'=>'Countable|array', 'mode='=>'int'],
'sleep' => ['int|false', 'seconds'=>'int'],
'snmp2_get' => ['string', 'host'=>'string', 'community'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'],
'snmp2_getnext' => ['string', 'host'=>'string', 'community'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'],
'snmp2_real_walk' => ['array', 'host'=>'string', 'community'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'],
'snmp2_set' => ['bool', 'host'=>'string', 'community'=>'string', 'object_id'=>'string', 'type'=>'string', 'value'=>'string', 'timeout='=>'int', 'retries='=>'int'],
'snmp2_walk' => ['array', 'host'=>'string', 'community'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'],
'snmp3_get' => ['string', 'host'=>'string', 'sec_name'=>'string', 'sec_level'=>'string', 'auth_protocol'=>'string', 'auth_passphrase'=>'string', 'priv_protocol'=>'string', 'priv_passphrase'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'],
'snmp3_getnext' => ['string', 'host'=>'string', 'sec_name'=>'string', 'sec_level'=>'string', 'auth_protocol'=>'string', 'auth_passphrase'=>'string', 'priv_protocol'=>'string', 'priv_passphrase'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'],
'snmp3_real_walk' => ['array', 'host'=>'string', 'sec_name'=>'string', 'sec_level'=>'string', 'auth_protocol'=>'string', 'auth_passphrase'=>'string', 'priv_protocol'=>'string', 'priv_passphrase'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'],
'snmp3_set' => ['bool', 'host'=>'string', 'sec_name'=>'string', 'sec_level'=>'string', 'auth_protocol'=>'string', 'auth_passphrase'=>'string', 'priv_protocol'=>'string', 'priv_passphrase'=>'string', 'object_id'=>'string', 'type'=>'string', 'value'=>'string', 'timeout='=>'int', 'retries='=>'int'],
'snmp3_walk' => ['array', 'host'=>'string', 'sec_name'=>'string', 'sec_level'=>'string', 'auth_protocol'=>'string', 'auth_passphrase'=>'string', 'priv_protocol'=>'string', 'priv_passphrase'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'],
'SNMP::__construct' => ['void', 'version'=>'int', 'hostname'=>'string', 'community'=>'string', 'timeout'=>'int', 'retries'=>'int'],
'SNMP::close' => ['bool'],
'SNMP::get' => ['mixed', 'object_id'=>'mixed', 'preserve_keys'=>'bool'],
'SNMP::getErrno' => ['int'],
'SNMP::getError' => ['int'],
'SNMP::getnext' => ['mixed', 'object_id'=>'mixed'],
'SNMP::set' => ['bool', 'object_id'=>'mixed', 'type'=>'mixed', 'value'=>'mixed'],
'SNMP::setSecurity' => ['bool', 'sec_level'=>'string', 'auth_protocol'=>'string', 'auth_passphrase'=>'string', 'priv_protocol'=>'string', 'priv_passphrase'=>'string', 'contextname'=>'string', 'contextengineid'=>'string'],
'SNMP::walk' => ['array', 'object_id'=>'string', 'suffix_as_key'=>'bool', 'max_repetitions'=>'int', 'non_repeaters'=>'int'],
'snmp_get_quick_print' => ['bool'],
'snmp_get_valueretrieval' => ['int'],
'snmp_read_mib' => ['bool', 'filename'=>'string'],
'snmp_set_enum_print' => ['bool', 'enum_print'=>'int'],
'snmp_set_oid_numeric_print' => ['void', 'oid_format'=>'int'],
'snmp_set_oid_output_format' => ['bool', 'oid_format'=>'int'],
'snmp_set_quick_print' => ['bool', 'quick_print'=>'int'],
'snmp_set_valueretrieval' => ['bool', 'method'=>'int'],
'snmpget' => ['string', 'host'=>'string', 'community'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'],
'snmpgetnext' => ['string', 'host'=>'string', 'community'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'],
'snmprealwalk' => ['array', 'host'=>'string', 'community'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'],
'snmpset' => ['bool', 'host'=>'string', 'community'=>'string', 'object_id'=>'string', 'type'=>'string', 'value'=>'mixed', 'timeout='=>'int', 'retries='=>'int'],
'snmpwalk' => ['array', 'host'=>'string', 'community'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'],
'snmpwalkoid' => ['array', 'hostname'=>'string', 'community'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'],
'SoapClient::__call' => ['', 'function_name'=>'string', 'arguments'=>'string'],
'SoapClient::__construct' => ['void', 'wsdl'=>'mixed', 'options='=>'array'],
'SoapClient::__doRequest' => ['string', 'request'=>'string', 'location'=>'string', 'action'=>'string', 'version'=>'int', 'one_way='=>'int'],
'SoapClient::__getCookies' => ['array'],
'SoapClient::__getFunctions' => ['array'],
'SoapClient::__getLastRequest' => ['string'],
'SoapClient::__getLastRequestHeaders' => ['string'],
'SoapClient::__getLastResponse' => ['string'],
'SoapClient::__getLastResponseHeaders' => ['string'],
'SoapClient::__getTypes' => ['array'],
'SoapClient::__setCookie' => ['', 'name'=>'string', 'value='=>'string'],
'SoapClient::__setLocation' => ['string', 'new_location='=>'string'],
'SoapClient::__setSoapHeaders' => ['bool', 'soapheaders='=>''],
'SoapClient::__soapCall' => ['', 'function_name'=>'string', 'arguments'=>'array', 'options='=>'array', 'input_headers='=>'', '&w_output_headers='=>'array'],
'SoapClient::SoapClient' => ['object', 'wsdl'=>'mixed', 'options='=>'array'],
'SoapFault::__construct' => ['void', 'faultcode'=>'string', 'faultstring'=>'string', 'faultactor='=>'string', 'detail='=>'string', 'faultname='=>'string', 'headerfault='=>'string'],
'SoapFault::__toString' => ['string'],
'SoapFault::SoapFault' => ['object', 'faultcode'=>'string', 'faultstring'=>'string', 'faultactor='=>'string', 'detail='=>'string', 'faultname='=>'string', 'headerfault='=>'string'],
'SoapHeader::__construct' => ['void', 'namespace'=>'string', 'name'=>'string', 'data='=>'mixed', 'mustunderstand='=>'bool', 'actor='=>'string'],
'SoapHeader::SoapHeader' => ['object', 'namespace'=>'string', 'name'=>'string', 'data='=>'mixed', 'mustunderstand='=>'bool', 'actor='=>'string'],
'SoapParam::__construct' => ['void', 'data'=>'mixed', 'name'=>'string'],
'SoapParam::SoapParam' => ['object', 'data'=>'mixed', 'name'=>'string'],
'SoapServer::__construct' => ['void', 'wsdl'=>'?string', 'options='=>'array'],
'SoapServer::addFunction' => ['void', 'functions'=>'mixed'],
'SoapServer::addSoapHeader' => ['void', 'object'=>'soapheader'],
'SoapServer::fault' => ['void', 'code'=>'string', 'string'=>'string', 'actor='=>'string', 'details='=>'string', 'name='=>'string'],
'SoapServer::getFunctions' => ['array'],
'SoapServer::handle' => ['void', 'soap_request='=>'string'],
'SoapServer::setClass' => ['void', 'class_name'=>'string', '...args='=>'mixed'],
'SoapServer::setObject' => ['void', 'obj'=>'object'],
'SoapServer::setPersistence' => ['void', 'mode'=>'int'],
'SoapServer::SoapServer' => ['object', 'wsdl'=>'?string', 'options'=>'array'],
'SoapVar::__construct' => ['void', 'data'=>'mixed', 'encoding'=>'int', 'type_name='=>'string', 'type_namespace='=>'string', 'node_name='=>'string', 'node_namespace='=>'string'],
'SoapVar::SoapVar' => ['object', 'data'=>'mixed', 'encoding'=>'int', 'type_name='=>'string', 'type_namespace='=>'string', 'node_name='=>'string', 'node_namespace='=>'string'],
'socket_accept' => ['resource|false', 'socket'=>'resource'],
'socket_addrinfo_bind' => ['resource|null', 'addrinfo'=>'resource'],
'socket_addrinfo_connect' => ['resource|null', 'addrinfo'=>'resource'],
'socket_addrinfo_explain' => ['array', 'addrinfo'=>'resource'],
'socket_addrinfo_lookup' => ['resource[]', 'node'=>'string', 'service='=>'mixed', 'hints='=>'array'],
'socket_bind' => ['bool', 'socket'=>'resource', 'addr'=>'string', 'port='=>'int'],
'socket_clear_error' => ['void', 'socket='=>'resource'],
'socket_close' => ['void', 'socket'=>'resource'],
'socket_cmsg_space' => ['int', 'level'=>'int', 'type'=>'int'],
'socket_connect' => ['bool', 'socket'=>'resource', 'addr'=>'string', 'port='=>'int'],
'socket_create' => ['resource|false', 'domain'=>'int', 'type'=>'int', 'protocol'=>'int'],
'socket_create_listen' => ['resource|false', 'port'=>'int', 'backlog='=>'int'],
'socket_create_pair' => ['bool', 'domain'=>'int', 'type'=>'int', 'protocol'=>'int', '&w_fd'=>'resource[]'],
'socket_export_stream' => ['resource|false', 'socket'=>'resource'],
'socket_get_option' => ['mixed', 'socket'=>'resource', 'level'=>'int', 'optname'=>'int'],
'socket_getopt' => ['mixed', 'socket'=>'resource', 'level'=>'int', 'optname'=>'int'],
'socket_getpeername' => ['bool', 'socket'=>'resource', '&w_addr'=>'string', '&w_port='=>'int'],
'socket_getsockname' => ['bool', 'socket'=>'resource', '&w_addr'=>'string', '&w_port='=>'int'],
'socket_import_stream' => ['resource|false', 'stream'=>'resource'],
'socket_last_error' => ['int', 'socket='=>'resource'],
'socket_listen' => ['bool', 'socket'=>'resource', 'backlog='=>'int'],
'socket_read' => ['string|false', 'socket'=>'resource', 'length'=>'int', 'type='=>'int'],
'socket_recv' => ['int|false', 'socket'=>'resource', '&w_buf'=>'string', 'len'=>'int', 'flags'=>'int'],
'socket_recvfrom' => ['int|false', 'socket'=>'resource', '&w_buf'=>'string', 'len'=>'int', 'flags'=>'int', '&w_name'=>'string', '&w_port='=>'int'],
'socket_recvmsg' => ['int|false', 'socket'=>'resource', '&w_message'=>'string', 'flags='=>'int'],
'socket_select' => ['int|false', '&rw_read_fds'=>'resource[]|null', '&rw_write_fds'=>'resource[]|null', '&rw_except_fds'=>'resource[]|null', 'tv_sec'=>'int', 'tv_usec='=>'int'],
'socket_send' => ['int|false', 'socket'=>'resource', 'buf'=>'string', 'len'=>'int', 'flags'=>'int'],
'socket_sendmsg' => ['int|false', 'socket'=>'resource', 'message'=>'array', 'flags'=>'int'],
'socket_sendto' => ['int|false', 'socket'=>'resource', 'buf'=>'string', 'len'=>'int', 'flags'=>'int', 'addr'=>'string', 'port='=>'int'],
'socket_set_block' => ['bool', 'socket'=>'resource'],
'socket_set_nonblock' => ['bool', 'socket'=>'resource'],
'socket_set_option' => ['bool', 'socket'=>'resource', 'level'=>'int', 'optname'=>'int', 'optval'=>'int|string|array'],
'socket_shutdown' => ['bool', 'socket'=>'resource', 'how='=>'int'],
'socket_strerror' => ['string', 'errno'=>'int'],
'socket_write' => ['int|false', 'socket'=>'resource', 'buf'=>'string', 'length='=>'int'],
'Sodium\add' => ['', '&left'=>'string', 'right'=>'string'],
'Sodium\bin2hex' => ['string', 'binary'=>'string'],
'Sodium\compare' => ['int', 'left'=>'string', 'right'=>'string'],
'Sodium\crypto_aead_aes256gcm_decrypt' => ['string', 'msg'=>'string', 'nonce'=>'string', 'key'=>'string', 'ad='=>'string'],
'Sodium\crypto_aead_aes256gcm_encrypt' => ['string', 'msg'=>'string', 'nonce'=>'string', 'key'=>'string', 'ad='=>'string'],
'Sodium\crypto_aead_aes256gcm_is_available' => ['bool'],
'Sodium\crypto_aead_chacha20poly1305_decrypt' => ['string', 'msg'=>'string', 'nonce'=>'string', 'key'=>'string', 'ad='=>'string'],
'Sodium\crypto_aead_chacha20poly1305_encrypt' => ['string', 'msg'=>'string', 'nonce'=>'string', 'key'=>'string', 'ad='=>'string'],
'Sodium\crypto_auth' => ['string', 'msg'=>'string', 'key'=>'string'],
'Sodium\crypto_auth_verify' => ['bool', 'mac'=>'string', 'msg'=>'string', 'key'=>'string'],
'Sodium\crypto_box' => ['string', 'msg'=>'string', 'nonce'=>'string', 'keypair'=>'string'],
'Sodium\crypto_box_keypair' => ['string'],
'Sodium\crypto_box_keypair_from_secretkey_and_publickey' => ['string', 'secretkey'=>'string', 'publickey'=>'string'],
'Sodium\crypto_box_open' => ['string', 'msg'=>'string', 'nonce'=>'string', 'keypair'=>'string'],
'Sodium\crypto_box_publickey' => ['string', 'keypair'=>'string'],
'Sodium\crypto_box_publickey_from_secretkey' => ['string', 'secretkey'=>'string'],
'Sodium\crypto_box_seal' => ['string', 'message'=>'string', 'publickey'=>'string'],
'Sodium\crypto_box_seal_open' => ['string', 'encrypted'=>'string', 'keypair'=>'string'],
'Sodium\crypto_box_secretkey' => ['string', 'keypair'=>'string'],
'Sodium\crypto_box_seed_keypair' => ['string', 'seed'=>'string'],
'Sodium\crypto_generichash' => ['string', 'input'=>'string', 'key='=>'string', 'length='=>'int'],
'Sodium\crypto_generichash_final' => ['string', 'state'=>'string', 'length='=>'int'],
'Sodium\crypto_generichash_init' => ['string', 'key='=>'string', 'length='=>'int'],
'Sodium\crypto_generichash_update' => ['bool', '&hashState'=>'string', 'append'=>'string'],
'Sodium\crypto_kx' => ['string', 'secretkey'=>'string', 'publickey'=>'string', 'client_publickey'=>'string', 'server_publickey'=>'string'],
'Sodium\crypto_pwhash' => ['string', 'out_len'=>'int', 'passwd'=>'string', 'salt'=>'string', 'opslimit'=>'int', 'memlimit'=>'int'],
'Sodium\crypto_pwhash_scryptsalsa208sha256' => ['string', 'out_len'=>'int', 'passwd'=>'string', 'salt'=>'string', 'opslimit'=>'int', 'memlimit'=>'int'],
'Sodium\crypto_pwhash_scryptsalsa208sha256_str' => ['string', 'passwd'=>'string', 'opslimit'=>'int', 'memlimit'=>'int'],
'Sodium\crypto_pwhash_scryptsalsa208sha256_str_verify' => ['bool', 'hash'=>'string', 'passwd'=>'string'],
'Sodium\crypto_pwhash_str' => ['string', 'passwd'=>'string', 'opslimit'=>'int', 'memlimit'=>'int'],
'Sodium\crypto_pwhash_str_verify' => ['bool', 'hash'=>'string', 'passwd'=>'string'],
'Sodium\crypto_scalarmult' => ['string', 'ecdhA'=>'string', 'ecdhB'=>'string'],
'Sodium\crypto_scalarmult_base' => ['string', 'sk'=>'string'],
'Sodium\crypto_secretbox' => ['string', 'plaintext'=>'string', 'nonce'=>'string', 'key'=>'string'],
'Sodium\crypto_secretbox_open' => ['string', 'ciphertext'=>'string', 'nonce'=>'string', 'key'=>'string'],
'Sodium\crypto_shorthash' => ['string', 'message'=>'string', 'key'=>'string'],
'Sodium\crypto_sign' => ['string', 'message'=>'string', 'secretkey'=>'string'],
'Sodium\crypto_sign_detached' => ['string', 'message'=>'string', 'secretkey'=>'string'],
'Sodium\crypto_sign_ed25519_pk_to_curve25519' => ['string', 'sign_pk'=>'string'],
'Sodium\crypto_sign_ed25519_sk_to_curve25519' => ['string', 'sign_sk'=>'string'],
'Sodium\crypto_sign_keypair' => ['string'],
'Sodium\crypto_sign_keypair_from_secretkey_and_publickey' => ['string', 'secretkey'=>'string', 'publickey'=>'string'],
'Sodium\crypto_sign_open' => ['string|false', 'signed_message'=>'string', 'publickey'=>'string'],
'Sodium\crypto_sign_publickey' => ['string', 'keypair'=>'string'],
'Sodium\crypto_sign_publickey_from_secretkey' => ['string', 'secretkey'=>'string'],
'Sodium\crypto_sign_secretkey' => ['string', 'keypair'=>'string'],
'Sodium\crypto_sign_seed_keypair' => ['string', 'seed'=>'string'],
'Sodium\crypto_sign_verify_detached' => ['bool', 'signature'=>'string', 'msg'=>'string', 'publickey'=>'string'],
'Sodium\crypto_stream' => ['string', 'length'=>'int', 'nonce'=>'string', 'key'=>'string'],
'Sodium\crypto_stream_xor' => ['string', 'plaintext'=>'string', 'nonce'=>'string', 'key'=>'string'],
'Sodium\hex2bin' => ['string', 'hex'=>'string'],
'Sodium\increment' => ['string', '&nonce'=>'string'],
'Sodium\library_version_major' => ['int'],
'Sodium\library_version_minor' => ['int'],
'Sodium\memcmp' => ['int', 'left'=>'string', 'right'=>'string'],
'Sodium\memzero' => ['', '&target'=>'string'],
'Sodium\randombytes_buf' => ['string', 'length'=>'int'],
'Sodium\randombytes_random16' => ['int|string'],
'Sodium\randombytes_uniform' => ['int', 'upperBoundNonInclusive'=>'int'],
'Sodium\version_string' => ['string'],
'sodium_add' => ['string', 'string_1'=>'string', 'string_2'=>'string'],
'sodium_base642bin' => ['string', 'base64'=>'string', 'variant'=>'int', 'ignore'=>'string'],
'sodium_bin2base64' => ['string', 'binary'=>'string', 'variant'=>'int'],
'sodium_bin2hex' => ['string', 'binary'=>'string'],
'sodium_compare' => ['int', 'string_1'=>'string', 'string_2'=>'string'],
'sodium_crypto_aead_aes256gcm_decrypt' => ['string|false', 'confidential_message'=>'string', 'public_message'=>'string', 'nonce'=>'string', 'key'=>'string'],
'sodium_crypto_aead_aes256gcm_encrypt' => ['string', 'confidential_message'=>'string', 'public_message'=>'string', 'nonce'=>'string', 'key'=>'string'],
'sodium_crypto_aead_aes256gcm_is_available' => ['bool'],
'sodium_crypto_aead_aes256gcm_keygen' => ['string'],
'sodium_crypto_aead_chacha20poly1305_decrypt' => ['string', 'confidential_message'=>'string', 'public_message'=>'string', 'nonce'=>'string', 'key'=>'string'],
'sodium_crypto_aead_chacha20poly1305_encrypt' => ['string', 'confidential_message'=>'string', 'public_message'=>'string', 'nonce'=>'string', 'key'=>'string'],
'sodium_crypto_aead_chacha20poly1305_ietf_decrypt' => ['string|false', 'confidential_message'=>'string', 'public_message'=>'string', 'nonce'=>'string', 'key'=>'string'],
'sodium_crypto_aead_chacha20poly1305_ietf_encrypt' => ['string', 'confidential_message'=>'string', 'public_message'=>'string', 'nonce'=>'string', 'key'=>'string'],
'sodium_crypto_aead_chacha20poly1305_ietf_keygen' => ['string'],
'sodium_crypto_aead_chacha20poly1305_keygen' => ['string'],
'sodium_crypto_aead_xchacha20poly1305_ietf_decrypt' => ['string|false', 'confidential_message'=>'string', 'public_message'=>'string', 'nonce'=>'string', 'key'=>'string'],
'sodium_crypto_aead_xchacha20poly1305_ietf_encrypt' => ['string', 'confidential_message'=>'string', 'public_message'=>'string', 'nonce'=>'string', 'key'=>'string'],
'sodium_crypto_aead_xchacha20poly1305_ietf_keygen' => ['string'],
'sodium_crypto_auth' => ['string', 'message'=>'string', 'key'=>'string'],
'sodium_crypto_auth_keygen' => ['string'],
'sodium_crypto_auth_verify' => ['bool', 'mac'=>'string', 'message'=>'string', 'key'=>'string'],
'sodium_crypto_box' => ['string', 'string'=>'string', 'nonce'=>'string', 'key'=>'string'],
'sodium_crypto_box_keypair' => ['string'],
'sodium_crypto_box_keypair_from_secretkey_and_publickey' => ['string', 'secret_key'=>'string', 'public_key'=>'string'],
'sodium_crypto_box_open' => ['string|false', 'message'=>'string', 'nonce'=>'string', 'message_keypair'=>'string'],
'sodium_crypto_box_publickey' => ['string', 'keypair'=>'string'],
'sodium_crypto_box_publickey_from_secretkey' => ['string', 'secretkey'=>'string'],
'sodium_crypto_box_seal' => ['string', 'message'=>'string', 'publickey'=>'string'],
'sodium_crypto_box_seal_open' => ['string|false', 'message'=>'string', 'recipient_keypair'=>'string'],
'sodium_crypto_box_secretkey' => ['string', 'keypair'=>'string'],
'sodium_crypto_box_seed_keypair' => ['string', 'seed'=>'string'],
'sodium_crypto_generichash' => ['string', 'msg'=>'string', 'key='=>'?string', 'length='=>'?int'],
'sodium_crypto_generichash_final' => ['string', 'state'=>'string', 'length='=>'?int'],
'sodium_crypto_generichash_init' => ['string', 'key='=>'?string', 'length='=>'?int'],
'sodium_crypto_generichash_keygen' => ['string'],
'sodium_crypto_generichash_update' => ['bool', 'state'=>'string', 'string'=>'string'],
'sodium_crypto_kdf_derive_from_key' => ['string', 'subkey_len'=>'int', 'subkey_id'=>'int', 'context'=>'string', 'key'=>'string'],
'sodium_crypto_kdf_keygen' => ['string'],
'sodium_crypto_kx' => ['string', 'secretkey'=>'string', 'publickey'=>'string', 'client_publickey'=>'string', 'server_publickey'=>'string'],
'sodium_crypto_kx_client_session_keys' => ['string', 'client_keypair'=>'string', 'server_key'=>'string'],
'sodium_crypto_kx_keypair' => ['string'],
'sodium_crypto_kx_publickey' => ['string', 'keypair'=>'string'],
'sodium_crypto_kx_secretkey' => ['string', 'keypair'=>'string'],
'sodium_crypto_kx_seed_keypair' => ['string', 'seed'=>'string'],
'sodium_crypto_kx_server_session_keys' => ['string', 'server_keypair'=>'string', 'client_key'=>'string'],
'sodium_crypto_pwhash' => ['string', 'length'=>'int', 'password'=>'string', 'salt'=>'string', 'opslimit'=>'int', 'memlimit'=>'int', 'alg='=>'int'],
'sodium_crypto_pwhash_scryptsalsa208sha256' => ['string', 'length'=>'int', 'password'=>'string', 'salt'=>'string', 'opslimit'=>'int', 'memlimit'=>'int'],
'sodium_crypto_pwhash_scryptsalsa208sha256_str' => ['string', 'password'=>'string', 'opslimit'=>'int', 'memlimit'=>'int'],
'sodium_crypto_pwhash_scryptsalsa208sha256_str_verify' => ['bool', 'hash'=>'string', 'password'=>'string'],
'sodium_crypto_pwhash_str' => ['string', 'password'=>'string', 'opslimit'=>'int', 'memlimit'=>'int'],
'sodium_crypto_pwhash_str_needs_rehash' => ['bool', 'password'=>'string', 'opslimit'=>'int', 'memlimit'=>'int'],
'sodium_crypto_pwhash_str_verify' => ['bool', 'hash'=>'string', 'password'=>'string'],
'sodium_crypto_scalarmult' => ['string', 'string_1'=>'string', 'string_2'=>'string'],
'sodium_crypto_scalarmult_base' => ['string', 'string_1'=>'string', 'string_2'=>'string'],
'sodium_crypto_secretbox' => ['string', 'plaintext'=>'string', 'nonce'=>'string', 'key'=>'string'],
'sodium_crypto_secretbox_keygen' => ['string'],
'sodium_crypto_secretbox_open' => ['string|false', 'ciphertext'=>'string', 'nonce'=>'string', 'key'=>'string'],
'sodium_crypto_secretstream_xchacha20poly1305_init_pull' => ['string', 'header'=>'string', 'key'=>'string'],
'sodium_crypto_secretstream_xchacha20poly1305_init_push' => ['array', 'key'=>'string'],
'sodium_crypto_secretstream_xchacha20poly1305_keygen' => ['string'],
'sodium_crypto_secretstream_xchacha20poly1305_pull' => ['array', 'state'=>'string', 'c'=>'string', 'ad='=>'string'],
'sodium_crypto_secretstream_xchacha20poly1305_push' => ['string', 'state'=>'string', 'msg'=>'string', 'ad='=>'string', 'tag='=>'int'],
'sodium_crypto_secretstream_xchacha20poly1305_rekey' => ['void', 'state'=>'string'],
'sodium_crypto_shorthash' => ['string', 'message'=>'string', 'key'=>'string'],
'sodium_crypto_shorthash_keygen' => ['string'],
'sodium_crypto_sign' => ['string', 'message'=>'string', 'secretkey'=>'string'],
'sodium_crypto_sign_detached' => ['string', 'message'=>'string', 'secretkey'=>'string'],
'sodium_crypto_sign_ed25519_pk_to_curve25519' => ['string', 'ed25519pk'=>'string'],
'sodium_crypto_sign_ed25519_sk_to_curve25519' => ['string', 'ed25519sk'=>'string'],
'sodium_crypto_sign_keypair' => ['string'],
'sodium_crypto_sign_keypair_from_secretkey_and_publickey' => ['string', 'secret_key'=>'string', 'public_key'=>'string'],
'sodium_crypto_sign_open' => ['string|false', 'message'=>'string', 'publickey'=>'string'],
'sodium_crypto_sign_publickey' => ['string', 'keypair'=>'string'],
'sodium_crypto_sign_publickey_from_secretkey' => ['string', 'secretkey'=>'string'],
'sodium_crypto_sign_secretkey' => ['string', 'keypair'=>'string'],
'sodium_crypto_sign_seed_keypair' => ['string', 'seed'=>'string'],
'sodium_crypto_sign_verify_detached' => ['bool', 'signature'=>'string', 'message'=>'string', 'publickey'=>'string'],
'sodium_crypto_stream' => ['string', 'length'=>'int', 'nonce'=>'string', 'key'=>'string'],
'sodium_crypto_stream_keygen' => ['string'],
'sodium_crypto_stream_xor' => ['string', 'message'=>'string', 'nonce'=>'string', 'key'=>'string'],
'sodium_hex2bin' => ['string', 'hex'=>'string', 'ignore='=>'string'],
'sodium_increment' => ['string', '&binary_string'=>'string'],
'sodium_library_version_major' => ['int'],
'sodium_library_version_minor' => ['int'],
'sodium_memcmp' => ['int', 'string_1'=>'string', 'string_2'=>'string'],
'sodium_memzero' => ['void', '&secret'=>'string'],
'sodium_pad' => ['string', 'unpadded'=>'string', 'length'=>'int'],
'sodium_randombytes_buf' => ['string', 'length'=>'int'],
'sodium_randombytes_random16' => ['int|string'],
'sodium_randombytes_uniform' => ['int', 'upperBoundNonInclusive'=>'int'],
'sodium_unpad' => ['string', 'padded'=>'string', 'length'=>'int'],
'sodium_version_string' => ['string'],
'solid_fetch_prev' => ['bool', 'result_id'=>''],
'solr_get_version' => ['string'],
'SolrClient::__construct' => ['void', 'clientOptions'=>'array'],
'SolrClient::__destruct' => [''],
'SolrClient::addDocument' => ['SolrUpdateResponse', 'doc'=>'solrinputdocument', 'allowdups='=>'bool', 'commitwithin='=>'int'],
'SolrClient::addDocuments' => ['SolrUpdateResponse', 'docs'=>'array', 'allowdups='=>'bool', 'commitwithin='=>'int'],
'SolrClient::commit' => ['SolrUpdateResponse', 'maxsegments='=>'int', 'waitflush='=>'bool', 'waitsearcher='=>'bool'],
'SolrClient::deleteById' => ['SolrUpdateResponse', 'id'=>'string'],
'SolrClient::deleteByIds' => ['SolrUpdateResponse', 'ids'=>'array'],
'SolrClient::deleteByQueries' => ['SolrUpdateResponse', 'queries'=>'array'],
'SolrClient::deleteByQuery' => ['SolrUpdateResponse', 'query'=>'string'],
'SolrClient::getById' => ['SolrQueryResponse', 'id'=>'string'],
'SolrClient::getByIds' => ['SolrQueryResponse', 'ids'=>'array'],
'SolrClient::getDebug' => ['string'],
'SolrClient::getOptions' => ['array'],
'SolrClient::optimize' => ['SolrUpdateResponse', 'maxsegments='=>'int', 'waitflush='=>'bool', 'waitsearcher='=>'bool'],
'SolrClient::ping' => ['SolrPingResponse'],
'SolrClient::query' => ['SolrQueryResponse', 'query'=>'solrparams'],
'SolrClient::request' => ['SolrUpdateResponse', 'raw_request'=>'string'],
'SolrClient::rollback' => ['SolrUpdateResponse'],
'SolrClient::setResponseWriter' => ['void', 'responsewriter'=>'string'],
'SolrClient::setServlet' => ['bool', 'type'=>'int', 'value'=>'string'],
'SolrClient::system' => ['void'],
'SolrClient::threads' => ['void'],
'SolrClientException::getInternalInfo' => ['array'],
'SolrCollapseFunction::__toString' => ['string'],
'SolrCollapseFunction::getField' => ['string'],
'SolrCollapseFunction::getHint' => ['string'],
'SolrCollapseFunction::getMax' => ['string'],
'SolrCollapseFunction::getMin' => ['string'],
'SolrCollapseFunction::getNullPolicy' => ['string'],
'SolrCollapseFunction::getSize' => ['int'],
'SolrCollapseFunction::setField' => ['SolrCollapseFunction', 'fieldName'=>'string'],
'SolrCollapseFunction::setHint' => ['SolrCollapseFunction', 'hint'=>'string'],
'SolrCollapseFunction::setMax' => ['SolrCollapseFunction', 'max'=>'string'],
'SolrCollapseFunction::setMin' => ['SolrCollapseFunction', 'min'=>'string'],
'SolrCollapseFunction::setNullPolicy' => ['SolrCollapseFunction', 'nullPolicy'=>'string'],
'SolrCollapseFunction::setSize' => ['SolrCollapseFunction', 'size'=>'int'],
'SolrDisMaxQuery::__construct' => ['void', 'q='=>'string'],
'SolrDisMaxQuery::addBigramPhraseField' => ['SolrDisMaxQuery', 'field'=>'string', 'boost'=>'string', 'slop='=>'string'],
'SolrDisMaxQuery::addBoostQuery' => ['SolrDisMaxQuery', 'field'=>'string', 'value'=>'string', 'boost='=>'string'],
'SolrDisMaxQuery::addExpandFilterQuery' => ['SolrQuery', 'fq'=>'string'],
'SolrDisMaxQuery::addExpandSortField' => ['SolrQuery', 'field'=>'string', 'order'=>'string'],
'SolrDisMaxQuery::addFacetDateField' => ['SolrQuery', 'dateField'=>'string'],
'SolrDisMaxQuery::addFacetDateOther' => ['SolrQuery', 'value'=>'string', 'field_override'=>'string'],
'SolrDisMaxQuery::addFacetField' => ['SolrQuery', 'field'=>'string'],
'SolrDisMaxQuery::addFacetQuery' => ['SolrQuery', 'facetQuery'=>'string'],
'SolrDisMaxQuery::addField' => ['SolrQuery', 'field'=>'string'],
'SolrDisMaxQuery::addFilterQuery' => ['SolrQuery', 'fq'=>'string'],
'SolrDisMaxQuery::addGroupField' => ['SolrQuery', 'value'=>'string'],
'SolrDisMaxQuery::addGroupFunction' => ['SolrQuery', 'value'=>'string'],
'SolrDisMaxQuery::addGroupQuery' => ['SolrQuery', 'value'=>'string'],
'SolrDisMaxQuery::addGroupSortField' => ['SolrQuery', 'field'=>'string', 'order'=>'int'],
'SolrDisMaxQuery::addHighlightField' => ['SolrQuery', 'field'=>'string'],
'SolrDisMaxQuery::addMltField' => ['SolrQuery', 'field'=>'string'],
'SolrDisMaxQuery::addMltQueryField' => ['SolrQuery', 'field'=>'string', 'boost'=>'float'],
'SolrDisMaxQuery::addParam' => ['SolrParams', 'name'=>'string', 'value'=>'string'],
'SolrDisMaxQuery::addPhraseField' => ['SolrDisMaxQuery', 'field'=>'string', 'boost'=>'string', 'slop='=>'string'],
'SolrDisMaxQuery::addQueryField' => ['SolrDisMaxQuery', 'field'=>'string', 'boost='=>'string'],
'SolrDisMaxQuery::addSortField' => ['SolrQuery', 'field'=>'string', 'order='=>'int'],
'SolrDisMaxQuery::addStatsFacet' => ['SolrQuery', 'field'=>'string'],
'SolrDisMaxQuery::addStatsField' => ['SolrQuery', 'field'=>'string'],
'SolrDisMaxQuery::addTrigramPhraseField' => ['SolrDisMaxQuery', 'field'=>'string', 'boost'=>'string', 'slop='=>'string'],
'SolrDisMaxQuery::addUserField' => ['SolrDisMaxQuery', 'field'=>'string'],
'SolrDisMaxQuery::collapse' => ['SolrQuery', 'collapseFunction'=>'SolrCollapseFunction'],
'SolrDisMaxQuery::get' => ['mixed', 'param_name'=>'string'],
'SolrDisMaxQuery::getExpand' => ['bool'],
'SolrDisMaxQuery::getExpandFilterQueries' => ['array'],
'SolrDisMaxQuery::getExpandQuery' => ['array'],
'SolrDisMaxQuery::getExpandRows' => ['int'],
'SolrDisMaxQuery::getExpandSortFields' => ['array'],
'SolrDisMaxQuery::getFacet' => ['bool'],
'SolrDisMaxQuery::getFacetDateEnd' => ['string', 'field_override'=>'string'],
'SolrDisMaxQuery::getFacetDateFields' => ['array'],
'SolrDisMaxQuery::getFacetDateGap' => ['string', 'field_override'=>'string'],
'SolrDisMaxQuery::getFacetDateHardEnd' => ['string', 'field_override'=>'string'],
'SolrDisMaxQuery::getFacetDateOther' => ['string', 'field_override'=>'string'],
'SolrDisMaxQuery::getFacetDateStart' => ['string', 'field_override'=>'string'],
'SolrDisMaxQuery::getFacetFields' => ['array'],
'SolrDisMaxQuery::getFacetLimit' => ['int', 'field_override'=>'string'],
'SolrDisMaxQuery::getFacetMethod' => ['string', 'field_override'=>'string'],
'SolrDisMaxQuery::getFacetMinCount' => ['int', 'field_override'=>'string'],
'SolrDisMaxQuery::getFacetMissing' => ['string', 'field_override'=>'string'],
'SolrDisMaxQuery::getFacetOffset' => ['int', 'field_override'=>'string'],
'SolrDisMaxQuery::getFacetPrefix' => ['string', 'field_override'=>'string'],
'SolrDisMaxQuery::getFacetQueries' => ['string'],
'SolrDisMaxQuery::getFacetSort' => ['int', 'field_override'=>'string'],
'SolrDisMaxQuery::getFields' => ['string'],
'SolrDisMaxQuery::getFilterQueries' => ['string'],
'SolrDisMaxQuery::getGroup' => ['bool'],
'SolrDisMaxQuery::getGroupCachePercent' => ['int'],
'SolrDisMaxQuery::getGroupFacet' => ['bool'],
'SolrDisMaxQuery::getGroupFields' => ['array'],
'SolrDisMaxQuery::getGroupFormat' => ['string'],
'SolrDisMaxQuery::getGroupFunctions' => ['array'],
'SolrDisMaxQuery::getGroupLimit' => ['int'],
'SolrDisMaxQuery::getGroupMain' => ['bool'],
'SolrDisMaxQuery::getGroupNGroups' => ['bool'],
'SolrDisMaxQuery::getGroupOffset' => ['bool'],
'SolrDisMaxQuery::getGroupQueries' => ['array'],
'SolrDisMaxQuery::getGroupSortFields' => ['array'],
'SolrDisMaxQuery::getGroupTruncate' => ['bool'],
'SolrDisMaxQuery::getHighlight' => ['bool'],
'SolrDisMaxQuery::getHighlightAlternateField' => ['string', 'field_override'=>'string'],
'SolrDisMaxQuery::getHighlightFields' => ['array'],
'SolrDisMaxQuery::getHighlightFormatter' => ['string', 'field_override'=>'string'],
'SolrDisMaxQuery::getHighlightFragmenter' => ['string', 'field_override'=>'string'],
'SolrDisMaxQuery::getHighlightFragsize' => ['int', 'field_override'=>'string'],
'SolrDisMaxQuery::getHighlightHighlightMultiTerm' => ['bool'],
'SolrDisMaxQuery::getHighlightMaxAlternateFieldLength' => ['int', 'field_override'=>'string'],
'SolrDisMaxQuery::getHighlightMaxAnalyzedChars' => ['int'],
'SolrDisMaxQuery::getHighlightMergeContiguous' => ['bool', 'field_override'=>'string'],
'SolrDisMaxQuery::getHighlightRegexMaxAnalyzedChars' => ['int'],
'SolrDisMaxQuery::getHighlightRegexPattern' => ['string'],
'SolrDisMaxQuery::getHighlightRegexSlop' => ['float'],
'SolrDisMaxQuery::getHighlightRequireFieldMatch' => ['bool'],
'SolrDisMaxQuery::getHighlightSimplePost' => ['string', 'field_override'=>'string'],
'SolrDisMaxQuery::getHighlightSimplePre' => ['string', 'field_override'=>'string'],
'SolrDisMaxQuery::getHighlightSnippets' => ['int', 'field_override'=>'string'],
'SolrDisMaxQuery::getHighlightUsePhraseHighlighter' => ['bool'],
'SolrDisMaxQuery::getMlt' => ['bool'],
'SolrDisMaxQuery::getMltBoost' => ['bool'],
'SolrDisMaxQuery::getMltCount' => ['int'],
'SolrDisMaxQuery::getMltFields' => ['array'],
'SolrDisMaxQuery::getMltMaxNumQueryTerms' => ['int'],
'SolrDisMaxQuery::getMltMaxNumTokens' => ['int'],
'SolrDisMaxQuery::getMltMaxWordLength' => ['int'],
'SolrDisMaxQuery::getMltMinDocFrequency' => ['int'],
'SolrDisMaxQuery::getMltMinTermFrequency' => ['int'],
'SolrDisMaxQuery::getMltMinWordLength' => ['int'],
'SolrDisMaxQuery::getMltQueryFields' => ['array'],
'SolrDisMaxQuery::getParam' => ['mixed', 'param_name'=>'string'],
'SolrDisMaxQuery::getParams' => ['array'],
'SolrDisMaxQuery::getPreparedParams' => ['array'],
'SolrDisMaxQuery::getQuery' => ['string'],
'SolrDisMaxQuery::getRows' => ['int'],
'SolrDisMaxQuery::getSortFields' => ['array'],
'SolrDisMaxQuery::getStart' => ['int'],
'SolrDisMaxQuery::getStats' => ['bool'],
'SolrDisMaxQuery::getStatsFacets' => ['array'],
'SolrDisMaxQuery::getStatsFields' => ['array'],
'SolrDisMaxQuery::getTerms' => ['bool'],
'SolrDisMaxQuery::getTermsField' => ['string'],
'SolrDisMaxQuery::getTermsIncludeLowerBound' => ['bool'],
'SolrDisMaxQuery::getTermsIncludeUpperBound' => ['bool'],
'SolrDisMaxQuery::getTermsLimit' => ['int'],
'SolrDisMaxQuery::getTermsLowerBound' => ['string'],
'SolrDisMaxQuery::getTermsMaxCount' => ['int'],
'SolrDisMaxQuery::getTermsMinCount' => ['int'],
'SolrDisMaxQuery::getTermsPrefix' => ['string'],
'SolrDisMaxQuery::getTermsReturnRaw' => ['bool'],
'SolrDisMaxQuery::getTermsSort' => ['int'],
'SolrDisMaxQuery::getTermsUpperBound' => ['string'],
'SolrDisMaxQuery::getTimeAllowed' => ['int'],
'SolrDisMaxQuery::removeBigramPhraseField' => ['SolrDisMaxQuery', 'field'=>'string'],
'SolrDisMaxQuery::removeBoostQuery' => ['SolrDisMaxQuery', 'field'=>'string'],
'SolrDisMaxQuery::removeExpandFilterQuery' => ['SolrQuery', 'fq'=>'string'],
'SolrDisMaxQuery::removeExpandSortField' => ['SolrQuery', 'field'=>'string'],
'SolrDisMaxQuery::removeFacetDateField' => ['SolrQuery', 'field'=>'string'],
'SolrDisMaxQuery::removeFacetDateOther' => ['SolrQuery', 'value'=>'string', 'field_override'=>'string'],
'SolrDisMaxQuery::removeFacetField' => ['SolrQuery', 'field'=>'string'],
'SolrDisMaxQuery::removeFacetQuery' => ['SolrQuery', 'value'=>'string'],
'SolrDisMaxQuery::removeField' => ['SolrQuery', 'field'=>'string'],
'SolrDisMaxQuery::removeFilterQuery' => ['SolrQuery', 'fq'=>'string'],
'SolrDisMaxQuery::removeHighlightField' => ['SolrQuery', 'field'=>'string'],
'SolrDisMaxQuery::removeMltField' => ['SolrQuery', 'field'=>'string'],
'SolrDisMaxQuery::removeMltQueryField' => ['SolrQuery', 'queryField'=>'string'],
'SolrDisMaxQuery::removePhraseField' => ['SolrDisMaxQuery', 'field'=>'string'],
'SolrDisMaxQuery::removeQueryField' => ['SolrDisMaxQuery', 'field'=>'string'],
'SolrDisMaxQuery::removeSortField' => ['SolrQuery', 'field'=>'string'],
'SolrDisMaxQuery::removeStatsFacet' => ['SolrQuery', 'value'=>'string'],
'SolrDisMaxQuery::removeStatsField' => ['SolrQuery', 'field'=>'string'],
'SolrDisMaxQuery::removeTrigramPhraseField' => ['SolrDisMaxQuery', 'field'=>'string'],
'SolrDisMaxQuery::removeUserField' => ['SolrDisMaxQuery', 'field'=>'string'],
'SolrDisMaxQuery::serialize' => ['string'],
'SolrDisMaxQuery::set' => ['SolrParams', 'name'=>'string', 'value'=>''],
'SolrDisMaxQuery::setBigramPhraseFields' => ['SolrDisMaxQuery', 'fields'=>'string'],
'SolrDisMaxQuery::setBigramPhraseSlop' => ['SolrDisMaxQuery', 'slop'=>'string'],
'SolrDisMaxQuery::setBoostFunction' => ['SolrDisMaxQuery', 'function'=>'string'],
'SolrDisMaxQuery::setBoostQuery' => ['SolrDisMaxQuery', 'q'=>'string'],
'SolrDisMaxQuery::setEchoHandler' => ['SolrQuery', 'flag'=>'bool'],
'SolrDisMaxQuery::setEchoParams' => ['SolrQuery', 'type'=>'string'],
'SolrDisMaxQuery::setExpand' => ['SolrQuery', 'value'=>'bool'],
'SolrDisMaxQuery::setExpandQuery' => ['SolrQuery', 'q'=>'string'],
'SolrDisMaxQuery::setExpandRows' => ['SolrQuery', 'value'=>'int'],
'SolrDisMaxQuery::setExplainOther' => ['SolrQuery', 'query'=>'string'],
'SolrDisMaxQuery::setFacet' => ['SolrQuery', 'flag'=>'bool'],
'SolrDisMaxQuery::setFacetDateEnd' => ['SolrQuery', 'value'=>'string', 'field_override'=>'string'],
'SolrDisMaxQuery::setFacetDateGap' => ['SolrQuery', 'value'=>'string', 'field_override'=>'string'],
'SolrDisMaxQuery::setFacetDateHardEnd' => ['SolrQuery', 'value'=>'string', 'field_override'=>'string'],
'SolrDisMaxQuery::setFacetDateStart' => ['SolrQuery', 'value'=>'string', 'field_override'=>'string'],
'SolrDisMaxQuery::setFacetEnumCacheMinDefaultFrequency' => ['SolrQuery', 'frequency'=>'int', 'field_override'=>'string'],
'SolrDisMaxQuery::setFacetLimit' => ['SolrQuery', 'limit'=>'int', 'field_override'=>'string'],
'SolrDisMaxQuery::setFacetMethod' => ['SolrQuery', 'method'=>'string', 'field_override'=>'string'],
'SolrDisMaxQuery::setFacetMinCount' => ['SolrQuery', 'mincount'=>'int', 'field_override'=>'string'],
'SolrDisMaxQuery::setFacetMissing' => ['SolrQuery', 'flag'=>'bool', 'field_override'=>'string'],
'SolrDisMaxQuery::setFacetOffset' => ['SolrQuery', 'offset'=>'int', 'field_override'=>'string'],
'SolrDisMaxQuery::setFacetPrefix' => ['SolrQuery', 'prefix'=>'string', 'field_override'=>'string'],
'SolrDisMaxQuery::setFacetSort' => ['SolrQuery', 'facetSort'=>'int', 'field_override'=>'string'],
'SolrDisMaxQuery::setGroup' => ['SolrQuery', 'value'=>'bool'],
'SolrDisMaxQuery::setGroupCachePercent' => ['SolrQuery', 'percent'=>'int'],
'SolrDisMaxQuery::setGroupFacet' => ['SolrQuery', 'value'=>'bool'],
'SolrDisMaxQuery::setGroupFormat' => ['SolrQuery', 'value'=>'string'],
'SolrDisMaxQuery::setGroupLimit' => ['SolrQuery', 'value'=>'int'],
'SolrDisMaxQuery::setGroupMain' => ['SolrQuery', 'value'=>'string'],
'SolrDisMaxQuery::setGroupNGroups' => ['SolrQuery', 'value'=>'bool'],
'SolrDisMaxQuery::setGroupOffset' => ['SolrQuery', 'value'=>'int'],
'SolrDisMaxQuery::setGroupTruncate' => ['SolrQuery', 'value'=>'bool'],
'SolrDisMaxQuery::setHighlight' => ['SolrQuery', 'flag'=>'bool'],
'SolrDisMaxQuery::setHighlightAlternateField' => ['SolrQuery', 'field'=>'string', 'field_override'=>'string'],
'SolrDisMaxQuery::setHighlightFormatter' => ['SolrQuery', 'formatter'=>'string', 'field_override'=>'string'],
'SolrDisMaxQuery::setHighlightFragmenter' => ['SolrQuery', 'fragmenter'=>'string', 'field_override'=>'string'],
'SolrDisMaxQuery::setHighlightFragsize' => ['SolrQuery', 'size'=>'int', 'field_override'=>'string'],
'SolrDisMaxQuery::setHighlightHighlightMultiTerm' => ['SolrQuery', 'flag'=>'bool'],
'SolrDisMaxQuery::setHighlightMaxAlternateFieldLength' => ['SolrQuery', 'fieldLength'=>'string', 'field_override'=>'string'],
'SolrDisMaxQuery::setHighlightMaxAnalyzedChars' => ['SolrQuery', 'value'=>'int'],
'SolrDisMaxQuery::setHighlightMergeContiguous' => ['SolrQuery', 'flag'=>'bool', 'field_override'=>'string'],
'SolrDisMaxQuery::setHighlightRegexMaxAnalyzedChars' => ['SolrQuery', 'maxAnalyzedChars'=>'int'],
'SolrDisMaxQuery::setHighlightRegexPattern' => ['SolrQuery', 'value'=>'string'],
'SolrDisMaxQuery::setHighlightRegexSlop' => ['SolrQuery', 'factor'=>'float'],
'SolrDisMaxQuery::setHighlightRequireFieldMatch' => ['SolrQuery', 'flag'=>'bool'],
'SolrDisMaxQuery::setHighlightSimplePost' => ['SolrQuery', 'simplePost'=>'string', 'field_override'=>'string'],
'SolrDisMaxQuery::setHighlightSimplePre' => ['SolrQuery', 'simplePre'=>'string', 'field_override'=>'string'],
'SolrDisMaxQuery::setHighlightSnippets' => ['SolrQuery', 'value'=>'int', 'field_override'=>'string'],
'SolrDisMaxQuery::setHighlightUsePhraseHighlighter' => ['SolrQuery', 'flag'=>'bool'],
'SolrDisMaxQuery::setMinimumMatch' => ['SolrDisMaxQuery', 'value'=>'string'],
'SolrDisMaxQuery::setMlt' => ['SolrQuery', 'flag'=>'bool'],
'SolrDisMaxQuery::setMltBoost' => ['SolrQuery', 'flag'=>'bool'],
'SolrDisMaxQuery::setMltCount' => ['SolrQuery', 'count'=>'int'],
'SolrDisMaxQuery::setMltMaxNumQueryTerms' => ['SolrQuery', 'value'=>'int'],
'SolrDisMaxQuery::setMltMaxNumTokens' => ['SolrQuery', 'value'=>'int'],
'SolrDisMaxQuery::setMltMaxWordLength' => ['SolrQuery', 'maxWordLength'=>'int'],
'SolrDisMaxQuery::setMltMinDocFrequency' => ['SolrQuery', 'minDocFrequency'=>'int'],
'SolrDisMaxQuery::setMltMinTermFrequency' => ['SolrQuery', 'minTermFrequency'=>'int'],
'SolrDisMaxQuery::setMltMinWordLength' => ['SolrQuery', 'minWordLength'=>'int'],
'SolrDisMaxQuery::setOmitHeader' => ['SolrQuery', 'flag'=>'bool'],
'SolrDisMaxQuery::setParam' => ['SolrParams', 'name'=>'string', 'value'=>''],
'SolrDisMaxQuery::setPhraseFields' => ['SolrDisMaxQuery', 'fields'=>'string'],
'SolrDisMaxQuery::setPhraseSlop' => ['SolrDisMaxQuery', 'slop'=>'string'],
'SolrDisMaxQuery::setQuery' => ['SolrQuery', 'query'=>'string'],
'SolrDisMaxQuery::setQueryAlt' => ['SolrDisMaxQuery', 'q'=>'string'],
'SolrDisMaxQuery::setQueryPhraseSlop' => ['SolrDisMaxQuery', 'slop'=>'string'],
'SolrDisMaxQuery::setRows' => ['SolrQuery', 'rows'=>'int'],
'SolrDisMaxQuery::setShowDebugInfo' => ['SolrQuery', 'flag'=>'bool'],
'SolrDisMaxQuery::setStart' => ['SolrQuery', 'start'=>'int'],
'SolrDisMaxQuery::setStats' => ['SolrQuery', 'flag'=>'bool'],
'SolrDisMaxQuery::setTerms' => ['SolrQuery', 'flag'=>'bool'],
'SolrDisMaxQuery::setTermsField' => ['SolrQuery', 'fieldname'=>'string'],
'SolrDisMaxQuery::setTermsIncludeLowerBound' => ['SolrQuery', 'flag'=>'bool'],
'SolrDisMaxQuery::setTermsIncludeUpperBound' => ['SolrQuery', 'flag'=>'bool'],
'SolrDisMaxQuery::setTermsLimit' => ['SolrQuery', 'limit'=>'int'],
'SolrDisMaxQuery::setTermsLowerBound' => ['SolrQuery', 'lowerBound'=>'string'],
'SolrDisMaxQuery::setTermsMaxCount' => ['SolrQuery', 'frequency'=>'int'],
'SolrDisMaxQuery::setTermsMinCount' => ['SolrQuery', 'frequency'=>'int'],
'SolrDisMaxQuery::setTermsPrefix' => ['SolrQuery', 'prefix'=>'string'],
'SolrDisMaxQuery::setTermsReturnRaw' => ['SolrQuery', 'flag'=>'bool'],
'SolrDisMaxQuery::setTermsSort' => ['SolrQuery', 'sortType'=>'int'],
'SolrDisMaxQuery::setTermsUpperBound' => ['SolrQuery', 'upperBound'=>'string'],
'SolrDisMaxQuery::setTieBreaker' => ['SolrDisMaxQuery', 'tieBreaker'=>'string'],
'SolrDisMaxQuery::setTimeAllowed' => ['SolrQuery', 'timeAllowed'=>'int'],
'SolrDisMaxQuery::setTrigramPhraseFields' => ['SolrDisMaxQuery', 'fields'=>'string'],
'SolrDisMaxQuery::setTrigramPhraseSlop' => ['SolrDisMaxQuery', 'slop'=>'string'],
'SolrDisMaxQuery::setUserFields' => ['SolrDisMaxQuery', 'fields'=>'string'],
'SolrDisMaxQuery::toString' => ['string', 'url_encode='=>'bool|false'],
'SolrDisMaxQuery::unserialize' => ['void', 'serialized'=>'string'],
'SolrDisMaxQuery::useDisMaxQueryParser' => ['SolrDisMaxQuery'],
'SolrDisMaxQuery::useEDisMaxQueryParser' => ['SolrDisMaxQuery'],
'SolrDocument::__clone' => ['void'],
'SolrDocument::__construct' => ['void'],
'SolrDocument::__destruct' => [''],
'SolrDocument::__get' => ['SolrDocumentField', 'fieldname'=>'string'],
'SolrDocument::__isset' => ['bool', 'fieldname'=>'string'],
'SolrDocument::__set' => ['bool', 'fieldname'=>'string', 'fieldvalue'=>'string'],
'SolrDocument::__unset' => ['bool', 'fieldname'=>'string'],
'SolrDocument::addField' => ['bool', 'fieldname'=>'string', 'fieldvalue'=>'string'],
'SolrDocument::clear' => ['bool'],
'SolrDocument::current' => ['SolrDocumentField'],
'SolrDocument::deleteField' => ['bool', 'fieldname'=>'string'],
'SolrDocument::fieldExists' => ['bool', 'fieldname'=>'string'],
'SolrDocument::getChildDocuments' => ['array'],
'SolrDocument::getChildDocumentsCount' => ['int'],
'SolrDocument::getField' => ['SolrDocumentField', 'fieldname'=>'string'],
'SolrDocument::getFieldCount' => ['int'],
'SolrDocument::getFieldNames' => ['array'],
'SolrDocument::getInputDocument' => ['SolrInputDocument'],
'SolrDocument::hasChildDocuments' => ['bool'],
'SolrDocument::key' => ['string'],
'SolrDocument::merge' => ['bool', 'sourcedoc'=>'solrdocument', 'overwrite='=>'bool'],
'SolrDocument::next' => ['void'],
'SolrDocument::offsetExists' => ['bool', 'fieldname'=>'string'],
'SolrDocument::offsetGet' => ['SolrDocumentField', 'fieldname'=>'string'],
'SolrDocument::offsetSet' => ['void', 'fieldname'=>'string', 'fieldvalue'=>'string'],
'SolrDocument::offsetUnset' => ['void', 'fieldname'=>'string'],
'SolrDocument::reset' => ['bool'],
'SolrDocument::rewind' => ['void'],
'SolrDocument::serialize' => ['string'],
'SolrDocument::sort' => ['bool', 'sortorderby'=>'int', 'sortdirection='=>'int'],
'SolrDocument::toArray' => ['array'],
'SolrDocument::unserialize' => ['void', 'serialized'=>'string'],
'SolrDocument::valid' => ['bool'],
'SolrDocumentField::__construct' => ['void'],
'SolrDocumentField::__destruct' => [''],
'SolrException::__clone' => ['void'],
'SolrException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?\Exception|?\Throwable'],
'SolrException::__toString' => ['string'],
'SolrException::__wakeup' => ['void'],
'SolrException::getCode' => ['int'],
'SolrException::getFile' => ['string'],
'SolrException::getInternalInfo' => ['array'],
'SolrException::getLine' => ['int'],
'SolrException::getMessage' => ['string'],
'SolrException::getPrevious' => ['Exception|Throwable'],
'SolrException::getTrace' => ['array'],
'SolrException::getTraceAsString' => ['string'],
'SolrGenericResponse::__construct' => ['void'],
'SolrGenericResponse::__destruct' => [''],
'SolrGenericResponse::getDigestedResponse' => ['string'],
'SolrGenericResponse::getHttpStatus' => ['int'],
'SolrGenericResponse::getHttpStatusMessage' => ['string'],
'SolrGenericResponse::getRawRequest' => ['string'],
'SolrGenericResponse::getRawRequestHeaders' => ['string'],
'SolrGenericResponse::getRawResponse' => ['string'],
'SolrGenericResponse::getRawResponseHeaders' => ['string'],
'SolrGenericResponse::getRequestUrl' => ['string'],
'SolrGenericResponse::getResponse' => ['SolrObject'],
'SolrGenericResponse::setParseMode' => ['bool', 'parser_mode='=>'int'],
'SolrGenericResponse::success' => ['bool'],
'SolrIllegalArgumentException::__clone' => ['void'],
'SolrIllegalArgumentException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?\Exception|?\Throwable'],
'SolrIllegalArgumentException::__toString' => ['string'],
'SolrIllegalArgumentException::__wakeup' => ['void'],
'SolrIllegalArgumentException::getCode' => ['int'],
'SolrIllegalArgumentException::getFile' => ['string'],
'SolrIllegalArgumentException::getInternalInfo' => ['array'],
'SolrIllegalArgumentException::getLine' => ['int'],
'SolrIllegalArgumentException::getMessage' => ['string'],
'SolrIllegalArgumentException::getPrevious' => ['Exception|Throwable'],
'SolrIllegalArgumentException::getTrace' => ['array'],
'SolrIllegalArgumentException::getTraceAsString' => ['string'],
'SolrIllegalOperationException::__clone' => ['void'],
'SolrIllegalOperationException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?\Exception|?\Throwable'],
'SolrIllegalOperationException::__toString' => ['string'],
'SolrIllegalOperationException::__wakeup' => ['void'],
'SolrIllegalOperationException::getCode' => ['int'],
'SolrIllegalOperationException::getFile' => ['string'],
'SolrIllegalOperationException::getInternalInfo' => ['array'],
'SolrIllegalOperationException::getLine' => ['int'],
'SolrIllegalOperationException::getMessage' => ['string'],
'SolrIllegalOperationException::getPrevious' => ['Exception|Throwable'],
'SolrIllegalOperationException::getTrace' => ['array'],
'SolrIllegalOperationException::getTraceAsString' => ['string'],
'SolrInputDocument::__clone' => ['void'],
'SolrInputDocument::__construct' => ['void'],
'SolrInputDocument::__destruct' => [''],
'SolrInputDocument::addChildDocument' => ['void', 'child'=>'SolrInputDocument'],
'SolrInputDocument::addChildDocuments' => ['void', 'docs'=>'array'],
'SolrInputDocument::addField' => ['bool', 'fieldname'=>'string', 'fieldvalue'=>'string', 'fieldboostvalue='=>'float'],
'SolrInputDocument::clear' => ['bool'],
'SolrInputDocument::deleteField' => ['bool', 'fieldname'=>'string'],
'SolrInputDocument::fieldExists' => ['bool', 'fieldname'=>'string'],
'SolrInputDocument::getBoost' => ['float'],
'SolrInputDocument::getChildDocuments' => ['array'],
'SolrInputDocument::getChildDocumentsCount' => ['int'],
'SolrInputDocument::getField' => ['SolrDocumentField', 'fieldname'=>'string'],
'SolrInputDocument::getFieldBoost' => ['float', 'fieldname'=>'string'],
'SolrInputDocument::getFieldCount' => ['int'],
'SolrInputDocument::getFieldNames' => ['array'],
'SolrInputDocument::hasChildDocuments' => ['bool'],
'SolrInputDocument::merge' => ['bool', 'sourcedoc'=>'solrinputdocument', 'overwrite='=>'bool'],
'SolrInputDocument::reset' => ['bool'],
'SolrInputDocument::setBoost' => ['bool', 'documentboostvalue'=>'float'],
'SolrInputDocument::setFieldBoost' => ['bool', 'fieldname'=>'string', 'fieldboostvalue'=>'float'],
'SolrInputDocument::sort' => ['bool', 'sortorderby'=>'int', 'sortdirection='=>'int'],
'SolrInputDocument::toArray' => ['array'],
'SolrModifiableParams::__construct' => ['void'],
'SolrModifiableParams::__destruct' => [''],
'SolrModifiableParams::add' => ['SolrParams', 'name'=>'string', 'value'=>'string'],
'SolrModifiableParams::addParam' => ['SolrParams', 'name'=>'string', 'value'=>'string'],
'SolrModifiableParams::get' => ['mixed', 'param_name'=>'string'],
'SolrModifiableParams::getParam' => ['mixed', 'param_name'=>'string'],
'SolrModifiableParams::getParams' => ['array'],
'SolrModifiableParams::getPreparedParams' => ['array'],
'SolrModifiableParams::serialize' => ['string'],
'SolrModifiableParams::set' => ['SolrParams', 'name'=>'string', 'value'=>''],
'SolrModifiableParams::setParam' => ['SolrParams', 'name'=>'string', 'value'=>''],
'SolrModifiableParams::toString' => ['string', 'url_encode='=>'bool|false'],
'SolrModifiableParams::unserialize' => ['void', 'serialized'=>'string'],
'SolrObject::__construct' => ['void'],
'SolrObject::__destruct' => [''],
'SolrObject::getPropertyNames' => ['array'],
'SolrObject::offsetExists' => ['bool', 'property_name'=>'string'],
'SolrObject::offsetGet' => ['mixed', 'property_name'=>'string'],
'SolrObject::offsetSet' => ['void', 'property_name'=>'string', 'property_value'=>'string'],
'SolrObject::offsetUnset' => ['void', 'property_name'=>'string'],
'SolrParams::__construct' => ['void'],
'SolrParams::add' => ['SolrParams', 'name'=>'string', 'value'=>'string'],
'SolrParams::addParam' => ['SolrParams', 'name'=>'string', 'value'=>'string'],
'SolrParams::get' => ['mixed', 'param_name'=>'string'],
'SolrParams::getParam' => ['mixed', 'param_name='=>'string'],
'SolrParams::getParams' => ['array'],
'SolrParams::getPreparedParams' => ['array'],
'SolrParams::serialize' => ['string'],
'SolrParams::set' => ['void', 'name'=>'string', 'value'=>'string'],
'SolrParams::setParam' => ['SolrParams', 'name'=>'string', 'value'=>'string'],
'SolrParams::toString' => ['string', 'url_encode='=>'bool'],
'SolrParams::unserialize' => ['void', 'serialized'=>'string'],
'SolrPingResponse::__construct' => ['void'],
'SolrPingResponse::__destruct' => [''],
'SolrPingResponse::getDigestedResponse' => ['string'],
'SolrPingResponse::getHttpStatus' => ['int'],
'SolrPingResponse::getHttpStatusMessage' => ['string'],
'SolrPingResponse::getRawRequest' => ['string'],
'SolrPingResponse::getRawRequestHeaders' => ['string'],
'SolrPingResponse::getRawResponse' => ['string'],
'SolrPingResponse::getRawResponseHeaders' => ['string'],
'SolrPingResponse::getRequestUrl' => ['string'],
'SolrPingResponse::getResponse' => ['string'],
'SolrPingResponse::setParseMode' => ['bool', 'parser_mode='=>'int'],
'SolrPingResponse::success' => ['bool'],
'SolrQuery::__construct' => ['void', 'q='=>'string'],
'SolrQuery::__destruct' => [''],
'SolrQuery::add' => ['SolrParams', 'name'=>'string', 'value'=>'string'],
'SolrQuery::addExpandFilterQuery' => ['SolrQuery', 'fq'=>'string'],
'SolrQuery::addExpandSortField' => ['SolrQuery', 'field'=>'string', 'order='=>'string'],
'SolrQuery::addFacetDateField' => ['SolrQuery', 'datefield'=>'string'],
'SolrQuery::addFacetDateOther' => ['SolrQuery', 'value'=>'string', 'field_override='=>'string'],
'SolrQuery::addFacetField' => ['SolrQuery', 'field'=>'string'],
'SolrQuery::addFacetQuery' => ['SolrQuery', 'facetquery'=>'string'],
'SolrQuery::addField' => ['SolrQuery', 'field'=>'string'],
'SolrQuery::addFilterQuery' => ['SolrQuery', 'fq'=>'string'],
'SolrQuery::addGroupField' => ['SolrQuery', 'value'=>'string'],
'SolrQuery::addGroupFunction' => ['SolrQuery', 'value'=>'string'],
'SolrQuery::addGroupQuery' => ['SolrQuery', 'value'=>'string'],
'SolrQuery::addGroupSortField' => ['SolrQuery', 'field'=>'string', 'order='=>'int'],
'SolrQuery::addHighlightField' => ['SolrQuery', 'field'=>'string'],
'SolrQuery::addMltField' => ['SolrQuery', 'field'=>'string'],
'SolrQuery::addMltQueryField' => ['SolrQuery', 'field'=>'string', 'boost'=>'float'],
'SolrQuery::addParam' => ['SolrParams', 'name'=>'string', 'value'=>'string'],
'SolrQuery::addSortField' => ['SolrQuery', 'field'=>'string', 'order='=>'int'],
'SolrQuery::addStatsFacet' => ['SolrQuery', 'field'=>'string'],
'SolrQuery::addStatsField' => ['SolrQuery', 'field'=>'string'],
'SolrQuery::collapse' => ['SolrQuery', 'collapseFunction'=>'SolrCollapseFunction'],
'SolrQuery::get' => ['mixed', 'param_name'=>'string'],
'SolrQuery::getExpand' => ['bool'],
'SolrQuery::getExpandFilterQueries' => ['array'],
'SolrQuery::getExpandQuery' => ['array'],
'SolrQuery::getExpandRows' => ['int'],
'SolrQuery::getExpandSortFields' => ['array'],
'SolrQuery::getFacet' => ['bool'],
'SolrQuery::getFacetDateEnd' => ['string', 'field_override='=>'string'],
'SolrQuery::getFacetDateFields' => ['array'],
'SolrQuery::getFacetDateGap' => ['string', 'field_override='=>'string'],
'SolrQuery::getFacetDateHardEnd' => ['string', 'field_override='=>'string'],
'SolrQuery::getFacetDateOther' => ['array', 'field_override='=>'string'],
'SolrQuery::getFacetDateStart' => ['string', 'field_override='=>'string'],
'SolrQuery::getFacetFields' => ['array'],
'SolrQuery::getFacetLimit' => ['int', 'field_override='=>'string'],
'SolrQuery::getFacetMethod' => ['string', 'field_override='=>'string'],
'SolrQuery::getFacetMinCount' => ['int', 'field_override='=>'string'],
'SolrQuery::getFacetMissing' => ['bool', 'field_override='=>'string'],
'SolrQuery::getFacetOffset' => ['int', 'field_override='=>'string'],
'SolrQuery::getFacetPrefix' => ['string', 'field_override='=>'string'],
'SolrQuery::getFacetQueries' => ['array'],
'SolrQuery::getFacetSort' => ['int', 'field_override='=>'string'],
'SolrQuery::getFields' => ['array'],
'SolrQuery::getFilterQueries' => ['array'],
'SolrQuery::getGroup' => ['bool'],
'SolrQuery::getGroupCachePercent' => ['int'],
'SolrQuery::getGroupFacet' => ['bool'],
'SolrQuery::getGroupFields' => ['array'],
'SolrQuery::getGroupFormat' => ['string'],
'SolrQuery::getGroupFunctions' => ['array'],
'SolrQuery::getGroupLimit' => ['int'],
'SolrQuery::getGroupMain' => ['bool'],
'SolrQuery::getGroupNGroups' => ['bool'],
'SolrQuery::getGroupOffset' => ['int'],
'SolrQuery::getGroupQueries' => ['array'],
'SolrQuery::getGroupSortFields' => ['array'],
'SolrQuery::getGroupTruncate' => ['bool'],
'SolrQuery::getHighlight' => ['bool'],
'SolrQuery::getHighlightAlternateField' => ['string', 'field_override='=>'string'],
'SolrQuery::getHighlightFields' => ['array'],
'SolrQuery::getHighlightFormatter' => ['string', 'field_override='=>'string'],
'SolrQuery::getHighlightFragmenter' => ['string', 'field_override='=>'string'],
'SolrQuery::getHighlightFragsize' => ['int', 'field_override='=>'string'],
'SolrQuery::getHighlightHighlightMultiTerm' => ['bool'],
'SolrQuery::getHighlightMaxAlternateFieldLength' => ['int', 'field_override='=>'string'],
'SolrQuery::getHighlightMaxAnalyzedChars' => ['int'],
'SolrQuery::getHighlightMergeContiguous' => ['bool', 'field_override='=>'string'],
'SolrQuery::getHighlightRegexMaxAnalyzedChars' => ['int'],
'SolrQuery::getHighlightRegexPattern' => ['string'],
'SolrQuery::getHighlightRegexSlop' => ['float'],
'SolrQuery::getHighlightRequireFieldMatch' => ['bool'],
'SolrQuery::getHighlightSimplePost' => ['string', 'field_override='=>'string'],
'SolrQuery::getHighlightSimplePre' => ['string', 'field_override='=>'string'],
'SolrQuery::getHighlightSnippets' => ['int', 'field_override='=>'string'],
'SolrQuery::getHighlightUsePhraseHighlighter' => ['bool'],
'SolrQuery::getMlt' => ['bool'],
'SolrQuery::getMltBoost' => ['bool'],
'SolrQuery::getMltCount' => ['int'],
'SolrQuery::getMltFields' => ['array'],
'SolrQuery::getMltMaxNumQueryTerms' => ['int'],
'SolrQuery::getMltMaxNumTokens' => ['int'],
'SolrQuery::getMltMaxWordLength' => ['int'],
'SolrQuery::getMltMinDocFrequency' => ['int'],
'SolrQuery::getMltMinTermFrequency' => ['int'],
'SolrQuery::getMltMinWordLength' => ['int'],
'SolrQuery::getMltQueryFields' => ['array'],
'SolrQuery::getParam' => ['mixed', 'param_name'=>'string'],
'SolrQuery::getParams' => ['array'],
'SolrQuery::getPreparedParams' => ['array'],
'SolrQuery::getQuery' => ['string'],
'SolrQuery::getRows' => ['int'],
'SolrQuery::getSortFields' => ['array'],
'SolrQuery::getStart' => ['int'],
'SolrQuery::getStats' => ['bool'],
'SolrQuery::getStatsFacets' => ['array'],
'SolrQuery::getStatsFields' => ['array'],
'SolrQuery::getTerms' => ['bool'],
'SolrQuery::getTermsField' => ['string'],
'SolrQuery::getTermsIncludeLowerBound' => ['bool'],
'SolrQuery::getTermsIncludeUpperBound' => ['bool'],
'SolrQuery::getTermsLimit' => ['int'],
'SolrQuery::getTermsLowerBound' => ['string'],
'SolrQuery::getTermsMaxCount' => ['int'],
'SolrQuery::getTermsMinCount' => ['int'],
'SolrQuery::getTermsPrefix' => ['string'],
'SolrQuery::getTermsReturnRaw' => ['bool'],
'SolrQuery::getTermsSort' => ['int'],
'SolrQuery::getTermsUpperBound' => ['string'],
'SolrQuery::getTimeAllowed' => ['int'],
'SolrQuery::removeExpandFilterQuery' => ['SolrQuery', 'fq'=>'string'],
'SolrQuery::removeExpandSortField' => ['SolrQuery', 'field'=>'string'],
'SolrQuery::removeFacetDateField' => ['SolrQuery', 'field'=>'string'],
'SolrQuery::removeFacetDateOther' => ['SolrQuery', 'value'=>'string', 'field_override='=>'string'],
'SolrQuery::removeFacetField' => ['SolrQuery', 'field'=>'string'],
'SolrQuery::removeFacetQuery' => ['SolrQuery', 'value'=>'string'],
'SolrQuery::removeField' => ['SolrQuery', 'field'=>'string'],
'SolrQuery::removeFilterQuery' => ['SolrQuery', 'fq'=>'string'],
'SolrQuery::removeHighlightField' => ['SolrQuery', 'field'=>'string'],
'SolrQuery::removeMltField' => ['SolrQuery', 'field'=>'string'],
'SolrQuery::removeMltQueryField' => ['SolrQuery', 'queryfield'=>'string'],
'SolrQuery::removeSortField' => ['SolrQuery', 'field'=>'string'],
'SolrQuery::removeStatsFacet' => ['SolrQuery', 'value'=>'string'],
'SolrQuery::removeStatsField' => ['SolrQuery', 'field'=>'string'],
'SolrQuery::serialize' => ['string'],
'SolrQuery::set' => ['SolrParams', 'name'=>'string', 'value'=>''],
'SolrQuery::setEchoHandler' => ['SolrQuery', 'flag'=>'bool'],
'SolrQuery::setEchoParams' => ['SolrQuery', 'type'=>'string'],
'SolrQuery::setExpand' => ['SolrQuery', 'value'=>'bool'],
'SolrQuery::setExpandQuery' => ['SolrQuery', 'q'=>'string'],
'SolrQuery::setExpandRows' => ['SolrQuery', 'value'=>'int'],
'SolrQuery::setExplainOther' => ['SolrQuery', 'query'=>'string'],
'SolrQuery::setFacet' => ['SolrQuery', 'flag'=>'bool'],
'SolrQuery::setFacetDateEnd' => ['SolrQuery', 'value'=>'string', 'field_override='=>'string'],
'SolrQuery::setFacetDateGap' => ['SolrQuery', 'value'=>'string', 'field_override='=>'string'],
'SolrQuery::setFacetDateHardEnd' => ['SolrQuery', 'value'=>'bool', 'field_override='=>'string'],
'SolrQuery::setFacetDateStart' => ['SolrQuery', 'value'=>'string', 'field_override='=>'string'],
'SolrQuery::setFacetEnumCacheMinDefaultFrequency' => ['SolrQuery', 'frequency'=>'int', 'field_override='=>'string'],
'SolrQuery::setFacetLimit' => ['SolrQuery', 'limit'=>'int', 'field_override='=>'string'],
'SolrQuery::setFacetMethod' => ['SolrQuery', 'method'=>'string', 'field_override='=>'string'],
'SolrQuery::setFacetMinCount' => ['SolrQuery', 'mincount'=>'int', 'field_override='=>'string'],
'SolrQuery::setFacetMissing' => ['SolrQuery', 'flag'=>'bool', 'field_override='=>'string'],
'SolrQuery::setFacetOffset' => ['SolrQuery', 'offset'=>'int', 'field_override='=>'string'],
'SolrQuery::setFacetPrefix' => ['SolrQuery', 'prefix'=>'string', 'field_override='=>'string'],
'SolrQuery::setFacetSort' => ['SolrQuery', 'facetsort'=>'int', 'field_override='=>'string'],
'SolrQuery::setGroup' => ['SolrQuery', 'value'=>'bool'],
'SolrQuery::setGroupCachePercent' => ['SolrQuery', 'percent'=>'int'],
'SolrQuery::setGroupFacet' => ['SolrQuery', 'value'=>'bool'],
'SolrQuery::setGroupFormat' => ['SolrQuery', 'value'=>'string'],
'SolrQuery::setGroupLimit' => ['SolrQuery', 'value'=>'int'],
'SolrQuery::setGroupMain' => ['SolrQuery', 'value'=>'string'],
'SolrQuery::setGroupNGroups' => ['SolrQuery', 'value'=>'bool'],
'SolrQuery::setGroupOffset' => ['SolrQuery', 'value'=>'int'],
'SolrQuery::setGroupTruncate' => ['SolrQuery', 'value'=>'bool'],
'SolrQuery::setHighlight' => ['SolrQuery', 'flag'=>'bool'],
'SolrQuery::setHighlightAlternateField' => ['SolrQuery', 'field'=>'string', 'field_override='=>'string'],
'SolrQuery::setHighlightFormatter' => ['SolrQuery', 'formatter'=>'string', 'field_override='=>'string'],
'SolrQuery::setHighlightFragmenter' => ['SolrQuery', 'fragmenter'=>'string', 'field_override='=>'string'],
'SolrQuery::setHighlightFragsize' => ['SolrQuery', 'size'=>'int', 'field_override='=>'string'],
'SolrQuery::setHighlightHighlightMultiTerm' => ['SolrQuery', 'flag'=>'bool'],
'SolrQuery::setHighlightMaxAlternateFieldLength' => ['SolrQuery', 'fieldlength'=>'int', 'field_override='=>'string'],
'SolrQuery::setHighlightMaxAnalyzedChars' => ['SolrQuery', 'value'=>'int'],
'SolrQuery::setHighlightMergeContiguous' => ['SolrQuery', 'flag'=>'bool', 'field_override='=>'string'],
'SolrQuery::setHighlightRegexMaxAnalyzedChars' => ['SolrQuery', 'maxanalyzedchars'=>'int'],
'SolrQuery::setHighlightRegexPattern' => ['SolrQuery', 'value'=>'string'],
'SolrQuery::setHighlightRegexSlop' => ['SolrQuery', 'factor'=>'float'],
'SolrQuery::setHighlightRequireFieldMatch' => ['SolrQuery', 'flag'=>'bool'],
'SolrQuery::setHighlightSimplePost' => ['SolrQuery', 'simplepost'=>'string', 'field_override='=>'string'],
'SolrQuery::setHighlightSimplePre' => ['SolrQuery', 'simplepre'=>'string', 'field_override='=>'string'],
'SolrQuery::setHighlightSnippets' => ['SolrQuery', 'value'=>'int', 'field_override='=>'string'],
'SolrQuery::setHighlightUsePhraseHighlighter' => ['SolrQuery', 'flag'=>'bool'],
'SolrQuery::setMlt' => ['SolrQuery', 'flag'=>'bool'],
'SolrQuery::setMltBoost' => ['SolrQuery', 'flag'=>'bool'],
'SolrQuery::setMltCount' => ['SolrQuery', 'count'=>'int'],
'SolrQuery::setMltMaxNumQueryTerms' => ['SolrQuery', 'value'=>'int'],
'SolrQuery::setMltMaxNumTokens' => ['SolrQuery', 'value'=>'int'],
'SolrQuery::setMltMaxWordLength' => ['SolrQuery', 'maxwordlength'=>'int'],
'SolrQuery::setMltMinDocFrequency' => ['SolrQuery', 'mindocfrequency'=>'int'],
'SolrQuery::setMltMinTermFrequency' => ['SolrQuery', 'mintermfrequency'=>'int'],
'SolrQuery::setMltMinWordLength' => ['SolrQuery', 'minwordlength'=>'int'],
'SolrQuery::setOmitHeader' => ['SolrQuery', 'flag'=>'bool'],
'SolrQuery::setParam' => ['SolrParams', 'name'=>'string', 'value'=>''],
'SolrQuery::setQuery' => ['SolrQuery', 'query'=>'string'],
'SolrQuery::setRows' => ['SolrQuery', 'rows'=>'int'],
'SolrQuery::setShowDebugInfo' => ['SolrQuery', 'flag'=>'bool'],
'SolrQuery::setStart' => ['SolrQuery', 'start'=>'int'],
'SolrQuery::setStats' => ['SolrQuery', 'flag'=>'bool'],
'SolrQuery::setTerms' => ['SolrQuery', 'flag'=>'bool'],
'SolrQuery::setTermsField' => ['SolrQuery', 'fieldname'=>'string'],
'SolrQuery::setTermsIncludeLowerBound' => ['SolrQuery', 'flag'=>'bool'],
'SolrQuery::setTermsIncludeUpperBound' => ['SolrQuery', 'flag'=>'bool'],
'SolrQuery::setTermsLimit' => ['SolrQuery', 'limit'=>'int'],
'SolrQuery::setTermsLowerBound' => ['SolrQuery', 'lowerbound'=>'string'],
'SolrQuery::setTermsMaxCount' => ['SolrQuery', 'frequency'=>'int'],
'SolrQuery::setTermsMinCount' => ['SolrQuery', 'frequency'=>'int'],
'SolrQuery::setTermsPrefix' => ['SolrQuery', 'prefix'=>'string'],
'SolrQuery::setTermsReturnRaw' => ['SolrQuery', 'flag'=>'bool'],
'SolrQuery::setTermsSort' => ['SolrQuery', 'sorttype'=>'int'],
'SolrQuery::setTermsUpperBound' => ['SolrQuery', 'upperbound'=>'string'],
'SolrQuery::setTimeAllowed' => ['SolrQuery', 'timeallowed'=>'int'],
'SolrQuery::toString' => ['string', 'url_encode='=>'bool|false'],
'SolrQuery::unserialize' => ['void', 'serialized'=>'string'],
'SolrQueryResponse::__construct' => ['void'],
'SolrQueryResponse::__destruct' => [''],
'SolrQueryResponse::getDigestedResponse' => ['string'],
'SolrQueryResponse::getHttpStatus' => ['int'],
'SolrQueryResponse::getHttpStatusMessage' => ['string'],
'SolrQueryResponse::getRawRequest' => ['string'],
'SolrQueryResponse::getRawRequestHeaders' => ['string'],
'SolrQueryResponse::getRawResponse' => ['string'],
'SolrQueryResponse::getRawResponseHeaders' => ['string'],
'SolrQueryResponse::getRequestUrl' => ['string'],
'SolrQueryResponse::getResponse' => ['SolrObject'],
'SolrQueryResponse::setParseMode' => ['bool', 'parser_mode='=>'int'],
'SolrQueryResponse::success' => ['bool'],
'SolrResponse::getDigestedResponse' => ['string'],
'SolrResponse::getHttpStatus' => ['int'],
'SolrResponse::getHttpStatusMessage' => ['string'],
'SolrResponse::getRawRequest' => ['string'],
'SolrResponse::getRawRequestHeaders' => ['string'],
'SolrResponse::getRawResponse' => ['string'],
'SolrResponse::getRawResponseHeaders' => ['string'],
'SolrResponse::getRequestUrl' => ['string'],
'SolrResponse::getResponse' => ['SolrObject'],
'SolrResponse::setParseMode' => ['bool', 'parser_mode='=>'int'],
'SolrResponse::success' => ['bool'],
'SolrServerException::__clone' => ['void'],
'SolrServerException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?\Exception|?\Throwable'],
'SolrServerException::__toString' => ['string'],
'SolrServerException::__wakeup' => ['void'],
'SolrServerException::getCode' => ['int'],
'SolrServerException::getFile' => ['string'],
'SolrServerException::getInternalInfo' => ['array'],
'SolrServerException::getLine' => ['int'],
'SolrServerException::getMessage' => ['string'],
'SolrServerException::getPrevious' => ['Exception|Throwable'],
'SolrServerException::getTrace' => ['array'],
'SolrServerException::getTraceAsString' => ['string'],
'SolrUpdateResponse::__construct' => ['void'],
'SolrUpdateResponse::__destruct' => [''],
'SolrUpdateResponse::getDigestedResponse' => ['string'],
'SolrUpdateResponse::getHttpStatus' => ['int'],
'SolrUpdateResponse::getHttpStatusMessage' => ['string'],
'SolrUpdateResponse::getRawRequest' => ['string'],
'SolrUpdateResponse::getRawRequestHeaders' => ['string'],
'SolrUpdateResponse::getRawResponse' => ['string'],
'SolrUpdateResponse::getRawResponseHeaders' => ['string'],
'SolrUpdateResponse::getRequestUrl' => ['string'],
'SolrUpdateResponse::getResponse' => ['SolrObject'],
'SolrUpdateResponse::setParseMode' => ['bool', 'parser_mode='=>'int'],
'SolrUpdateResponse::success' => ['bool'],
'SolrUtils::digestXmlResponse' => ['SolrObject', 'xmlresponse'=>'string', 'parse_mode='=>'int'],
'SolrUtils::escapeQueryChars' => ['string', 'str'=>'string'],
'SolrUtils::getSolrVersion' => ['string'],
'SolrUtils::queryPhrase' => ['string', 'str'=>'string'],
'sort' => ['bool', '&rw_array_arg'=>'array', 'sort_flags='=>'int'],
'soundex' => ['string', 'str'=>'string'],
'SphinxClient::__construct' => ['void'],
'SphinxClient::addQuery' => ['int', 'query'=>'string', 'index='=>'string', 'comment='=>'string'],
'SphinxClient::buildExcerpts' => ['array', 'docs'=>'array', 'index'=>'string', 'words'=>'string', 'opts='=>'array'],
'SphinxClient::buildKeywords' => ['array', 'query'=>'string', 'index'=>'string', 'hits'=>'bool'],
'SphinxClient::close' => ['bool'],
'SphinxClient::escapeString' => ['string', 'string'=>'string'],
'SphinxClient::getLastError' => ['string'],
'SphinxClient::getLastWarning' => ['string'],
'SphinxClient::open' => ['bool'],
'SphinxClient::query' => ['array', 'query'=>'string', 'index='=>'string', 'comment='=>'string'],
'SphinxClient::resetFilters' => ['void'],
'SphinxClient::resetGroupBy' => ['void'],
'SphinxClient::runQueries' => ['array'],
'SphinxClient::setArrayResult' => ['bool', 'array_result'=>'bool'],
'SphinxClient::setConnectTimeout' => ['bool', 'timeout'=>'float'],
'SphinxClient::setFieldWeights' => ['bool', 'weights'=>'array'],
'SphinxClient::setFilter' => ['bool', 'attribute'=>'string', 'values'=>'array', 'exclude='=>'bool'],
'SphinxClient::setFilterFloatRange' => ['bool', 'attribute'=>'string', 'min'=>'float', 'max'=>'float', 'exclude='=>'bool'],
'SphinxClient::setFilterRange' => ['bool', 'attribute'=>'string', 'min'=>'int', 'max'=>'int', 'exclude='=>'bool'],
'SphinxClient::setGeoAnchor' => ['bool', 'attrlat'=>'string', 'attrlong'=>'string', 'latitude'=>'float', 'longitude'=>'float'],
'SphinxClient::setGroupBy' => ['bool', 'attribute'=>'string', 'func'=>'int', 'groupsort='=>'string'],
'SphinxClient::setGroupDistinct' => ['bool', 'attribute'=>'string'],
'SphinxClient::setIDRange' => ['bool', 'min'=>'int', 'max'=>'int'],
'SphinxClient::setIndexWeights' => ['bool', 'weights'=>'array'],
'SphinxClient::setLimits' => ['bool', 'offset'=>'int', 'limit'=>'int', 'max_matches='=>'int', 'cutoff='=>'int'],
'SphinxClient::setMatchMode' => ['bool', 'mode'=>'int'],
'SphinxClient::setMaxQueryTime' => ['bool', 'qtime'=>'int'],
'SphinxClient::setOverride' => ['bool', 'attribute'=>'string', 'type'=>'int', 'values'=>'array'],
'SphinxClient::setRankingMode' => ['bool', 'ranker'=>'int'],
'SphinxClient::setRetries' => ['bool', 'count'=>'int', 'delay='=>'int'],
'SphinxClient::setSelect' => ['bool', 'clause'=>'string'],
'SphinxClient::setServer' => ['bool', 'server'=>'string', 'port'=>'int'],
'SphinxClient::setSortMode' => ['bool', 'mode'=>'int', 'sortby='=>'string'],
'SphinxClient::status' => ['array'],
'SphinxClient::updateAttributes' => ['int', 'index'=>'string', 'attributes'=>'array', 'values'=>'array', 'mva='=>'bool'],
'spl_autoload' => ['void', 'class_name'=>'string', 'file_extensions='=>'string'],
'spl_autoload_call' => ['void', 'class_name'=>'string'],
'spl_autoload_extensions' => ['string', 'file_extensions='=>'string'],
'spl_autoload_functions' => ['false|array'],
'spl_autoload_register' => ['bool', 'autoload_function='=>'callable', 'throw='=>'bool', 'prepend='=>'bool'],
'spl_autoload_unregister' => ['bool', 'autoload_function'=>'mixed'],
'spl_classes' => ['array'],
'spl_object_hash' => ['string', 'obj'=>'object'],
'spl_object_id' => ['int', 'obj'=>'object'],
'SplDoublyLinkedList::add' => ['void', 'index'=>'mixed', 'newval'=>'mixed'],
'SplDoublyLinkedList::bottom' => ['mixed'],
'SplDoublyLinkedList::count' => ['int'],
'SplDoublyLinkedList::current' => ['mixed'],
'SplDoublyLinkedList::getIteratorMode' => ['int'],
'SplDoublyLinkedList::isEmpty' => ['bool'],
'SplDoublyLinkedList::key' => ['mixed'],
'SplDoublyLinkedList::next' => ['void'],
'SplDoublyLinkedList::offsetExists' => ['bool', 'index'=>'mixed'],
'SplDoublyLinkedList::offsetGet' => ['mixed', 'index'=>'mixed'],
'SplDoublyLinkedList::offsetSet' => ['void', 'index'=>'mixed', 'newval'=>'mixed'],
'SplDoublyLinkedList::offsetUnset' => ['void', 'index'=>'mixed'],
'SplDoublyLinkedList::pop' => ['mixed'],
'SplDoublyLinkedList::prev' => ['void'],
'SplDoublyLinkedList::push' => ['void', 'value'=>'mixed'],
'SplDoublyLinkedList::rewind' => ['void'],
'SplDoublyLinkedList::serialize' => ['string'],
'SplDoublyLinkedList::setIteratorMode' => ['int', 'flags'=>'int'],
'SplDoublyLinkedList::shift' => ['mixed'],
'SplDoublyLinkedList::top' => ['mixed'],
'SplDoublyLinkedList::unserialize' => ['void', 'serialized'=>'string'],
'SplDoublyLinkedList::unshift' => ['bool', 'value'=>'mixed'],
'SplDoublyLinkedList::valid' => ['bool'],
'SplEnum::__construct' => ['void', 'initial_value='=>'mixed', 'strict='=>'bool|true'],
'SplEnum::getConstList' => ['array', 'include_default='=>'bool'],
'SplFileInfo::__construct' => ['void', 'file_name'=>'string'],
'SplFileInfo::__toString' => ['string'],
'SplFileInfo::getATime' => ['int'],
'SplFileInfo::getBasename' => ['string', 'suffix='=>'string'],
'SplFileInfo::getCTime' => ['int'],
'SplFileInfo::getExtension' => ['string'],
'SplFileInfo::getFileInfo' => ['SplFileInfo', 'class_name='=>'string'],
'SplFileInfo::getFilename' => ['string'],
'SplFileInfo::getGroup' => ['int'],
'SplFileInfo::getInode' => ['int'],
'SplFileInfo::getLinkTarget' => ['string'],
'SplFileInfo::getMTime' => ['int'],
'SplFileInfo::getOwner' => ['int'],
'SplFileInfo::getPath' => ['string'],
'SplFileInfo::getPathInfo' => ['SplFileInfo', 'class_name='=>'string'],
'SplFileInfo::getPathname' => ['string'],
'SplFileInfo::getPerms' => ['int'],
'SplFileInfo::getRealPath' => ['string|false'],
'SplFileInfo::getSize' => ['int'],
'SplFileInfo::getType' => ['string'],
'SplFileInfo::isDir' => ['bool'],
'SplFileInfo::isExecutable' => ['bool'],
'SplFileInfo::isFile' => ['bool'],
'SplFileInfo::isLink' => ['bool'],
'SplFileInfo::isReadable' => ['bool'],
'SplFileInfo::isWritable' => ['bool'],
'SplFileInfo::openFile' => ['SplFileObject', 'mode='=>'string', 'use_include_path='=>'bool', 'context='=>'resource'],
'SplFileInfo::setFileClass' => ['void', 'class_name='=>'string'],
'SplFileInfo::setInfoClass' => ['void', 'class_name='=>'string'],
'SplFileObject::__construct' => ['void', 'filename'=>'string', 'mode='=>'string', 'use_include_path='=>'bool', 'context='=>''],
'SplFileObject::__toString' => ['string'],
'SplFileObject::current' => ['string|array'],
'SplFileObject::eof' => ['bool'],
'SplFileObject::fflush' => ['bool'],
'SplFileObject::fgetc' => ['string|false'],
'SplFileObject::fgetcsv' => ['?array|false', 'delimiter='=>'string', 'enclosure='=>'string', 'escape='=>'string'],
'SplFileObject::fgets' => ['string'],
'SplFileObject::fgetss' => ['string', 'allowable_tags='=>'string'],
'SplFileObject::flock' => ['bool', 'operation'=>'int', '&w_wouldblock='=>'int'],
'SplFileObject::fpassthru' => ['int'],
'SplFileObject::fputcsv' => ['int|false', 'fields'=>'array', 'delimiter='=>'string', 'enclosure='=>'string', 'escape='=>'string'],
'SplFileObject::fread' => ['string|false', 'length'=>'int'],
'SplFileObject::fscanf' => ['bool', 'format'=>'string', '&...w_vars='=>'string|int|float'],
'SplFileObject::fseek' => ['int', 'pos'=>'int', 'whence='=>'int'],
'SplFileObject::fstat' => ['array|false'],
'SplFileObject::ftell' => ['int|false'],
'SplFileObject::ftruncate' => ['bool', 'size'=>'int'],
'SplFileObject::fwrite' => ['int', 'str'=>'string', 'length='=>'int'],
'SplFileObject::getChildren' => ['bool'],
'SplFileObject::getCsvControl' => ['array'],
'SplFileObject::getFlags' => ['int'],
'SplFileObject::getMaxLineLen' => ['int'],
'SplFileObject::hasChildren' => ['bool'],
'SplFileObject::key' => ['int'],
'SplFileObject::next' => ['void'],
'SplFileObject::rewind' => ['void'],
'SplFileObject::seek' => ['void', 'line_pos'=>'int'],
'SplFileObject::setCsvControl' => ['void', 'delimiter='=>'string', 'enclosure='=>'string', 'escape='=>'string'],
'SplFileObject::setFlags' => ['void', 'flags'=>'int'],
'SplFileObject::setMaxLineLen' => ['void', 'max_len'=>'int'],
'SplFileObject::valid' => ['bool'],
'SplFixedArray::__construct' => ['void', 'size='=>'int'],
'SplFixedArray::__wakeup' => ['void'],
'SplFixedArray::count' => ['int'],
'SplFixedArray::current' => ['mixed'],
'SplFixedArray::fromArray' => ['SplFixedArray', 'data'=>'array', 'save_indexes='=>'bool'],
'SplFixedArray::getSize' => ['int'],
'SplFixedArray::key' => ['int'],
'SplFixedArray::next' => ['void'],
'SplFixedArray::offsetExists' => ['bool', 'index'=>'int'],
'SplFixedArray::offsetGet' => ['mixed', 'index'=>'int'],
'SplFixedArray::offsetSet' => ['void', 'index'=>'int', 'newval'=>'mixed'],
'SplFixedArray::offsetUnset' => ['void', 'index'=>'int'],
'SplFixedArray::rewind' => ['void'],
'SplFixedArray::setSize' => ['bool', 'size'=>'int'],
'SplFixedArray::toArray' => ['array'],
'SplFixedArray::valid' => ['bool'],
'SplHeap::compare' => ['int', 'value1'=>'mixed', 'value2'=>'mixed'],
'SplHeap::count' => ['int'],
'SplHeap::current' => ['mixed'],
'SplHeap::extract' => ['mixed'],
'SplHeap::insert' => ['bool', 'value'=>'mixed'],
'SplHeap::isCorrupted' => ['int'],
'SplHeap::isEmpty' => ['bool'],
'SplHeap::key' => ['int'],
'SplHeap::next' => ['void'],
'SplHeap::recoverFromCorruption' => ['int'],
'SplHeap::rewind' => ['void'],
'SplHeap::top' => ['mixed'],
'SplHeap::valid' => ['bool'],
'split' => ['array', 'pattern'=>'string', 'string'=>'string', 'limit='=>'int'],
'spliti' => ['array', 'pattern'=>'string', 'string'=>'string', 'limit='=>'int'],
'SplMaxHeap::compare' => ['int', 'a'=>'mixed', 'b'=>'mixed'],
'SplMinHeap::compare' => ['int', 'a'=>'mixed', 'b'=>'mixed'],
'SplObjectStorage::addAll' => ['void', 'os'=>'splobjectstorage'],
'SplObjectStorage::attach' => ['void', 'obj'=>'object', 'inf='=>'mixed'],
'SplObjectStorage::contains' => ['bool', 'obj'=>'object'],
'SplObjectStorage::count' => ['int'],
'SplObjectStorage::current' => ['object'],
'SplObjectStorage::detach' => ['void', 'obj'=>'object'],
'SplObjectStorage::getHash' => ['string', 'obj'=>'object'],
'SplObjectStorage::getInfo' => ['mixed'],
'SplObjectStorage::key' => ['int'],
'SplObjectStorage::next' => ['void'],
'SplObjectStorage::offsetExists' => ['bool', 'object'=>'object'],
'SplObjectStorage::offsetGet' => ['mixed', 'obj'=>'object'],
'SplObjectStorage::offsetSet' => ['object', 'object'=>'object', 'data='=>'mixed'],
'SplObjectStorage::offsetUnset' => ['object', 'object'=>'object'],
'SplObjectStorage::removeAll' => ['void', 'os'=>'splobjectstorage'],
'SplObjectStorage::removeAllExcept' => ['void', 'os'=>'splobjectstorage'],
'SplObjectStorage::rewind' => ['void'],
'SplObjectStorage::serialize' => ['string'],
'SplObjectStorage::setInfo' => ['void', 'inf'=>'mixed'],
'SplObjectStorage::unserialize' => ['void', 'serialized'=>'string'],
'SplObjectStorage::valid' => ['bool'],
'SplObserver::update' => ['void', 'subject'=>'splsubject'],
'SplPriorityQueue::compare' => ['int', 'a'=>'mixed', 'b'=>'mixed'],
'SplPriorityQueue::count' => ['int'],
'SplPriorityQueue::current' => ['mixed'],
'SplPriorityQueue::extract' => ['mixed'],
'SplPriorityQueue::getExtractFlags' => ['int'],
'SplPriorityQueue::insert' => ['bool', 'value'=>'mixed', 'priority'=>'mixed'],
'SplPriorityQueue::isEmpty' => ['bool'],
'SplPriorityQueue::key' => ['mixed'],
'SplPriorityQueue::next' => ['void'],
'SplPriorityQueue::recoverFromCorruption' => ['void'],
'SplPriorityQueue::rewind' => ['void'],
'SplPriorityQueue::setExtractFlags' => ['void', 'flags'=>'int'],
'SplPriorityQueue::top' => ['mixed'],
'SplPriorityQueue::valid' => ['bool'],
'SplQueue::dequeue' => ['mixed'],
'SplQueue::enqueue' => ['void', 'value'=>'mixed'],
'SplQueue::setIteratorMode' => ['void', 'mode'=>'int'],
'SplStack::setIteratorMode' => ['void', 'mode'=>'int'],
'SplSubject::attach' => ['void', 'observer'=>'splobserver'],
'SplSubject::detach' => ['void', 'observer'=>'splobserver'],
'SplSubject::notify' => ['void'],
'SplTempFileObject::__construct' => ['void', 'max_memory='=>'int'],
'SplType::__construct' => ['void', 'initial_value='=>'mixed', 'strict='=>'bool'],
'Spoofchecker::__construct' => ['void'],
'Spoofchecker::areConfusable' => ['bool', 's1'=>'string', 's2'=>'string', '&w_error='=>'string'],
'Spoofchecker::isSuspicious' => ['bool', 'text'=>'string', '&w_error='=>'string'],
'Spoofchecker::setAllowedLocales' => ['void', 'locale_list'=>'string'],
'Spoofchecker::setChecks' => ['void', 'checks'=>'long'],
'sprintf' => ['string', 'format'=>'string', '...args='=>'string|int|float'],
'sql_regcase' => ['string', 'string'=>'string'],
'SQLite3::__construct' => ['void', 'filename'=>'string', 'flags='=>'int', 'encryption_key='=>'string|null'],
'SQLite3::busyTimeout' => ['bool', 'msecs'=>'int'],
'SQLite3::changes' => ['int'],
'SQLite3::close' => ['bool'],
'SQLite3::createAggregate' => ['bool', 'name'=>'string', 'step_callback'=>'callable', 'final_callback'=>'callable', 'argument_count='=>'int'],
'SQLite3::createCollation' => ['bool', 'name'=>'string', 'callback'=>'callable'],
'SQLite3::createFunction' => ['bool', 'name'=>'string', 'callback'=>'callable', 'argument_count='=>'int', 'flags='=>'int'],
'SQLite3::enableExceptions' => ['bool', 'enableexceptions='=>'bool'],
'SQLite3::escapeString' => ['string', 'value'=>'string'],
'SQLite3::exec' => ['bool', 'query'=>'string'],
'SQLite3::lastErrorCode' => ['int'],
'SQLite3::lastErrorMsg' => ['string'],
'SQLite3::lastInsertRowID' => ['int'],
'SQLite3::loadExtension' => ['bool', 'shared_library'=>'string'],
'SQLite3::open' => ['void', 'filename'=>'string', 'flags='=>'int', 'encryption_key='=>'string|null'],
'SQLite3::openBlob' => ['resource', 'table'=>'string', 'column'=>'string', 'rowid'=>'int', 'dbname'=>'string', 'flags='=>'int'],
'SQLite3::prepare' => ['SQLite3Stmt|false', 'query'=>'string'],
'SQLite3::query' => ['SQLite3Result|false', 'query'=>'string'],
'SQLite3::querySingle' => ['array|int|string|bool|float|null|false', 'query'=>'string', 'entire_row='=>'bool'],
'SQLite3::version' => ['array'],
'SQLite3Result::__construct' => ['void'],
'SQLite3Result::columnName' => ['string', 'column_number'=>'int'],
'SQLite3Result::columnType' => ['int', 'column_number'=>'int'],
'SQLite3Result::fetchArray' => ['array', 'mode='=>'int'],
'SQLite3Result::finalize' => ['bool'],
'SQLite3Result::numColumns' => ['int'],
'SQLite3Result::reset' => ['bool'],
'SQLite3Stmt::__construct' => ['void', 'dbobject'=>'sqlite3', 'statement'=>'string'],
'SQLite3Stmt::bindParam' => ['bool', 'parameter_name_or_number'=>'string|int', '&rw_parameter'=>'mixed', 'type='=>'int'],
'SQLite3Stmt::bindValue' => ['bool', 'parameter_name_or_number'=>'string|int', 'parameter'=>'mixed', 'type='=>'int'],
'SQLite3Stmt::clear' => ['bool'],
'SQLite3Stmt::close' => ['bool'],
'SQLite3Stmt::execute' => ['SQLite3Result'],
'SQLite3Stmt::paramCount' => ['int'],
'SQLite3Stmt::readOnly' => ['bool'],
'SQLite3Stmt::reset' => ['bool'],
'sqlite_array_query' => ['array', 'dbhandle'=>'', 'query'=>'string', 'result_type='=>'int', 'decode_binary='=>'bool'],
'sqlite_busy_timeout' => ['', 'dbhandle'=>'', 'milliseconds'=>'int'],
'sqlite_changes' => ['int', 'dbhandle'=>''],
'sqlite_close' => ['void', 'dbhandle'=>'resource'],
'sqlite_column' => ['', 'result'=>'', 'index_or_name'=>'', 'decode_binary='=>'bool'],
'sqlite_create_aggregate' => ['', 'dbhandle'=>'', 'function_name'=>'string', 'step_func'=>'callable', 'finalize_func'=>'callable', 'num_args='=>'int'],
'sqlite_create_function' => ['', 'dbhandle'=>'', 'function_name'=>'string', 'callback'=>'callable', 'num_args='=>'int'],
'sqlite_current' => ['array', 'result'=>'', 'result_type='=>'int', 'decode_binary='=>'bool'],
'sqlite_error_string' => ['string', 'error_code'=>'int'],
'sqlite_escape_string' => ['string', 'item'=>'string'],
'sqlite_exec' => ['bool', 'dbhandle'=>'', 'query'=>'string', 'error_msg='=>'string'],
'sqlite_factory' => ['SQLiteDatabase', 'filename'=>'string', 'mode='=>'int', 'error_message='=>'string'],
'sqlite_fetch_all' => ['array', 'result'=>'', 'result_type='=>'int', 'decode_binary='=>'bool'],
'sqlite_fetch_array' => ['array', 'result'=>'', 'result_type='=>'int', 'decode_binary='=>'bool'],
'sqlite_fetch_column_types' => ['array', 'table_name'=>'string', 'dbhandle'=>'', 'result_type='=>'int'],
'sqlite_fetch_object' => ['object', 'result'=>'', 'class_name='=>'string', 'ctor_params='=>'array', 'decode_binary='=>'bool'],
'sqlite_fetch_single' => ['string', 'result'=>'', 'decode_binary='=>'bool'],
'sqlite_field_name' => ['string', 'result'=>'', 'field_index'=>'int'],
'sqlite_has_more' => ['bool', 'result'=>'resource'],
'sqlite_has_prev' => ['bool', 'result'=>''],
'sqlite_key' => ['int', 'result'=>''],
'sqlite_last_error' => ['int', 'dbhandle'=>''],
'sqlite_last_insert_rowid' => ['int', 'dbhandle'=>''],
'sqlite_libencoding' => ['string'],
'sqlite_libversion' => ['string'],
'sqlite_next' => ['bool', 'result'=>''],
'sqlite_num_fields' => ['int', 'result'=>''],
'sqlite_num_rows' => ['int', 'result'=>''],
'sqlite_open' => ['resource', 'filename'=>'string', 'mode='=>'int', 'error_message='=>'string'],
'sqlite_popen' => ['resource', 'filename'=>'string', 'mode='=>'int', 'error_message='=>'string'],
'sqlite_prev' => ['bool', 'result'=>''],
'sqlite_query' => ['SQLiteResult', 'dbhandle'=>'', 'query'=>'string', 'result_type='=>'int', 'error_msg='=>'string'],
'sqlite_rewind' => ['bool', 'result'=>''],
'sqlite_seek' => ['bool', 'result'=>'', 'rownum'=>'int'],
'sqlite_single_query' => ['array', 'db'=>'', 'query'=>'string', 'first_row_only='=>'bool', 'decode_binary='=>'bool'],
'sqlite_udf_decode_binary' => ['string', 'data'=>'string'],
'sqlite_udf_encode_binary' => ['string', 'data'=>'string'],
'sqlite_unbuffered_query' => ['SQLiteUnbuffered', 'dbhandle'=>'', 'query'=>'string', 'result_type='=>'int', 'error_msg='=>'string'],
'sqlite_valid' => ['bool', 'result'=>''],
'SQLiteDatabase::arrayQuery' => ['array', 'dbhandle'=>'', 'query'=>'string', 'result_type='=>'int', 'decode_binary='=>'bool'],
'SQLiteDatabase::busyTimeout' => ['', 'dbhandle'=>'', 'milliseconds'=>'int'],
'SQLiteDatabase::changes' => ['int', 'dbhandle'=>''],
'SQLiteDatabase::createAggregate' => ['', 'dbhandle'=>'', 'function_name'=>'string', 'step_func'=>'callable', 'finalize_func'=>'callable', 'num_args='=>'int'],
'SQLiteDatabase::createFunction' => ['', 'dbhandle'=>'', 'function_name'=>'string', 'callback'=>'callable', 'num_args='=>'int'],
'SQLiteDatabase::exec' => ['bool', 'dbhandle'=>'', 'query'=>'string', 'error_msg='=>'string'],
'SQLiteDatabase::fetchColumnTypes' => ['array', 'table_name'=>'string', 'dbhandle'=>'', 'result_type='=>'int'],
'SQLiteDatabase::lastError' => ['int', 'dbhandle'=>''],
'SQLiteDatabase::lastInsertRowid' => ['int', 'dbhandle'=>''],
'SQLiteDatabase::query' => ['SQLiteResult', 'dbhandle'=>'', 'query'=>'string', 'result_type='=>'int', 'error_msg='=>'string'],
'SQLiteDatabase::queryExec' => ['bool', 'query'=>'string', '&w_error_msg='=>'string'],
'SQLiteDatabase::singleQuery' => ['array', 'db'=>'', 'query'=>'string', 'first_row_only='=>'bool', 'decode_binary='=>'bool'],
'SQLiteDatabase::unbufferedQuery' => ['SQLiteUnbuffered', 'dbhandle'=>'', 'query'=>'string', 'result_type='=>'int', 'error_msg='=>'string'],
'SQLiteResult::column' => ['', 'result'=>'', 'index_or_name'=>'', 'decode_binary='=>'bool'],
'SQLiteResult::current' => ['array', 'result'=>'', 'result_type='=>'int', 'decode_binary='=>'bool'],
'SQLiteResult::fetch' => ['array', 'result'=>'', 'result_type='=>'int', 'decode_binary='=>'bool'],
'SQLiteResult::fetchAll' => ['array', 'result'=>'', 'result_type='=>'int', 'decode_binary='=>'bool'],
'SQLiteResult::fetchObject' => ['object', 'result'=>'', 'class_name='=>'string', 'ctor_params='=>'array', 'decode_binary='=>'bool'],
'SQLiteResult::fetchSingle' => ['string', 'result'=>'', 'decode_binary='=>'bool'],
'SQLiteResult::fieldName' => ['string', 'result'=>'', 'field_index'=>'int'],
'SQLiteResult::hasPrev' => ['bool', 'result'=>''],
'SQLiteResult::key' => ['int', 'result'=>''],
'SQLiteResult::next' => ['bool', 'result'=>''],
'SQLiteResult::numFields' => ['int', 'result'=>''],
'SQLiteResult::numRows' => ['int', 'result'=>''],
'SQLiteResult::prev' => ['bool', 'result'=>''],
'SQLiteResult::rewind' => ['bool', 'result'=>''],
'SQLiteResult::seek' => ['bool', 'result'=>'', 'rownum'=>'int'],
'SQLiteResult::valid' => ['bool', 'result'=>''],
'SQLiteUnbuffered::column' => ['', 'result'=>'', 'index_or_name'=>'', 'decode_binary='=>'bool'],
'SQLiteUnbuffered::current' => ['array', 'result'=>'', 'result_type='=>'int', 'decode_binary='=>'bool'],
'SQLiteUnbuffered::fetch' => ['array', 'result'=>'', 'result_type='=>'int', 'decode_binary='=>'bool'],
'SQLiteUnbuffered::fetchAll' => ['array', 'result'=>'', 'result_type='=>'int', 'decode_binary='=>'bool'],
'SQLiteUnbuffered::fetchObject' => ['object', 'result'=>'', 'class_name='=>'string', 'ctor_params='=>'array', 'decode_binary='=>'bool'],
'SQLiteUnbuffered::fetchSingle' => ['string', 'result'=>'', 'decode_binary='=>'bool'],
'SQLiteUnbuffered::fieldName' => ['string', 'result'=>'', 'field_index'=>'int'],
'SQLiteUnbuffered::next' => ['bool', 'result'=>''],
'SQLiteUnbuffered::numFields' => ['int', 'result'=>''],
'SQLiteUnbuffered::valid' => ['bool', 'result'=>''],
'sqlsrv_begin_transaction' => ['bool', 'conn'=>'resource'],
'sqlsrv_cancel' => ['bool', 'stmt'=>'resource'],
'sqlsrv_client_info' => ['array', 'conn'=>'resource'],
'sqlsrv_close' => ['bool', 'conn'=>'resource'],
'sqlsrv_commit' => ['bool', 'conn'=>'resource'],
'sqlsrv_configure' => ['bool', 'setting'=>'string', 'value'=>'mixed'],
'sqlsrv_connect' => ['resource', 'serverName'=>'string', 'connectionInfo='=>'array'],
'sqlsrv_errors' => ['mixed', 'errorsOrWarnings='=>'int'],
'sqlsrv_execute' => ['bool', 'stmt'=>'resource'],
'sqlsrv_fetch' => ['mixed', 'stmt'=>'resource', 'row='=>'int', 'offset='=>'int'],
'sqlsrv_fetch_array' => ['array', 'stmt'=>'resource', 'fetchType='=>'int', 'row='=>'int', 'offset='=>'int'],
'sqlsrv_fetch_object' => ['mixed', 'stmt'=>'resource', 'className='=>'string', 'ctorParams='=>'array', 'row='=>'int', 'offset='=>'int'],
'sqlsrv_field_metadata' => ['mixed', 'stmt'=>'resource'],
'sqlsrv_free_stmt' => ['bool', 'stmt'=>'resource'],
'sqlsrv_get_config' => ['mixed', 'setting'=>'string'],
'sqlsrv_get_field' => ['mixed', 'stmt'=>'resource', 'fieldIndex'=>'int', 'getAsType='=>'int'],
'sqlsrv_has_rows' => ['bool', 'stmt'=>'resource'],
'sqlsrv_next_result' => ['mixed', 'stmt'=>'resource'],
'sqlsrv_num_fields' => ['mixed', 'stmt'=>'resource'],
'sqlsrv_num_rows' => ['mixed', 'stmt'=>'resource'],
'sqlsrv_prepare' => ['mixed', 'conn'=>'resource', 'sql'=>'string', 'params='=>'array', 'options='=>'array'],
'sqlsrv_query' => ['mixed', 'conn'=>'resource', 'sql'=>'string', 'params='=>'array', 'options='=>'array'],
'sqlsrv_rollback' => ['bool', 'conn'=>'resource'],
'sqlsrv_rows_affected' => ['int', 'stmt'=>'resource'],
'sqlsrv_send_stream_data' => ['bool', 'stmt'=>'resource'],
'sqlsrv_server_info' => ['array', 'conn'=>'resource'],
'sqrt' => ['float', 'number'=>'float'],
'srand' => ['void', 'seed='=>'int', 'mode='=>'int'],
'sscanf' => ['mixed', 'str'=>'string', 'format'=>'string', '&...w_vars='=>'string|int|float|null'],
'ssdeep_fuzzy_compare' => ['int', 'signature1'=>'string', 'signature2'=>'string'],
'ssdeep_fuzzy_hash' => ['string', 'to_hash'=>'string'],
'ssdeep_fuzzy_hash_filename' => ['string', 'file_name'=>'string'],
'ssh2_auth_agent' => ['bool', 'session'=>'resource', 'username'=>'string'],
'ssh2_auth_hostbased_file' => ['bool', 'session'=>'resource', 'username'=>'string', 'hostname'=>'string', 'pubkeyfile'=>'string', 'privkeyfile'=>'string', 'passphrase='=>'string', 'local_username='=>'string'],
'ssh2_auth_none' => ['true|string[]', 'session'=>'resource', 'username'=>'string'],
'ssh2_auth_password' => ['bool', 'session'=>'resource', 'username'=>'string', 'password'=>'string'],
'ssh2_auth_pubkey_file' => ['bool', 'session'=>'resource', 'username'=>'string', 'pubkeyfile'=>'string', 'privkeyfile'=>'string', 'passphrase='=>'string'],
'ssh2_connect' => ['resource|false', 'host'=>'string', 'port='=>'int', 'methods='=>'array', 'callbacks='=>'array'],
'ssh2_disconnect' => ['bool', 'session'=>'resource'],
'ssh2_exec' => ['resource|false', 'session'=>'resource', 'command'=>'string', 'pty='=>'string', 'env='=>'array', 'width='=>'int', 'height='=>'int', 'width_height_type='=>'int'],
'ssh2_fetch_stream' => ['resource', 'channel'=>'resource', 'streamid'=>'int'],
'ssh2_fingerprint' => ['string', 'session'=>'resource', 'flags='=>'int'],
'ssh2_methods_negotiated' => ['array', 'session'=>'resource'],
'ssh2_publickey_add' => ['bool', 'pkey'=>'resource', 'algoname'=>'string', 'blob'=>'string', 'overwrite='=>'bool', 'attributes='=>'array'],
'ssh2_publickey_init' => ['resource|false', 'session'=>'resource'],
'ssh2_publickey_list' => ['array', 'pkey'=>'resource'],
'ssh2_publickey_remove' => ['bool', 'pkey'=>'resource', 'algoname'=>'string', 'blob'=>'string'],
'ssh2_scp_recv' => ['bool', 'session'=>'resource', 'remote_file'=>'string', 'local_file'=>'string'],
'ssh2_scp_send' => ['bool', 'session'=>'resource', 'local_file'=>'string', 'remote_file'=>'string', 'create_mode='=>'int'],
'ssh2_sftp' => ['resource', 'session'=>'resource'],
'ssh2_sftp_chmod' => ['bool', 'sftp'=>'resource', 'filename'=>'string', 'mode'=>'int'],
'ssh2_sftp_lstat' => ['array', 'sftp'=>'resource', 'path'=>'string'],
'ssh2_sftp_mkdir' => ['bool', 'sftp'=>'resource', 'dirname'=>'string', 'mode='=>'int', 'recursive='=>'bool'],
'ssh2_sftp_readlink' => ['string', 'sftp'=>'resource', 'link'=>'string'],
'ssh2_sftp_realpath' => ['string', 'sftp'=>'resource', 'filename'=>'string'],
'ssh2_sftp_rename' => ['bool', 'sftp'=>'resource', 'from'=>'string', 'to'=>'string'],
'ssh2_sftp_rmdir' => ['bool', 'sftp'=>'resource', 'dirname'=>'string'],
'ssh2_sftp_stat' => ['array|false', 'sftp'=>'resource', 'path'=>'string'],
'ssh2_sftp_symlink' => ['bool', 'sftp'=>'resource', 'target'=>'string', 'link'=>'string'],
'ssh2_sftp_unlink' => ['bool', 'sftp'=>'resource', 'filename'=>'string'],
'ssh2_shell' => ['resource', 'session'=>'resource', 'term_type='=>'string', 'env='=>'array', 'width='=>'int', 'height='=>'int', 'width_height_type='=>'int'],
'ssh2_tunnel' => ['resource', 'session'=>'resource', 'host'=>'string', 'port'=>'int'],
'stat' => ['array|false', 'filename'=>'string'],
'stats_absolute_deviation' => ['float', 'a'=>'array'],
'stats_cdf_beta' => ['float', 'par1'=>'float', 'par2'=>'float', 'par3'=>'float', 'which'=>'int'],
'stats_cdf_binomial' => ['float', 'par1'=>'float', 'par2'=>'float', 'par3'=>'float', 'which'=>'int'],
'stats_cdf_cauchy' => ['float', 'par1'=>'float', 'par2'=>'float', 'par3'=>'float', 'which'=>'int'],
'stats_cdf_chisquare' => ['float', 'par1'=>'float', 'par2'=>'float', 'which'=>'int'],
'stats_cdf_exponential' => ['float', 'par1'=>'float', 'par2'=>'float', 'which'=>'int'],
'stats_cdf_f' => ['float', 'par1'=>'float', 'par2'=>'float', 'par3'=>'float', 'which'=>'int'],
'stats_cdf_gamma' => ['float', 'par1'=>'float', 'par2'=>'float', 'par3'=>'float', 'which'=>'int'],
'stats_cdf_laplace' => ['float', 'par1'=>'float', 'par2'=>'float', 'par3'=>'float', 'which'=>'int'],
'stats_cdf_logistic' => ['float', 'par1'=>'float', 'par2'=>'float', 'par3'=>'float', 'which'=>'int'],
'stats_cdf_negative_binomial' => ['float', 'par1'=>'float', 'par2'=>'float', 'par3'=>'float', 'which'=>'int'],
'stats_cdf_noncentral_chisquare' => ['float', 'par1'=>'float', 'par2'=>'float', 'par3'=>'float', 'which'=>'int'],
'stats_cdf_noncentral_f' => ['float', 'par1'=>'float', 'par2'=>'float', 'par3'=>'float', 'par4'=>'float', 'which'=>'int'],
'stats_cdf_noncentral_t' => ['float', 'par1'=>'float', 'par2'=>'float', 'par3'=>'float', 'which'=>'int'],
'stats_cdf_normal' => ['float', 'par1'=>'float', 'par2'=>'float', 'par3'=>'float', 'which'=>'int'],
'stats_cdf_poisson' => ['float', 'par1'=>'float', 'par2'=>'float', 'which'=>'int'],
'stats_cdf_t' => ['float', 'par1'=>'float', 'par2'=>'float', 'which'=>'int'],
'stats_cdf_uniform' => ['float', 'par1'=>'float', 'par2'=>'float', 'par3'=>'float', 'which'=>'int'],
'stats_cdf_weibull' => ['float', 'par1'=>'float', 'par2'=>'float', 'par3'=>'float', 'which'=>'int'],
'stats_covariance' => ['float', 'a'=>'array', 'b'=>'array'],
'stats_den_uniform' => ['float', 'x'=>'float', 'a'=>'float', 'b'=>'float'],
'stats_dens_beta' => ['float', 'x'=>'float', 'a'=>'float', 'b'=>'float'],
'stats_dens_cauchy' => ['float', 'x'=>'float', 'ave'=>'float', 'stdev'=>'float'],
'stats_dens_chisquare' => ['float', 'x'=>'float', 'dfr'=>'float'],
'stats_dens_exponential' => ['float', 'x'=>'float', 'scale'=>'float'],
'stats_dens_f' => ['float', 'x'=>'float', 'dfr1'=>'float', 'dfr2'=>'float'],
'stats_dens_gamma' => ['float', 'x'=>'float', 'shape'=>'float', 'scale'=>'float'],
'stats_dens_laplace' => ['float', 'x'=>'float', 'ave'=>'float', 'stdev'=>'float'],
'stats_dens_logistic' => ['float', 'x'=>'float', 'ave'=>'float', 'stdev'=>'float'],
'stats_dens_negative_binomial' => ['float', 'x'=>'float', 'n'=>'float', 'pi'=>'float'],
'stats_dens_normal' => ['float', 'x'=>'float', 'ave'=>'float', 'stdev'=>'float'],
'stats_dens_pmf_binomial' => ['float', 'x'=>'float', 'n'=>'float', 'pi'=>'float'],
'stats_dens_pmf_hypergeometric' => ['float', 'n1'=>'float', 'n2'=>'float', 'N1'=>'float', 'N2'=>'float'],
'stats_dens_pmf_negative_binomial' => ['float', 'x'=>'float', 'n'=>'float', 'pi'=>'float'],
'stats_dens_pmf_poisson' => ['float', 'x'=>'float', 'lb'=>'float'],
'stats_dens_t' => ['float', 'x'=>'float', 'dfr'=>'float'],
'stats_dens_uniform' => ['float', 'x'=>'float', 'a'=>'float', 'b'=>'float'],
'stats_dens_weibull' => ['float', 'x'=>'float', 'a'=>'float', 'b'=>'float'],
'stats_harmonic_mean' => ['float', 'a'=>'array'],
'stats_kurtosis' => ['float', 'a'=>'array'],
'stats_rand_gen_beta' => ['float', 'a'=>'float', 'b'=>'float'],
'stats_rand_gen_chisquare' => ['float', 'df'=>'float'],
'stats_rand_gen_exponential' => ['float', 'av'=>'float'],
'stats_rand_gen_f' => ['float', 'dfn'=>'float', 'dfd'=>'float'],
'stats_rand_gen_funiform' => ['float', 'low'=>'float', 'high'=>'float'],
'stats_rand_gen_gamma' => ['float', 'a'=>'float', 'r'=>'float'],
'stats_rand_gen_ibinomial' => ['int', 'n'=>'int', 'pp'=>'float'],
'stats_rand_gen_ibinomial_negative' => ['int', 'n'=>'int', 'p'=>'float'],
'stats_rand_gen_int' => ['int'],
'stats_rand_gen_ipoisson' => ['int', 'mu'=>'float'],
'stats_rand_gen_iuniform' => ['int', 'low'=>'int', 'high'=>'int'],
'stats_rand_gen_noncenral_chisquare' => ['float', 'df'=>'float', 'xnonc'=>'float'],
'stats_rand_gen_noncentral_chisquare' => ['float', 'df'=>'float', 'xnonc'=>'float'],
'stats_rand_gen_noncentral_f' => ['float', 'dfn'=>'float', 'dfd'=>'float', 'xnonc'=>'float'],
'stats_rand_gen_noncentral_t' => ['float', 'df'=>'float', 'xnonc'=>'float'],
'stats_rand_gen_normal' => ['float', 'av'=>'float', 'sd'=>'float'],
'stats_rand_gen_t' => ['float', 'df'=>'float'],
'stats_rand_get_seeds' => ['array'],
'stats_rand_phrase_to_seeds' => ['array', 'phrase'=>'string'],
'stats_rand_ranf' => ['float'],
'stats_rand_setall' => ['void', 'iseed1'=>'int', 'iseed2'=>'int'],
'stats_skew' => ['float', 'a'=>'array'],
'stats_standard_deviation' => ['float', 'a'=>'array', 'sample='=>'bool'],
'stats_stat_binomial_coef' => ['float', 'x'=>'int', 'n'=>'int'],
'stats_stat_correlation' => ['float', 'arr1'=>'array', 'arr2'=>'array'],
'stats_stat_factorial' => ['float', 'n'=>'int'],
'stats_stat_gennch' => ['float', 'n'=>'int'],
'stats_stat_independent_t' => ['float', 'arr1'=>'array', 'arr2'=>'array'],
'stats_stat_innerproduct' => ['float', 'arr1'=>'array', 'arr2'=>'array'],
'stats_stat_noncentral_t' => ['float', 'par1'=>'float', 'par2'=>'float', 'par3'=>'float', 'which'=>'int'],
'stats_stat_paired_t' => ['float', 'arr1'=>'array', 'arr2'=>'array'],
'stats_stat_percentile' => ['float', 'df'=>'float', 'xnonc'=>'float'],
'stats_stat_powersum' => ['float', 'arr'=>'array', 'power'=>'float'],
'stats_variance' => ['float', 'a'=>'array', 'sample='=>'bool'],
'Stomp::__construct' => ['void', 'broker='=>'string', 'username='=>'string', 'password='=>'string', 'headers='=>'array'],
'Stomp::__destruct' => ['bool', 'link'=>''],
'Stomp::abort' => ['bool', 'transaction_id'=>'string', 'headers='=>'array', 'link='=>''],
'Stomp::ack' => ['bool', 'msg'=>'', 'headers='=>'array', 'link='=>''],
'Stomp::begin' => ['bool', 'transaction_id'=>'string', 'headers='=>'array', 'link='=>''],
'Stomp::commit' => ['bool', 'transaction_id'=>'string', 'headers='=>'array', 'link='=>''],
'Stomp::error' => ['string', 'link'=>''],
'Stomp::getReadTimeout' => ['array', 'link'=>''],
'Stomp::getSessionId' => ['string', 'link'=>''],
'Stomp::hasFrame' => ['bool', 'link'=>''],
'Stomp::readFrame' => ['array', 'class_name='=>'string', 'link='=>''],
'Stomp::send' => ['bool', 'destination'=>'string', 'msg'=>'', 'headers='=>'array', 'link='=>''],
'Stomp::setReadTimeout' => ['', 'seconds'=>'int', 'microseconds='=>'int', 'link='=>''],
'Stomp::subscribe' => ['bool', 'destination'=>'string', 'headers='=>'array', 'link='=>''],
'Stomp::unsubscribe' => ['bool', 'destination'=>'string', 'headers='=>'array', 'link='=>''],
'stomp_abort' => ['bool', 'transaction_id'=>'string', 'headers='=>'array', 'link='=>''],
'stomp_ack' => ['bool', 'msg'=>'', 'headers='=>'array', 'link='=>''],
'stomp_begin' => ['bool', 'transaction_id'=>'string', 'headers='=>'array', 'link='=>''],
'stomp_close' => ['bool', 'link'=>''],
'stomp_commit' => ['bool', 'transaction_id'=>'string', 'headers='=>'array', 'link='=>''],
'stomp_connect' => ['resource', 'broker='=>'string', 'username='=>'string', 'password='=>'string', 'headers='=>'array'],
'stomp_connect_error' => ['string'],
'stomp_error' => ['string', 'link'=>''],
'stomp_get_read_timeout' => ['array', 'link'=>''],
'stomp_get_session_id' => ['string', 'link'=>''],
'stomp_has_frame' => ['bool', 'link'=>''],
'stomp_read_frame' => ['array', 'class_name='=>'string', 'link='=>''],
'stomp_send' => ['bool', 'destination'=>'string', 'msg'=>'', 'headers='=>'array', 'link='=>''],
'stomp_set_read_timeout' => ['', 'seconds'=>'int', 'microseconds='=>'int', 'link='=>''],
'stomp_subscribe' => ['bool', 'destination'=>'string', 'headers='=>'array', 'link='=>''],
'stomp_unsubscribe' => ['bool', 'destination'=>'string', 'headers='=>'array', 'link='=>''],
'stomp_version' => ['string'],
'StompException::getDetails' => ['string'],
'StompFrame::__construct' => ['void', 'command='=>'string', 'headers='=>'array', 'body='=>'string'],
'str_getcsv' => ['array', 'input'=>'string', 'delimiter='=>'string', 'enclosure='=>'string', 'escape='=>'string'],
'str_ireplace' => ['string|string[]', 'search'=>'string|array', 'replace'=>'string|array', 'subject'=>'string|array', '&w_replace_count='=>'int'],
'str_pad' => ['string', 'input'=>'string', 'pad_length'=>'int', 'pad_string='=>'string', 'pad_type='=>'int'],
'str_repeat' => ['string', 'input'=>'string', 'multiplier'=>'int'],
'str_replace' => ['string|array', 'search'=>'string|array', 'replace'=>'string|array', 'subject'=>'string|array', '&w_replace_count='=>'int'],
'str_rot13' => ['string', 'str'=>'string'],
'str_shuffle' => ['string', 'str'=>'string'],
'str_split' => ['array|false', 'str'=>'string', 'split_length='=>'int'],
'str_word_count' => ['array|int', 'string'=>'string', 'format='=>'int', 'charlist='=>'string'],
'strcasecmp' => ['int', 'str1'=>'string', 'str2'=>'string'],
'strchr' => ['string|false', 'haystack'=>'string', 'needle'=>'string', 'before_needle='=>'bool'],
'strcmp' => ['int', 'str1'=>'string', 'str2'=>'string'],
'strcoll' => ['int', 'str1'=>'string', 'str2'=>'string'],
'strcspn' => ['int', 'str'=>'string', 'mask'=>'string', 'start='=>'int', 'length='=>'int'],
'stream_bucket_append' => ['void', 'brigade'=>'resource', 'bucket'=>'object'],
'stream_bucket_make_writeable' => ['object', 'brigade'=>'resource'],
'stream_bucket_new' => ['resource', 'stream'=>'resource', 'buffer'=>'string'],
'stream_bucket_prepend' => ['void', 'brigade'=>'resource', 'bucket'=>'object'],
'stream_context_create' => ['resource', 'options='=>'array', 'params='=>'array'],
'stream_context_get_default' => ['resource', 'options='=>'array'],
'stream_context_get_options' => ['array', 'context'=>'resource'],
'stream_context_get_params' => ['array', 'context'=>'resource'],
'stream_context_set_default' => ['resource', 'options'=>'array'],
'stream_context_set_option' => ['bool', 'context'=>'', 'wrappername'=>'string', 'optionname'=>'string', 'value'=>''],
'stream_context_set_option\'1' => ['bool', 'context'=>'', 'options'=>'array'],
'stream_context_set_params' => ['bool', 'context'=>'resource', 'options'=>'array'],
'stream_copy_to_stream' => ['int|false', 'source'=>'resource', 'dest'=>'resource', 'maxlen='=>'int', 'pos='=>'int'],
'stream_encoding' => ['bool', 'stream'=>'resource', 'encoding='=>'string'],
'stream_filter_append' => ['resource|false', 'stream'=>'resource', 'filtername'=>'string', 'read_write='=>'int', 'filterparams='=>'array'],
'stream_filter_prepend' => ['resource|false', 'stream'=>'resource', 'filtername'=>'string', 'read_write='=>'int', 'filterparams='=>'array'],
'stream_filter_register' => ['bool', 'filtername'=>'string', 'classname'=>'string'],
'stream_filter_remove' => ['bool', 'stream_filter'=>'resource'],
'stream_get_contents' => ['string|false', 'source'=>'resource', 'maxlen='=>'int', 'offset='=>'int'],
'stream_get_filters' => ['array'],
'stream_get_line' => ['string|false', 'stream'=>'resource', 'maxlen'=>'int', 'ending='=>'string'],
'stream_get_meta_data' => ['array', 'fp'=>'resource'],
'stream_get_transports' => ['array'],
'stream_get_wrappers' => ['array'],
'stream_is_local' => ['bool', 'stream'=>'resource|string'],
'stream_isatty' => ['bool', 'stream'=>'resource'],
'stream_notification_callback' => ['callback', 'notification_code'=>'int', 'severity'=>'int', 'message'=>'string', 'message_code'=>'int', 'bytes_transferred'=>'int', 'bytes_max'=>'int'],
'stream_resolve_include_path' => ['string|false', 'filename'=>'string'],
'stream_select' => ['int|false', '&rw_read_streams'=>'resource[]', '&rw_write_streams'=>'?resource[]', '&rw_except_streams'=>'?resource[]', 'tv_sec'=>'?int', 'tv_usec='=>'?int'],
'stream_set_blocking' => ['bool', 'socket'=>'resource', 'mode'=>'bool'],
'stream_set_chunk_size' => ['int|false', 'fp'=>'resource', 'chunk_size'=>'int'],
'stream_set_read_buffer' => ['int', 'fp'=>'resource', 'buffer'=>'int'],
'stream_set_timeout' => ['bool', 'stream'=>'resource', 'seconds'=>'int', 'microseconds='=>'int'],
'stream_set_write_buffer' => ['int', 'fp'=>'resource', 'buffer'=>'int'],
'stream_socket_accept' => ['resource|false', 'serverstream'=>'resource', 'timeout='=>'float', '&w_peername='=>'string'],
'stream_socket_client' => ['resource|false', 'remoteaddress'=>'string', '&w_errcode='=>'int', '&w_errstring='=>'string', 'timeout='=>'float', 'flags='=>'int', 'context='=>'resource'],
'stream_socket_enable_crypto' => ['int', 'stream'=>'resource', 'enable'=>'bool', 'cryptokind='=>'int', 'sessionstream='=>'resource'],
'stream_socket_get_name' => ['string', 'stream'=>'resource', 'want_peer'=>'bool'],
'stream_socket_pair' => ['resource[]|false', 'domain'=>'int', 'type'=>'int', 'protocol'=>'int'],
'stream_socket_recvfrom' => ['string', 'stream'=>'resource', 'amount'=>'int', 'flags='=>'int', '&w_remote_addr='=>'string'],
'stream_socket_sendto' => ['int', 'stream'=>'resource', 'data'=>'string', 'flags='=>'int', 'target_addr='=>'string'],
'stream_socket_server' => ['resource|false', 'localaddress'=>'string', '&w_errcode='=>'int', '&w_errstring='=>'string', 'flags='=>'int', 'context='=>'resource'],
'stream_socket_shutdown' => ['bool', 'stream'=>'resource', 'how'=>'int'],
'stream_supports_lock' => ['bool', 'stream'=>'resource'],
'stream_wrapper_register' => ['bool', 'protocol'=>'string', 'classname'=>'string', 'flags='=>'int'],
'stream_wrapper_restore' => ['bool', 'protocol'=>'string'],
'stream_wrapper_unregister' => ['bool', 'protocol'=>'string'],
'streamWrapper::__construct' => ['void'],
'streamWrapper::__destruct' => [''],
'streamWrapper::dir_closedir' => ['bool'],
'streamWrapper::dir_opendir' => ['bool', 'path'=>'string', 'options'=>'int'],
'streamWrapper::dir_readdir' => ['string'],
'streamWrapper::dir_rewinddir' => ['bool'],
'streamWrapper::mkdir' => ['bool', 'path'=>'string', 'mode'=>'int', 'options'=>'int'],
'streamWrapper::rename' => ['bool', 'path_from'=>'string', 'path_to'=>'string'],
'streamWrapper::rmdir' => ['bool', 'path'=>'string', 'options'=>'int'],
'streamWrapper::stream_cast' => ['resource', 'cast_as'=>'int'],
'streamWrapper::stream_close' => ['void'],
'streamWrapper::stream_eof' => ['bool'],
'streamWrapper::stream_flush' => ['bool'],
'streamWrapper::stream_lock' => ['bool', 'operation'=>'mode'],
'streamWrapper::stream_metadata' => ['bool', 'path'=>'string', 'option'=>'int', 'value'=>'mixed'],
'streamWrapper::stream_open' => ['bool', 'path'=>'string', 'mode'=>'string', 'options'=>'int', 'opened_path'=>'string'],
'streamWrapper::stream_read' => ['string', 'count'=>'int'],
'streamWrapper::stream_seek' => ['bool', 'offset'=>'int', 'whence'=>'int'],
'streamWrapper::stream_set_option' => ['bool', 'option'=>'int', 'arg1'=>'int', 'arg2'=>'int'],
'streamWrapper::stream_stat' => ['array'],
'streamWrapper::stream_tell' => ['int'],
'streamWrapper::stream_truncate' => ['bool', 'new_size'=>'int'],
'streamWrapper::stream_write' => ['int', 'data'=>'string'],
'streamWrapper::unlink' => ['bool', 'path'=>'string'],
'streamWrapper::url_stat' => ['array', 'path'=>'string', 'flags'=>'int'],
'strftime' => ['string', 'format'=>'string', 'timestamp='=>'int'],
'strip_tags' => ['string', 'str'=>'string', 'allowable_tags='=>'string'],
'stripcslashes' => ['string', 'str'=>'string'],
'stripos' => ['int|false', 'haystack'=>'string', 'needle'=>'string|int', 'offset='=>'int'],
'stripslashes' => ['string', 'str'=>'string'],
'stristr' => ['string|false', 'haystack'=>'string', 'needle'=>'mixed', 'before_needle='=>'bool'],
'strlen' => ['int', 'string'=>'string'],
'strnatcasecmp' => ['int', 's1'=>'string', 's2'=>'string'],
'strnatcmp' => ['int', 's1'=>'string', 's2'=>'string'],
'strncasecmp' => ['int', 'str1'=>'string', 'str2'=>'string', 'len'=>'int'],
'strncmp' => ['int', 'str1'=>'string', 'str2'=>'string', 'len'=>'int'],
'strpbrk' => ['string|false', 'haystack'=>'string', 'char_list'=>'string'],
'strpos' => ['int|false', 'haystack'=>'string', 'needle'=>'string|int', 'offset='=>'int'],
'strptime' => ['array|false', 'datestr'=>'string', 'format'=>'string'],
'strrchr' => ['string|false', 'haystack'=>'string', 'needle'=>'mixed'],
'strrev' => ['string', 'str'=>'string'],
'strripos' => ['int|false', 'haystack'=>'string', 'needle'=>'string|int', 'offset='=>'int'],
'strrpos' => ['int|false', 'haystack'=>'string', 'needle'=>'string|int', 'offset='=>'int'],
'strspn' => ['int', 'str'=>'string', 'mask'=>'string', 'start='=>'int', 'len='=>'int'],
'strstr' => ['string|false', 'haystack'=>'string', 'needle'=>'mixed', 'before_needle='=>'bool'],
'strtok' => ['string|false', 'str'=>'string', 'token'=>'string'],
'strtok\'1' => ['string|false', 'token'=>'string'],
'strtolower' => ['string', 'str'=>'string'],
'strtotime' => ['int|false', 'time'=>'string', 'now='=>'int'],
'strtoupper' => ['string', 'str'=>'string'],
'strtr' => ['string', 'str'=>'string', 'from'=>'string', 'to'=>'string'],
'strtr\'1' => ['string', 'str'=>'string', 'replace_pairs'=>'array'],
'strval' => ['string', 'var'=>'mixed'],
'substr' => ['string', 'str'=>'string', 'start'=>'int', 'length='=>'int'],
'substr_compare' => ['int|false', 'main_str'=>'string', 'str'=>'string', 'offset'=>'int', 'length='=>'int', 'case_sensitivity='=>'bool'],
'substr_count' => ['int', 'haystack'=>'string', 'needle'=>'string', 'offset='=>'int', 'length='=>'int'],
'substr_replace' => ['string|array', 'str'=>'string|array', 'repl'=>'mixed', 'start'=>'mixed', 'length='=>'mixed'],
'suhosin_encrypt_cookie' => ['string', 'name'=>'string', 'value'=>'string'],
'suhosin_get_raw_cookies' => ['array'],
'SVM::__construct' => ['void'],
'svm::crossvalidate' => ['float', 'problem'=>'array', 'number_of_folds'=>'int'],
'SVM::getOptions' => ['array'],
'SVM::setOptions' => ['bool', 'params'=>'array'],
'svm::train' => ['SVMModel', 'problem'=>'array', 'weights='=>'array'],
'SVMModel::__construct' => ['void', 'filename='=>'string'],
'SVMModel::checkProbabilityModel' => ['bool'],
'SVMModel::getLabels' => ['array'],
'SVMModel::getNrClass' => ['int'],
'SVMModel::getSvmType' => ['int'],
'SVMModel::getSvrProbability' => ['float'],
'SVMModel::load' => ['bool', 'filename'=>'string'],
'SVMModel::predict' => ['float', 'data'=>'array'],
'SVMModel::predict_probability' => ['float', 'data'=>'array'],
'SVMModel::save' => ['bool', 'filename'=>'string'],
'svn_add' => ['bool', 'path'=>'string', 'recursive='=>'bool', 'force='=>'bool'],
'svn_auth_get_parameter' => ['string', 'key'=>'string'],
'svn_auth_set_parameter' => ['void', 'key'=>'string', 'value'=>'string'],
'svn_blame' => ['array', 'repository_url'=>'string', 'revision_no='=>'int'],
'svn_cat' => ['string', 'repos_url'=>'string', 'revision_no='=>'int'],
'svn_checkout' => ['bool', 'repos'=>'string', 'targetpath'=>'string', 'revision='=>'int', 'flags='=>'int'],
'svn_cleanup' => ['bool', 'workingdir'=>'string'],
'svn_client_version' => ['string'],
'svn_commit' => ['array', 'log'=>'string', 'targets'=>'array', 'dontrecurse='=>'bool'],
'svn_delete' => ['bool', 'path'=>'string', 'force='=>'bool'],
'svn_diff' => ['array', 'path1'=>'string', 'rev1'=>'int', 'path2'=>'string', 'rev2'=>'int'],
'svn_export' => ['bool', 'frompath'=>'string', 'topath'=>'string', 'working_copy='=>'bool', 'revision_no='=>'int'],
'svn_fs_abort_txn' => ['bool', 'txn'=>'resource'],
'svn_fs_apply_text' => ['resource', 'root'=>'resource', 'path'=>'string'],
'svn_fs_begin_txn2' => ['resource', 'repos'=>'resource', 'rev'=>'int'],
'svn_fs_change_node_prop' => ['bool', 'root'=>'resource', 'path'=>'string', 'name'=>'string', 'value'=>'string'],
'svn_fs_check_path' => ['int', 'fsroot'=>'resource', 'path'=>'string'],
'svn_fs_contents_changed' => ['bool', 'root1'=>'resource', 'path1'=>'string', 'root2'=>'resource', 'path2'=>'string'],
'svn_fs_copy' => ['bool', 'from_root'=>'resource', 'from_path'=>'string', 'to_root'=>'resource', 'to_path'=>'string'],
'svn_fs_delete' => ['bool', 'root'=>'resource', 'path'=>'string'],
'svn_fs_dir_entries' => ['array', 'fsroot'=>'resource', 'path'=>'string'],
'svn_fs_file_contents' => ['resource', 'fsroot'=>'resource', 'path'=>'string'],
'svn_fs_file_length' => ['int', 'fsroot'=>'resource', 'path'=>'string'],
'svn_fs_is_dir' => ['bool', 'root'=>'resource', 'path'=>'string'],
'svn_fs_is_file' => ['bool', 'root'=>'resource', 'path'=>'string'],
'svn_fs_make_dir' => ['bool', 'root'=>'resource', 'path'=>'string'],
'svn_fs_make_file' => ['bool', 'root'=>'resource', 'path'=>'string'],
'svn_fs_node_created_rev' => ['int', 'fsroot'=>'resource', 'path'=>'string'],
'svn_fs_node_prop' => ['string', 'fsroot'=>'resource', 'path'=>'string', 'propname'=>'string'],
'svn_fs_props_changed' => ['bool', 'root1'=>'resource', 'path1'=>'string', 'root2'=>'resource', 'path2'=>'string'],
'svn_fs_revision_prop' => ['string', 'fs'=>'resource', 'revnum'=>'int', 'propname'=>'string'],
'svn_fs_revision_root' => ['resource', 'fs'=>'resource', 'revnum'=>'int'],
'svn_fs_txn_root' => ['resource', 'txn'=>'resource'],
'svn_fs_youngest_rev' => ['int', 'fs'=>'resource'],
'svn_import' => ['bool', 'path'=>'string', 'url'=>'string', 'nonrecursive'=>'bool'],
'svn_log' => ['array', 'repos_url'=>'string', 'start_revision='=>'int', 'end_revision='=>'int', 'limit='=>'int', 'flags='=>'int'],
'svn_ls' => ['array', 'repos_url'=>'string', 'revision_no='=>'int', 'recurse='=>'bool', 'peg='=>'bool'],
'svn_mkdir' => ['bool', 'path'=>'string', 'log_message='=>'string'],
'svn_move' => ['mixed', 'src_path'=>'string', 'dst_path'=>'string', 'force='=>'bool|false'],
'svn_propget' => ['mixed', 'path'=>'string', 'property_name'=>'string', 'recurse='=>'bool|false', 'revision'=>'int'],
'svn_proplist' => ['mixed', 'path'=>'string', 'recurse='=>'bool|false', 'revision'=>'int'],
'svn_repos_create' => ['resource', 'path'=>'string', 'config='=>'array', 'fsconfig='=>'array'],
'svn_repos_fs' => ['resource', 'repos'=>'resource'],
'svn_repos_fs_begin_txn_for_commit' => ['resource', 'repos'=>'resource', 'rev'=>'int', 'author'=>'string', 'log_msg'=>'string'],
'svn_repos_fs_commit_txn' => ['int', 'txn'=>'resource'],
'svn_repos_hotcopy' => ['bool', 'repospath'=>'string', 'destpath'=>'string', 'cleanlogs'=>'bool'],
'svn_repos_open' => ['resource', 'path'=>'string'],
'svn_repos_recover' => ['bool', 'path'=>'string'],
'svn_revert' => ['bool', 'path'=>'string', 'recursive='=>'bool'],
'svn_status' => ['array', 'path'=>'string', 'flags='=>'int'],
'svn_update' => ['int', 'path'=>'string', 'revno='=>'int', 'recurse='=>'bool'],
'swf_actiongeturl' => ['', 'url'=>'string', 'target'=>'string'],
'swf_actiongotoframe' => ['', 'framenumber'=>'int'],
'swf_actiongotolabel' => ['', 'label'=>'string'],
'swf_actionnextframe' => [''],
'swf_actionplay' => [''],
'swf_actionprevframe' => [''],
'swf_actionsettarget' => ['', 'target'=>'string'],
'swf_actionstop' => [''],
'swf_actiontogglequality' => [''],
'swf_actionwaitforframe' => ['', 'framenumber'=>'int', 'skipcount'=>'int'],
'swf_addbuttonrecord' => ['', 'states'=>'int', 'shapeid'=>'int', 'depth'=>'int'],
'swf_addcolor' => ['', 'r'=>'float', 'g'=>'float', 'b'=>'float', 'a'=>'float'],
'swf_closefile' => ['', 'return_file='=>'int'],
'swf_definebitmap' => ['', 'objid'=>'int', 'image_name'=>'string'],
'swf_definefont' => ['', 'fontid'=>'int', 'fontname'=>'string'],
'swf_defineline' => ['', 'objid'=>'int', 'x1'=>'float', 'y1'=>'float', 'x2'=>'float', 'y2'=>'float', 'width'=>'float'],
'swf_definepoly' => ['', 'objid'=>'int', 'coords'=>'array', 'npoints'=>'int', 'width'=>'float'],
'swf_definerect' => ['', 'objid'=>'int', 'x1'=>'float', 'y1'=>'float', 'x2'=>'float', 'y2'=>'float', 'width'=>'float'],
'swf_definetext' => ['', 'objid'=>'int', 'str'=>'string', 'docenter'=>'int'],
'swf_endbutton' => [''],
'swf_enddoaction' => [''],
'swf_endshape' => [''],
'swf_endsymbol' => [''],
'swf_fontsize' => ['', 'size'=>'float'],
'swf_fontslant' => ['', 'slant'=>'float'],
'swf_fonttracking' => ['', 'tracking'=>'float'],
'swf_getbitmapinfo' => ['array', 'bitmapid'=>'int'],
'swf_getfontinfo' => ['array'],
'swf_getframe' => ['int'],
'swf_labelframe' => ['', 'name'=>'string'],
'swf_lookat' => ['', 'view_x'=>'float', 'view_y'=>'float', 'view_z'=>'float', 'reference_x'=>'float', 'reference_y'=>'float', 'reference_z'=>'float', 'twist'=>'float'],
'swf_modifyobject' => ['', 'depth'=>'int', 'how'=>'int'],
'swf_mulcolor' => ['', 'r'=>'float', 'g'=>'float', 'b'=>'float', 'a'=>'float'],
'swf_nextid' => ['int'],
'swf_oncondition' => ['', 'transition'=>'int'],
'swf_openfile' => ['', 'filename'=>'string', 'width'=>'float', 'height'=>'float', 'framerate'=>'float', 'r'=>'float', 'g'=>'float', 'b'=>'float'],
'swf_ortho' => ['', 'xmin'=>'float', 'xmax'=>'float', 'ymin'=>'float', 'ymax'=>'float', 'zmin'=>'float', 'zmax'=>'float'],
'swf_ortho2' => ['', 'xmin'=>'float', 'xmax'=>'float', 'ymin'=>'float', 'ymax'=>'float'],
'swf_perspective' => ['', 'fovy'=>'float', 'aspect'=>'float', 'near'=>'float', 'far'=>'float'],
'swf_placeobject' => ['', 'objid'=>'int', 'depth'=>'int'],
'swf_polarview' => ['', 'dist'=>'float', 'azimuth'=>'float', 'incidence'=>'float', 'twist'=>'float'],
'swf_popmatrix' => [''],
'swf_posround' => ['', 'round'=>'int'],
'swf_pushmatrix' => [''],
'swf_removeobject' => ['', 'depth'=>'int'],
'swf_rotate' => ['', 'angle'=>'float', 'axis'=>'string'],
'swf_scale' => ['', 'x'=>'float', 'y'=>'float', 'z'=>'float'],
'swf_setfont' => ['', 'fontid'=>'int'],
'swf_setframe' => ['', 'framenumber'=>'int'],
'swf_shapearc' => ['', 'x'=>'float', 'y'=>'float', 'r'=>'float', 'ang1'=>'float', 'ang2'=>'float'],
'swf_shapecurveto' => ['', 'x1'=>'float', 'y1'=>'float', 'x2'=>'float', 'y2'=>'float'],
'swf_shapecurveto3' => ['', 'x1'=>'float', 'y1'=>'float', 'x2'=>'float', 'y2'=>'float', 'x3'=>'float', 'y3'=>'float'],
'swf_shapefillbitmapclip' => ['', 'bitmapid'=>'int'],
'swf_shapefillbitmaptile' => ['', 'bitmapid'=>'int'],
'swf_shapefilloff' => [''],
'swf_shapefillsolid' => ['', 'r'=>'float', 'g'=>'float', 'b'=>'float', 'a'=>'float'],
'swf_shapelinesolid' => ['', 'r'=>'float', 'g'=>'float', 'b'=>'float', 'a'=>'float', 'width'=>'float'],
'swf_shapelineto' => ['', 'x'=>'float', 'y'=>'float'],
'swf_shapemoveto' => ['', 'x'=>'float', 'y'=>'float'],
'swf_showframe' => [''],
'swf_startbutton' => ['', 'objid'=>'int', 'type'=>'int'],
'swf_startdoaction' => [''],
'swf_startshape' => ['', 'objid'=>'int'],
'swf_startsymbol' => ['', 'objid'=>'int'],
'swf_textwidth' => ['float', 'str'=>'string'],
'swf_translate' => ['', 'x'=>'float', 'y'=>'float', 'z'=>'float'],
'swf_viewport' => ['', 'xmin'=>'float', 'xmax'=>'float', 'ymin'=>'float', 'ymax'=>'float'],
'SWFAction::__construct' => ['void', 'script'=>'string'],
'SWFBitmap::__construct' => ['void', 'file'=>'', 'alphafile='=>''],
'SWFBitmap::getHeight' => ['float'],
'SWFBitmap::getWidth' => ['float'],
'SWFButton::__construct' => ['void'],
'SWFButton::addAction' => ['void', 'action'=>'swfaction', 'flags'=>'int'],
'SWFButton::addASound' => ['SWFSoundInstance', 'sound'=>'swfsound', 'flags'=>'int'],
'SWFButton::addShape' => ['void', 'shape'=>'swfshape', 'flags'=>'int'],
'SWFButton::setAction' => ['void', 'action'=>'swfaction'],
'SWFButton::setDown' => ['void', 'shape'=>'swfshape'],
'SWFButton::setHit' => ['void', 'shape'=>'swfshape'],
'SWFButton::setMenu' => ['void', 'flag'=>'int'],
'SWFButton::setOver' => ['void', 'shape'=>'swfshape'],
'SWFButton::setUp' => ['void', 'shape'=>'swfshape'],
'SWFDisplayItem::addAction' => ['void', 'action'=>'swfaction', 'flags'=>'int'],
'SWFDisplayItem::addColor' => ['void', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'a='=>'int'],
'SWFDisplayItem::endMask' => ['void'],
'SWFDisplayItem::getRot' => ['float'],
'SWFDisplayItem::getX' => ['float'],
'SWFDisplayItem::getXScale' => ['float'],
'SWFDisplayItem::getXSkew' => ['float'],
'SWFDisplayItem::getY' => ['float'],
'SWFDisplayItem::getYScale' => ['float'],
'SWFDisplayItem::getYSkew' => ['float'],
'SWFDisplayItem::move' => ['void', 'dx'=>'float', 'dy'=>'float'],
'SWFDisplayItem::moveTo' => ['void', 'x'=>'float', 'y'=>'float'],
'SWFDisplayItem::multColor' => ['void', 'red'=>'float', 'green'=>'float', 'blue'=>'float', 'a='=>'float'],
'SWFDisplayItem::remove' => ['void'],
'SWFDisplayItem::rotate' => ['void', 'angle'=>'float'],
'SWFDisplayItem::rotateTo' => ['void', 'angle'=>'float'],
'SWFDisplayItem::scale' => ['void', 'dx'=>'float', 'dy'=>'float'],
'SWFDisplayItem::scaleTo' => ['void', 'x'=>'float', 'y='=>'float'],
'SWFDisplayItem::setDepth' => ['void', 'depth'=>'int'],
'SWFDisplayItem::setMaskLevel' => ['void', 'level'=>'int'],
'SWFDisplayItem::setMatrix' => ['void', 'a'=>'float', 'b'=>'float', 'c'=>'float', 'd'=>'float', 'x'=>'float', 'y'=>'float'],
'SWFDisplayItem::setName' => ['void', 'name'=>'string'],
'SWFDisplayItem::setRatio' => ['void', 'ratio'=>'float'],
'SWFDisplayItem::skewX' => ['void', 'ddegrees'=>'float'],
'SWFDisplayItem::skewXTo' => ['void', 'degrees'=>'float'],
'SWFDisplayItem::skewY' => ['void', 'ddegrees'=>'float'],
'SWFDisplayItem::skewYTo' => ['void', 'degrees'=>'float'],
'SWFFill::moveTo' => ['void', 'x'=>'float', 'y'=>'float'],
'SWFFill::rotateTo' => ['void', 'angle'=>'float'],
'SWFFill::scaleTo' => ['void', 'x'=>'float', 'y='=>'float'],
'SWFFill::skewXTo' => ['void', 'x'=>'float'],
'SWFFill::skewYTo' => ['void', 'y'=>'float'],
'SWFFont::__construct' => ['void', 'filename'=>'string'],
'SWFFont::getAscent' => ['float'],
'SWFFont::getDescent' => ['float'],
'SWFFont::getLeading' => ['float'],
'SWFFont::getShape' => ['string', 'code'=>'int'],
'SWFFont::getUTF8Width' => ['float', 'string'=>'string'],
'SWFFont::getWidth' => ['float', 'string'=>'string'],
'SWFFontChar::addChars' => ['void', 'char'=>'string'],
'SWFFontChar::addUTF8Chars' => ['void', 'char'=>'string'],
'SWFGradient::__construct' => ['void'],
'SWFGradient::addEntry' => ['void', 'ratio'=>'float', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'alpha='=>'int'],
'SWFMorph::__construct' => ['void'],
'SWFMorph::getShape1' => ['SWFShape'],
'SWFMorph::getShape2' => ['SWFShape'],
'SWFMovie::__construct' => ['void', 'version='=>'int'],
'SWFMovie::add' => ['mixed', 'instance'=>'object'],
'SWFMovie::addExport' => ['void', 'char'=>'swfcharacter', 'name'=>'string'],
'SWFMovie::addFont' => ['mixed', 'font'=>'swffont'],
'SWFMovie::importChar' => ['SWFSprite', 'libswf'=>'string', 'name'=>'string'],
'SWFMovie::importFont' => ['SWFFontChar', 'libswf'=>'string', 'name'=>'string'],
'SWFMovie::labelFrame' => ['void', 'label'=>'string'],
'SWFMovie::nextFrame' => ['void'],
'SWFMovie::output' => ['int', 'compression='=>'int'],
'SWFMovie::remove' => ['void', 'instance'=>'object'],
'SWFMovie::save' => ['int', 'filename'=>'string', 'compression='=>'int'],
'SWFMovie::saveToFile' => ['int', 'x'=>'resource', 'compression='=>'int'],
'SWFMovie::setbackground' => ['void', 'red'=>'int', 'green'=>'int', 'blue'=>'int'],
'SWFMovie::setDimension' => ['void', 'width'=>'float', 'height'=>'float'],
'SWFMovie::setFrames' => ['void', 'number'=>'int'],
'SWFMovie::setRate' => ['void', 'rate'=>'float'],
'SWFMovie::startSound' => ['SWFSoundInstance', 'sound'=>'swfsound'],
'SWFMovie::stopSound' => ['void', 'sound'=>'swfsound'],
'SWFMovie::streamMP3' => ['int', 'mp3file'=>'mixed', 'skip='=>'float'],
'SWFMovie::writeExports' => ['void'],
'SWFPrebuiltClip::__construct' => ['void', 'file'=>''],
'SWFShape::__construct' => ['void'],
'SWFShape::addFill' => ['SWFFill', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'alpha='=>'int', 'bitmap='=>'swfbitmap', 'flags='=>'int', 'gradient='=>'swfgradient'],
'SWFShape::addFill\'1' => ['SWFFill', 'bitmap'=>'SWFBitmap', 'flags='=>'int'],
'SWFShape::addFill\'2' => ['SWFFill', 'gradient'=>'SWFGradient', 'flags='=>'int'],
'SWFShape::drawArc' => ['void', 'r'=>'float', 'startangle'=>'float', 'endangle'=>'float'],
'SWFShape::drawCircle' => ['void', 'r'=>'float'],
'SWFShape::drawCubic' => ['int', 'bx'=>'float', 'by'=>'float', 'cx'=>'float', 'cy'=>'float', 'dx'=>'float', 'dy'=>'float'],
'SWFShape::drawCubicTo' => ['int', 'bx'=>'float', 'by'=>'float', 'cx'=>'float', 'cy'=>'float', 'dx'=>'float', 'dy'=>'float'],
'SWFShape::drawCurve' => ['int', 'controldx'=>'float', 'controldy'=>'float', 'anchordx'=>'float', 'anchordy'=>'float', 'targetdx='=>'float', 'targetdy='=>'float'],
'SWFShape::drawCurveTo' => ['int', 'controlx'=>'float', 'controly'=>'float', 'anchorx'=>'float', 'anchory'=>'float', 'targetx='=>'float', 'targety='=>'float'],
'SWFShape::drawGlyph' => ['void', 'font'=>'swffont', 'character'=>'string', 'size='=>'int'],
'SWFShape::drawLine' => ['void', 'dx'=>'float', 'dy'=>'float'],
'SWFShape::drawLineTo' => ['void', 'x'=>'float', 'y'=>'float'],
'SWFShape::movePen' => ['void', 'dx'=>'float', 'dy'=>'float'],
'SWFShape::movePenTo' => ['void', 'x'=>'float', 'y'=>'float'],
'SWFShape::setLeftFill' => ['', 'fill'=>'swfgradient', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'a='=>'int'],
'SWFShape::setLine' => ['', 'shape'=>'swfshape', 'width'=>'int', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'a='=>'int'],
'SWFShape::setRightFill' => ['', 'fill'=>'swfgradient', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'a='=>'int'],
'SWFSound' => ['SWFSound', 'filename'=>'string', 'flags='=>'int'],
'SWFSound::__construct' => ['void', 'filename'=>'string', 'flags='=>'int'],
'SWFSoundInstance::loopCount' => ['void', 'point'=>'int'],
'SWFSoundInstance::loopInPoint' => ['void', 'point'=>'int'],
'SWFSoundInstance::loopOutPoint' => ['void', 'point'=>'int'],
'SWFSoundInstance::noMultiple' => ['void'],
'SWFSprite::__construct' => ['void'],
'SWFSprite::add' => ['void', 'object'=>'object'],
'SWFSprite::labelFrame' => ['void', 'label'=>'string'],
'SWFSprite::nextFrame' => ['void'],
'SWFSprite::remove' => ['void', 'object'=>'object'],
'SWFSprite::setFrames' => ['void', 'number'=>'int'],
'SWFSprite::startSound' => ['SWFSoundInstance', 'sount'=>'swfsound'],
'SWFSprite::stopSound' => ['void', 'sount'=>'swfsound'],
'SWFText::__construct' => ['void'],
'SWFText::addString' => ['void', 'string'=>'string'],
'SWFText::addUTF8String' => ['void', 'text'=>'string'],
'SWFText::getAscent' => ['float'],
'SWFText::getDescent' => ['float'],
'SWFText::getLeading' => ['float'],
'SWFText::getUTF8Width' => ['float', 'string'=>'string'],
'SWFText::getWidth' => ['float', 'string'=>'string'],
'SWFText::moveTo' => ['void', 'x'=>'float', 'y'=>'float'],
'SWFText::setColor' => ['void', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'a='=>'int'],
'SWFText::setFont' => ['void', 'font'=>'swffont'],
'SWFText::setHeight' => ['void', 'height'=>'float'],
'SWFText::setSpacing' => ['void', 'spacing'=>'float'],
'SWFTextField::__construct' => ['void', 'flags='=>'int'],
'SWFTextField::addChars' => ['void', 'chars'=>'string'],
'SWFTextField::addString' => ['void', 'string'=>'string'],
'SWFTextField::align' => ['void', 'alignement'=>'int'],
'SWFTextField::setBounds' => ['void', 'width'=>'float', 'height'=>'float'],
'SWFTextField::setColor' => ['void', 'red'=>'int', 'green'=>'int', 'blue'=>'int', 'a='=>'int'],
'SWFTextField::setFont' => ['void', 'font'=>'swffont'],
'SWFTextField::setHeight' => ['void', 'height'=>'float'],
'SWFTextField::setIndentation' => ['void', 'width'=>'float'],
'SWFTextField::setLeftMargin' => ['void', 'width'=>'float'],
'SWFTextField::setLineSpacing' => ['void', 'height'=>'float'],
'SWFTextField::setMargins' => ['void', 'left'=>'float', 'right'=>'float'],
'SWFTextField::setName' => ['void', 'name'=>'string'],
'SWFTextField::setPadding' => ['void', 'padding'=>'float'],
'SWFTextField::setRightMargin' => ['void', 'width'=>'float'],
'SWFVideoStream::__construct' => ['void', 'file='=>'string'],
'SWFVideoStream::getNumFrames' => ['int'],
'SWFVideoStream::setDimension' => ['void', 'x'=>'int', 'y'=>'int'],
'Swish::__construct' => ['void', 'index_names'=>'string'],
'Swish::getMetaList' => ['array', 'index_name'=>'string'],
'Swish::getPropertyList' => ['array', 'index_name'=>'string'],
'Swish::prepare' => ['object', 'query='=>'string'],
'Swish::query' => ['object', 'query'=>'string'],
'SwishResult::getMetaList' => ['array'],
'SwishResult::stem' => ['array', 'word'=>'string'],
'SwishResults::getParsedWords' => ['array', 'index_name'=>'string'],
'SwishResults::getRemovedStopwords' => ['array', 'index_name'=>'string'],
'SwishResults::nextResult' => ['object'],
'SwishResults::seekResult' => ['int', 'position'=>'int'],
'SwishSearch::execute' => ['object', 'query='=>'string'],
'SwishSearch::resetLimit' => [''],
'SwishSearch::setLimit' => ['', 'property'=>'string', 'low'=>'string', 'high'=>'string'],
'SwishSearch::setPhraseDelimiter' => ['', 'delimiter'=>'string'],
'SwishSearch::setSort' => ['', 'sort'=>'string'],
'SwishSearch::setStructure' => ['', 'structure'=>'int'],
'swoole_async_dns_lookup' => ['bool', 'hostname'=>'string', 'callback'=>'callable'],
'swoole_async_read' => ['bool', 'filename'=>'string', 'callback'=>'callable', 'chunk_size='=>'int', 'offset='=>'int'],
'swoole_async_readfile' => ['bool', 'filename'=>'string', 'callback'=>'string'],
'swoole_async_set' => ['void', 'settings'=>'array'],
'swoole_async_write' => ['bool', 'filename'=>'string', 'content'=>'string', 'offset='=>'int', 'callback='=>'callable'],
'swoole_async_writefile' => ['bool', 'filename'=>'string', 'content'=>'string', 'callback='=>'string', 'flags='=>'int'],
'swoole_client_select' => ['int', 'read_array'=>'array', 'write_array'=>'array', 'error_array'=>'array', 'timeout='=>'float'],
'swoole_cpu_num' => ['int'],
'swoole_errno' => ['int'],
'swoole_event_add' => ['int', 'fd'=>'int', 'read_callback='=>'callable', 'write_callback='=>'callable', 'events='=>'int'],
'swoole_event_defer' => ['bool', 'callback'=>'callable'],
'swoole_event_del' => ['bool', 'fd'=>'int'],
'swoole_event_exit' => ['void'],
'swoole_event_set' => ['bool', 'fd'=>'int', 'read_callback='=>'callable', 'write_callback='=>'callable', 'events='=>'int'],
'swoole_event_wait' => ['void'],
'swoole_event_write' => ['bool', 'fd'=>'int', 'data'=>'string'],
'swoole_get_local_ip' => ['array'],
'swoole_last_error' => ['int'],
'swoole_load_module' => ['mixed', 'filename'=>'string'],
'swoole_select' => ['int', 'read_array'=>'array', 'write_array'=>'array', 'error_array'=>'array', 'timeout='=>'float'],
'swoole_set_process_name' => ['void', 'process_name'=>'string', 'size='=>'int'],
'swoole_strerror' => ['string', 'errno'=>'int', 'error_type='=>'int'],
'swoole_timer_after' => ['int', 'ms'=>'int', 'callback'=>'callable', 'param='=>'mixed'],
'swoole_timer_exists' => ['bool', 'timer_id'=>'int'],
'swoole_timer_tick' => ['int', 'ms'=>'int', 'callback'=>'callable', 'param='=>'mixed'],
'swoole_version' => ['string'],
'sybase_affected_rows' => ['int', 'link_identifier='=>'resource'],
'sybase_close' => ['bool', 'link_identifier='=>'resource'],
'sybase_connect' => ['resource', 'servername='=>'string', 'username='=>'string', 'password='=>'string', 'charset='=>'string', 'appname='=>'string', 'new='=>'bool'],
'sybase_data_seek' => ['bool', 'result_identifier'=>'resource', 'row_number'=>'int'],
'sybase_deadlock_retry_count' => ['void', 'retry_count'=>'int'],
'sybase_fetch_array' => ['array', 'result'=>'resource'],
'sybase_fetch_assoc' => ['array', 'result'=>'resource'],
'sybase_fetch_field' => ['object', 'result'=>'resource', 'field_offset='=>'int'],
'sybase_fetch_object' => ['object', 'result'=>'resource', 'object='=>'mixed'],
'sybase_fetch_row' => ['array', 'result'=>'resource'],
'sybase_field_seek' => ['bool', 'result'=>'resource', 'field_offset'=>'int'],
'sybase_free_result' => ['bool', 'result'=>'resource'],
'sybase_get_last_message' => ['string'],
'sybase_min_client_severity' => ['void', 'severity'=>'int'],
'sybase_min_error_severity' => ['void', 'severity'=>'int'],
'sybase_min_message_severity' => ['void', 'severity'=>'int'],
'sybase_min_server_severity' => ['void', 'severity'=>'int'],
'sybase_num_fields' => ['int', 'result'=>'resource'],
'sybase_num_rows' => ['int', 'result'=>'resource'],
'sybase_pconnect' => ['resource', 'servername='=>'string', 'username='=>'string', 'password='=>'string', 'charset='=>'string', 'appname='=>'string'],
'sybase_query' => ['mixed', 'query'=>'string', 'link_identifier='=>'resource'],
'sybase_result' => ['string', 'result'=>'resource', 'row'=>'int', 'field'=>'mixed'],
'sybase_select_db' => ['bool', 'database_name'=>'string', 'link_identifier='=>'resource'],
'sybase_set_message_handler' => ['bool', 'handler'=>'callable', 'connection='=>'resource'],
'sybase_unbuffered_query' => ['resource', 'query'=>'string', 'link_identifier'=>'resource', 'store_result='=>'bool'],
'symbolObj::__construct' => ['void', 'map'=>'MapObj', 'symbolname'=>'string'],
'symbolObj::free' => ['void'],
'symbolObj::getPatternArray' => ['array'],
'symbolObj::getPointsArray' => ['array'],
'symbolObj::ms_newSymbolObj' => ['int', 'map'=>'MapObj', 'symbolname'=>'string'],
'symbolObj::set' => ['int', 'property_name'=>'string', 'new_value'=>''],
'symbolObj::setImagePath' => ['int', 'filename'=>'string'],
'symbolObj::setPattern' => ['int', 'int'=>'array'],
'symbolObj::setPoints' => ['int', 'double'=>'array'],
'symlink' => ['bool', 'target'=>'string', 'link'=>'string'],
'SyncEvent::__construct' => ['void', 'name='=>'string', 'manual='=>'bool'],
'SyncEvent::fire' => ['bool'],
'SyncEvent::reset' => ['bool'],
'SyncEvent::wait' => ['bool', 'wait='=>'int'],
'SyncMutex::__construct' => ['void', 'name='=>'string'],
'SyncMutex::lock' => ['bool', 'wait='=>'int'],
'SyncMutex::unlock' => ['bool', 'all='=>'bool'],
'SyncReaderWriter::__construct' => ['void', 'name='=>'string', 'autounlock='=>'bool'],
'SyncReaderWriter::readlock' => ['bool', 'wait='=>'int'],
'SyncReaderWriter::readunlock' => ['bool'],
'SyncReaderWriter::writelock' => ['bool', 'wait='=>'int'],
'SyncReaderWriter::writeunlock' => ['bool'],
'SyncSemaphore::__construct' => ['void', 'name='=>'string', 'initialval='=>'int', 'autounlock='=>'bool'],
'SyncSemaphore::lock' => ['bool', 'wait='=>'int'],
'SyncSemaphore::unlock' => ['bool', '&w_prevcount='=>'int'],
'SyncSharedMemory::__construct' => ['void', 'name'=>'string', 'size'=>'int'],
'SyncSharedMemory::first' => ['bool'],
'SyncSharedMemory::read' => ['', 'start='=>'int', 'length='=>'int'],
'SyncSharedMemory::size' => ['bool'],
'SyncSharedMemory::write' => ['', 'string='=>'string', 'start='=>'int'],
'sys_get_temp_dir' => ['string'],
'sys_getloadavg' => ['array'],
'syslog' => ['bool', 'priority'=>'int', 'message'=>'string'],
'system' => ['string', 'command'=>'string', '&w_return_value='=>'int'],
'taint' => ['bool', '&rw_string'=>'string', '&...w_other_strings='=>'string'],
'tan' => ['float', 'number'=>'float'],
'tanh' => ['float', 'number'=>'float'],
'tcpwrap_check' => ['bool', 'daemon'=>'string', 'address'=>'string', 'user='=>'string', 'nodns='=>'bool'],
'tempnam' => ['string|false', 'dir'=>'string', 'prefix'=>'string'],
'textdomain' => ['string', 'domain'=>'string'],
'Thread::__construct' => ['void'],
'Thread::chunk' => ['array', 'size'=>'int', 'preserve'=>'bool'],
'Thread::count' => ['int'],
'Thread::detach' => ['void'],
'Thread::getCreatorId' => ['int'],
'Thread::getCurrentThread' => ['Thread'],
'Thread::getCurrentThreadId' => ['int'],
'Thread::getTerminationInfo' => ['array'],
'Thread::getThreadId' => ['int'],
'Thread::globally' => ['mixed'],
'Thread::isJoined' => ['bool'],
'Thread::isRunning' => ['bool'],
'Thread::isStarted' => ['bool'],
'Thread::isTerminated' => ['bool'],
'Thread::isWaiting' => ['bool'],
'Thread::join' => ['bool'],
'Thread::kill' => ['void'],
'Thread::lock' => ['bool'],
'Thread::merge' => ['bool', 'from'=>'', 'overwrite='=>'mixed'],
'Thread::notify' => ['bool'],
'Thread::offsetExists' => ['bool', 'offset'=>'mixed'],
'Thread::offsetGet' => ['mixed', 'offset'=>'mixed'],
'Thread::offsetSet' => ['void', 'offset'=>'mixed', 'value'=>'mixed'],
'Thread::offsetUnset' => ['void', 'offset'=>'mixed'],
'Thread::pop' => ['bool'],
'Thread::run' => ['void'],
'Thread::shift' => ['bool'],
'Thread::start' => ['bool', 'options='=>'int'],
'Thread::synchronized' => ['mixed', 'block'=>'Closure', '_='=>'mixed'],
'Thread::unlock' => ['bool'],
'Thread::wait' => ['bool', 'timeout='=>'int'],
'Threaded::__construct' => ['void'],
'Threaded::chunk' => ['array', 'size'=>'int', 'preserve'=>'bool'],
'Threaded::count' => ['int'],
'Threaded::extend' => ['bool', 'class'=>'string'],
'Threaded::from' => ['Threaded', 'run'=>'Closure', 'construct='=>'Closure', 'args='=>'array'],
'Threaded::getTerminationInfo' => ['array'],
'Threaded::isRunning' => ['bool'],
'Threaded::isTerminated' => ['bool'],
'Threaded::isWaiting' => ['bool'],
'Threaded::lock' => ['bool'],
'Threaded::merge' => ['bool', 'from'=>'mixed', 'overwrite='=>'bool'],
'Threaded::notify' => ['bool'],
'Threaded::notifyOne' => ['bool'],
'Threaded::offsetExists' => ['bool', 'offset'=>'mixed'],
'Threaded::offsetGet' => ['mixed', 'offset'=>'mixed'],
'Threaded::offsetSet' => ['void', 'offset'=>'mixed', 'value'=>'mixed'],
'Threaded::offsetUnset' => ['void', 'offset'=>'mixed'],
'Threaded::pop' => ['bool'],
'Threaded::run' => ['void'],
'Threaded::shift' => ['mixed'],
'Threaded::synchronized' => ['mixed', 'block'=>'Closure', '...args='=>'mixed'],
'Threaded::unlock' => ['bool'],
'Threaded::wait' => ['bool', 'timeout='=>'int'],
'Throwable::__toString' => ['string'],
'Throwable::getCode' => ['mixed'],
'Throwable::getFile' => ['string'],
'Throwable::getLine' => ['int'],
'Throwable::getMessage' => ['string'],
'Throwable::getPrevious' => ['Throwable|null'],
'Throwable::getTrace' => ['array'],
'Throwable::getTraceAsString' => ['string'],
'tidy::__construct' => ['void', 'filename='=>'string', 'config='=>'', 'encoding='=>'string', 'use_include_path='=>'bool'],
'tidy::body' => ['tidyNode'],
'tidy::cleanRepair' => ['bool'],
'tidy::diagnose' => ['bool'],
'tidy::getConfig' => ['array'],
'tidy::getHtmlVer' => ['int'],
'tidy::getOpt' => ['', 'option'=>'string'],
'tidy::getOptDoc' => ['string', 'optname'=>'string'],
'tidy::getRelease' => ['string'],
'tidy::getStatus' => ['int'],
'tidy::head' => ['tidyNode'],
'tidy::html' => ['tidyNode'],
'tidy::htmlver' => ['int'],
'tidy::isXhtml' => ['bool'],
'tidy::isXml' => ['bool'],
'tidy::parseFile' => ['bool', 'filename'=>'string', 'config='=>'', 'encoding='=>'string', 'use_include_path='=>'bool'],
'tidy::parseString' => ['bool', 'input'=>'string', 'config='=>'', 'encoding='=>'string'],
'tidy::repairFile' => ['string', 'filename'=>'string', 'config='=>'', 'encoding='=>'string', 'use_include_path='=>'bool'],
'tidy::repairString' => ['string', 'data'=>'string', 'config='=>'', 'encoding='=>'string'],
'tidy::root' => ['tidyNode'],
'tidy_access_count' => ['int', 'obj'=>'tidy'],
'tidy_clean_repair' => ['bool', 'obj'=>'tidy'],
'tidy_config_count' => ['int', 'obj'=>'tidy'],
'tidy_diagnose' => ['bool', 'obj'=>'tidy'],
'tidy_error_count' => ['int', 'obj'=>'tidy'],
'tidy_get_body' => ['tidyNode', 'obj'=>'tidy'],
'tidy_get_config' => ['array', 'obj'=>'tidy'],
'tidy_get_error_buffer' => ['string', 'obj'=>'tidy'],
'tidy_get_head' => ['tidyNode', 'obj'=>'tidy'],
'tidy_get_html' => ['tidyNode', 'obj'=>'tidy'],
'tidy_get_html_ver' => ['int', 'obj'=>'tidy'],
'tidy_get_opt_doc' => ['string', 'obj'=>'tidy', 'optname'=>'string'],
'tidy_get_output' => ['string', 'obj'=>'tidy'],
'tidy_get_release' => ['string'],
'tidy_get_root' => ['tidyNode', 'obj'=>'tidy'],
'tidy_get_status' => ['int', 'obj'=>'tidy'],
'tidy_getopt' => ['', 'option'=>'string', 'obj'=>'tidy'],
'tidy_is_xhtml' => ['bool', 'obj'=>'tidy'],
'tidy_is_xml' => ['bool', 'obj'=>'tidy'],
'tidy_load_config' => ['void', 'filename'=>'string', 'encoding'=>'string'],
'tidy_parse_file' => ['tidy', 'file'=>'string', 'config_options='=>'', 'encoding='=>'string', 'use_include_path='=>'bool'],
'tidy_parse_string' => ['tidy', 'input'=>'string', 'config_options='=>'', 'encoding='=>'string'],
'tidy_repair_file' => ['string', 'filename'=>'string', 'config_file='=>'', 'encoding='=>'string', 'use_include_path='=>'bool'],
'tidy_repair_string' => ['string', 'data'=>'string', 'config_file='=>'', 'encoding='=>'string'],
'tidy_reset_config' => ['bool'],
'tidy_save_config' => ['bool', 'filename'=>'string'],
'tidy_set_encoding' => ['bool', 'encoding'=>'string'],
'tidy_setopt' => ['bool', 'option'=>'string', 'value'=>'mixed'],
'tidy_warning_count' => ['int', 'obj'=>'tidy'],
'tidyNode::__construct' => ['void'],
'tidyNode::getParent' => ['tidyNode'],
'tidyNode::hasChildren' => ['bool'],
'tidyNode::hasSiblings' => ['bool'],
'tidyNode::isAsp' => ['bool'],
'tidyNode::isComment' => ['bool'],
'tidyNode::isHtml' => ['bool'],
'tidyNode::isJste' => ['bool'],
'tidyNode::isPhp' => ['bool'],
'tidyNode::isText' => ['bool'],
'time' => ['int'],
'time_nanosleep' => ['array|bool', 'seconds'=>'int', 'nanoseconds'=>'int'],
'time_sleep_until' => ['bool', 'timestamp'=>'float'],
'timezone_abbreviations_list' => ['array'],
'timezone_identifiers_list' => ['array', 'what='=>'int', 'country='=>'?string'],
'timezone_location_get' => ['array|false', 'object'=>'DateTimeZone'],
'timezone_name_from_abbr' => ['string|false', 'abbr'=>'string', 'gmtoffset='=>'int', 'isdst='=>'int'],
'timezone_name_get' => ['string', 'object'=>'DateTimeZone'],
'timezone_offset_get' => ['int', 'object'=>'DateTimeZone', 'datetime'=>'DateTime'],
'timezone_open' => ['DateTimeZone', 'timezone'=>'string'],
'timezone_transitions_get' => ['array|false', 'object'=>'DateTimeZone', 'timestamp_begin='=>'int', 'timestamp_end='=>'int'],
'timezone_version_get' => ['string'],
'tmpfile' => ['resource'],
'token_get_all' => ['array', 'source'=>'string', 'flags='=>'int'],
'token_name' => ['string', 'type'=>'int'],
'TokyoTyrant::__construct' => ['void', 'host='=>'string', 'port='=>'int', 'options='=>'array'],
'TokyoTyrant::add' => ['int|float', 'key'=>'string', 'increment'=>'float', 'type='=>'int'],
'TokyoTyrant::connect' => ['TokyoTyrant', 'host'=>'string', 'port='=>'int', 'options='=>'array'],
'TokyoTyrant::connectUri' => ['TokyoTyrant', 'uri'=>'string'],
'TokyoTyrant::copy' => ['TokyoTyrant', 'path'=>'string'],
'TokyoTyrant::ext' => ['string', 'name'=>'string', 'options'=>'int', 'key'=>'string', 'value'=>'string'],
'TokyoTyrant::fwmKeys' => ['array', 'prefix'=>'string', 'max_recs'=>'int'],
'TokyoTyrant::get' => ['array', 'keys'=>'mixed'],
'TokyoTyrant::getIterator' => ['TokyoTyrantIterator'],
'TokyoTyrant::num' => ['int'],
'TokyoTyrant::out' => ['string', 'keys'=>'mixed'],
'TokyoTyrant::put' => ['TokyoTyrant', 'keys'=>'mixed', 'value='=>'string'],
'TokyoTyrant::putCat' => ['TokyoTyrant', 'keys'=>'mixed', 'value='=>'string'],
'TokyoTyrant::putKeep' => ['TokyoTyrant', 'keys'=>'mixed', 'value='=>'string'],
'TokyoTyrant::putNr' => ['TokyoTyrant', 'keys'=>'mixed', 'value='=>'string'],
'TokyoTyrant::putShl' => ['mixed', 'key'=>'string', 'value'=>'string', 'width'=>'int'],
'TokyoTyrant::restore' => ['mixed', 'log_dir'=>'string', 'timestamp'=>'int', 'check_consistency='=>'bool'],
'TokyoTyrant::setMaster' => ['mixed', 'host'=>'string', 'port'=>'int', 'timestamp'=>'int', 'check_consistency='=>'bool'],
'TokyoTyrant::size' => ['int', 'key'=>'string'],
'TokyoTyrant::stat' => ['array'],
'TokyoTyrant::sync' => ['mixed'],
'TokyoTyrant::tune' => ['TokyoTyrant', 'timeout'=>'float', 'options='=>'int'],
'TokyoTyrant::vanish' => ['mixed'],
'TokyoTyrantIterator::__construct' => ['void', 'object'=>'mixed'],
'TokyoTyrantIterator::current' => ['mixed'],
'TokyoTyrantIterator::key' => ['mixed'],
'TokyoTyrantIterator::next' => ['mixed'],
'TokyoTyrantIterator::rewind' => ['void'],
'TokyoTyrantIterator::valid' => ['bool'],
'TokyoTyrantQuery::__construct' => ['void', 'table'=>'TokyoTyrantTable'],
'TokyoTyrantQuery::addCond' => ['mixed', 'name'=>'string', 'op'=>'int', 'expr'=>'string'],
'TokyoTyrantQuery::count' => ['int'],
'TokyoTyrantQuery::current' => ['array'],
'TokyoTyrantQuery::hint' => ['string'],
'TokyoTyrantQuery::key' => ['string'],
'TokyoTyrantQuery::metaSearch' => ['array', 'queries'=>'array', 'type'=>'int'],
'TokyoTyrantQuery::next' => ['array'],
'TokyoTyrantQuery::out' => ['TokyoTyrantQuery'],
'TokyoTyrantQuery::rewind' => ['bool'],
'TokyoTyrantQuery::search' => ['array'],
'TokyoTyrantQuery::setLimit' => ['mixed', 'max='=>'int', 'skip='=>'int'],
'TokyoTyrantQuery::setOrder' => ['mixed', 'name'=>'string', 'type'=>'int'],
'TokyoTyrantQuery::valid' => ['bool'],
'TokyoTyrantTable::add' => ['void', 'key'=>'string', 'increment'=>'mixed', 'type='=>'string'],
'TokyoTyrantTable::genUid' => ['int'],
'TokyoTyrantTable::get' => ['array', 'keys'=>'mixed'],
'TokyoTyrantTable::getIterator' => ['TokyoTyrantIterator'],
'TokyoTyrantTable::getQuery' => ['TokyoTyrantQuery'],
'TokyoTyrantTable::out' => ['void', 'keys'=>'mixed'],
'TokyoTyrantTable::put' => ['int', 'key'=>'string', 'columns'=>'array'],
'TokyoTyrantTable::putCat' => ['void', 'key'=>'string', 'columns'=>'array'],
'TokyoTyrantTable::putKeep' => ['void', 'key'=>'string', 'columns'=>'array'],
'TokyoTyrantTable::putNr' => ['void', 'keys'=>'mixed', 'value='=>'string'],
'TokyoTyrantTable::putShl' => ['void', 'key'=>'string', 'value'=>'string', 'width'=>'int'],
'TokyoTyrantTable::setIndex' => ['mixed', 'column'=>'string', 'type'=>'int'],
'touch' => ['bool', 'filename'=>'string', 'time='=>'int', 'atime='=>'int'],
'trader_acos' => ['array', 'real'=>'array'],
'trader_ad' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'volume'=>'array'],
'trader_add' => ['array', 'real0'=>'array', 'real1'=>'array'],
'trader_adosc' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'volume'=>'array', 'fastPeriod='=>'int', 'slowPeriod='=>'int'],
'trader_adx' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'timePeriod='=>'int'],
'trader_adxr' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'timePeriod='=>'int'],
'trader_apo' => ['array', 'real'=>'array', 'fastPeriod='=>'int', 'slowPeriod='=>'int', 'mAType='=>'int'],
'trader_aroon' => ['array', 'high'=>'array', 'low'=>'array', 'timePeriod='=>'int'],
'trader_aroonosc' => ['array', 'high'=>'array', 'low'=>'array', 'timePeriod='=>'int'],
'trader_asin' => ['array', 'real'=>'array'],
'trader_atan' => ['array', 'real'=>'array'],
'trader_atr' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'timePeriod='=>'int'],
'trader_avgprice' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_bbands' => ['array', 'real'=>'array', 'timePeriod='=>'int', 'nbDevUp='=>'float', 'nbDevDn='=>'float', 'mAType='=>'int'],
'trader_beta' => ['array', 'real0'=>'array', 'real1'=>'array', 'timePeriod='=>'int'],
'trader_bop' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cci' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'timePeriod='=>'int'],
'trader_cdl2crows' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdl3blackcrows' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdl3inside' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdl3linestrike' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdl3outside' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdl3starsinsouth' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdl3whitesoldiers' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlabandonedbaby' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'penetration='=>'float'],
'trader_cdladvanceblock' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlbelthold' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlbreakaway' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlclosingmarubozu' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlconcealbabyswall' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlcounterattack' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdldarkcloudcover' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'penetration='=>'float'],
'trader_cdldoji' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdldojistar' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdldragonflydoji' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlengulfing' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdleveningdojistar' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'penetration='=>'float'],
'trader_cdleveningstar' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'penetration='=>'float'],
'trader_cdlgapsidesidewhite' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlgravestonedoji' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlhammer' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlhangingman' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlharami' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlharamicross' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlhighwave' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlhikkake' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlhikkakemod' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlhomingpigeon' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlidentical3crows' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlinneck' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlinvertedhammer' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlkicking' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlkickingbylength' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlladderbottom' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdllongleggeddoji' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdllongline' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlmarubozu' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlmatchinglow' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlmathold' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'penetration='=>'float'],
'trader_cdlmorningdojistar' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'penetration='=>'float'],
'trader_cdlmorningstar' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'penetration='=>'float'],
'trader_cdlonneck' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlpiercing' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlrickshawman' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlrisefall3methods' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlseparatinglines' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlshootingstar' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlshortline' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlspinningtop' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlstalledpattern' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlsticksandwich' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdltakuri' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdltasukigap' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlthrusting' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdltristar' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlunique3river' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlupsidegap2crows' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_cdlxsidegap3methods' => ['array', 'open'=>'array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_ceil' => ['array', 'real'=>'array'],
'trader_cmo' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_correl' => ['array', 'real0'=>'array', 'real1'=>'array', 'timePeriod='=>'int'],
'trader_cos' => ['array', 'real'=>'array'],
'trader_cosh' => ['array', 'real'=>'array'],
'trader_dema' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_div' => ['array', 'real0'=>'array', 'real1'=>'array'],
'trader_dx' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'timePeriod='=>'int'],
'trader_ema' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_errno' => ['int'],
'trader_exp' => ['array', 'real'=>'array'],
'trader_floor' => ['array', 'real'=>'array'],
'trader_get_compat' => ['int'],
'trader_get_unstable_period' => ['int', 'functionId'=>'int'],
'trader_ht_dcperiod' => ['array', 'real'=>'array'],
'trader_ht_dcphase' => ['array', 'real'=>'array'],
'trader_ht_phasor' => ['array', 'real'=>'array'],
'trader_ht_sine' => ['array', 'real'=>'array'],
'trader_ht_trendline' => ['array', 'real'=>'array'],
'trader_ht_trendmode' => ['array', 'real'=>'array'],
'trader_kama' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_linearreg' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_linearreg_angle' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_linearreg_intercept' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_linearreg_slope' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_ln' => ['array', 'real'=>'array'],
'trader_log10' => ['array', 'real'=>'array'],
'trader_ma' => ['array', 'real'=>'array', 'timePeriod='=>'int', 'mAType='=>'int'],
'trader_macd' => ['array', 'real'=>'array', 'fastPeriod='=>'int', 'slowPeriod='=>'int', 'signalPeriod='=>'int'],
'trader_macdext' => ['array', 'real'=>'array', 'fastPeriod='=>'int', 'fastMAType='=>'int', 'slowPeriod='=>'int', 'slowMAType='=>'int', 'signalPeriod='=>'int', 'signalMAType='=>'int'],
'trader_macdfix' => ['array', 'real'=>'array', 'signalPeriod='=>'int'],
'trader_mama' => ['array', 'real'=>'array', 'fastLimit='=>'float', 'slowLimit='=>'float'],
'trader_mavp' => ['array', 'real'=>'array', 'periods'=>'array', 'minPeriod='=>'int', 'maxPeriod='=>'int', 'mAType='=>'int'],
'trader_max' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_maxindex' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_medprice' => ['array', 'high'=>'array', 'low'=>'array'],
'trader_mfi' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'volume'=>'array', 'timePeriod='=>'int'],
'trader_midpoint' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_midprice' => ['array', 'high'=>'array', 'low'=>'array', 'timePeriod='=>'int'],
'trader_min' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_minindex' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_minmax' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_minmaxindex' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_minus_di' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'timePeriod='=>'int'],
'trader_minus_dm' => ['array', 'high'=>'array', 'low'=>'array', 'timePeriod='=>'int'],
'trader_mom' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_mult' => ['array', 'real0'=>'array', 'real1'=>'array'],
'trader_natr' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'timePeriod='=>'int'],
'trader_obv' => ['array', 'real'=>'array', 'volume'=>'array'],
'trader_plus_di' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'timePeriod='=>'int'],
'trader_plus_dm' => ['array', 'high'=>'array', 'low'=>'array', 'timePeriod='=>'int'],
'trader_ppo' => ['array', 'real'=>'array', 'fastPeriod='=>'int', 'slowPeriod='=>'int', 'mAType='=>'int'],
'trader_roc' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_rocp' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_rocr' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_rocr100' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_rsi' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_sar' => ['array', 'high'=>'array', 'low'=>'array', 'acceleration='=>'float', 'maximum='=>'float'],
'trader_sarext' => ['array', 'high'=>'array', 'low'=>'array', 'startValue='=>'float', 'offsetOnReverse='=>'float', 'accelerationInitLong='=>'float', 'accelerationLong='=>'float', 'accelerationMaxLong='=>'float', 'accelerationInitShort='=>'float', 'accelerationShort='=>'float', 'accelerationMaxShort='=>'float'],
'trader_set_compat' => ['void', 'compatId'=>'int'],
'trader_set_unstable_period' => ['void', 'functionId'=>'int', 'timePeriod'=>'int'],
'trader_sin' => ['array', 'real'=>'array'],
'trader_sinh' => ['array', 'real'=>'array'],
'trader_sma' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_sqrt' => ['array', 'real'=>'array'],
'trader_stddev' => ['array', 'real'=>'array', 'timePeriod='=>'int', 'nbDev='=>'float'],
'trader_stoch' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'fastK_Period='=>'int', 'slowK_Period='=>'int', 'slowK_MAType='=>'int', 'slowD_Period='=>'int', 'slowD_MAType='=>'int'],
'trader_stochf' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'fastK_Period='=>'int', 'fastD_Period='=>'int', 'fastD_MAType='=>'int'],
'trader_stochrsi' => ['array', 'real'=>'array', 'timePeriod='=>'int', 'fastK_Period='=>'int', 'fastD_Period='=>'int', 'fastD_MAType='=>'int'],
'trader_sub' => ['array', 'real0'=>'array', 'real1'=>'array'],
'trader_sum' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_t3' => ['array', 'real'=>'array', 'timePeriod='=>'int', 'vFactor='=>'float'],
'trader_tan' => ['array', 'real'=>'array'],
'trader_tanh' => ['array', 'real'=>'array'],
'trader_tema' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_trange' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_trima' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_trix' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_tsf' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trader_typprice' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_ultosc' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'timePeriod1='=>'int', 'timePeriod2='=>'int', 'timePeriod3='=>'int'],
'trader_var' => ['array', 'real'=>'array', 'timePeriod='=>'int', 'nbDev='=>'float'],
'trader_wclprice' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array'],
'trader_willr' => ['array', 'high'=>'array', 'low'=>'array', 'close'=>'array', 'timePeriod='=>'int'],
'trader_wma' => ['array', 'real'=>'array', 'timePeriod='=>'int'],
'trait_exists' => ['bool', 'traitname'=>'string', 'autoload='=>'bool'],
'Transliterator::create' => ['?Transliterator', 'id'=>'string', 'direction='=>'int'],
'Transliterator::createFromRules' => ['?Transliterator', 'rules'=>'string', 'direction='=>'int'],
'Transliterator::createInverse' => ['Transliterator'],
'Transliterator::getErrorCode' => ['int'],
'Transliterator::getErrorMessage' => ['string'],
'Transliterator::listIDs' => ['array'],
'Transliterator::transliterate' => ['', 'subject'=>'string', 'start='=>'int', 'end='=>'int'],
'transliterator_create' => ['?Transliterator', 'id'=>'string', 'direction='=>'int'],
'transliterator_create_from_rules' => ['?Transliterator', 'rules'=>'string', 'direction='=>'int'],
'transliterator_create_inverse' => ['Transliterator', 'obj'=>'Transliterator'],
'transliterator_get_error_code' => ['int', 'obj'=>'Transliterator'],
'transliterator_get_error_message' => ['string', 'obj'=>'Transliterator'],
'transliterator_list_ids' => ['array'],
'transliterator_transliterate' => ['', 'obj'=>'Transliterator', 'subject'=>'string', 'start='=>'int', 'end='=>'int'],
'trigger_error' => ['bool', 'message'=>'string', 'error_type='=>'int'],
'trim' => ['string', 'str'=>'string', 'character_mask='=>'string'],
'TypeError::__clone' => ['void'],
'TypeError::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?TypeError'],
'TypeError::__toString' => ['string'],
'TypeError::getCode' => ['int'],
'TypeError::getFile' => ['string'],
'TypeError::getLine' => ['int'],
'TypeError::getMessage' => ['string'],
'TypeError::getPrevious' => ['Throwable|TypeError|null'],
'TypeError::getTrace' => ['array'],
'TypeError::getTraceAsString' => ['string'],
'uasort' => ['bool', '&rw_array_arg'=>'array', 'cmp_function'=>'callable'],
'ucfirst' => ['string', 'str'=>'string'],
'UConverter::__construct' => ['void', 'destination_encoding'=>'string', 'source_encoding='=>'string'],
'UConverter::convert' => ['string', 'str'=>'string', 'reverse='=>'bool'],
'UConverter::fromUCallback' => ['mixed', 'reason'=>'int', 'source'=>'string', 'codePoint'=>'string', '&w_error'=>'int'],
'UConverter::getAliases' => ['array', 'name='=>'string'],
'UConverter::getAvailable' => ['array'],
'UConverter::getDestinationEncoding' => ['string'],
'UConverter::getDestinationType' => ['int'],
'UConverter::getErrorCode' => ['int'],
'UConverter::getErrorMessage' => ['string'],
'UConverter::getSourceEncoding' => ['string'],
'UConverter::getSourceType' => ['int'],
'UConverter::getStandards' => ['array'],
'UConverter::getSubstChars' => ['string'],
'UConverter::reasonText' => ['string', 'reason='=>'int'],
'UConverter::setDestinationEncoding' => ['bool', 'encoding'=>'string'],
'UConverter::setSourceEncoding' => ['bool', 'encoding'=>'string'],
'UConverter::setSubstChars' => ['bool', 'chars'=>'string'],
'UConverter::toUCallback' => ['mixed', 'reason'=>'int', 'source'=>'string', 'codeUnits'=>'string', '&w_error'=>'int'],
'UConverter::transcode' => ['string', 'str'=>'string', 'toEncoding'=>'string', 'fromEncoding'=>'string', 'options='=>'array'],
'ucwords' => ['string', 'str'=>'string', 'delims='=>'string'],
'udm_add_search_limit' => ['bool', 'agent'=>'resource', 'var'=>'int', 'val'=>'string'],
'udm_alloc_agent' => ['resource', 'dbaddr'=>'string', 'dbmode='=>'string'],
'udm_alloc_agent_array' => ['resource', 'databases'=>'array'],
'udm_api_version' => ['int'],
'udm_cat_list' => ['array', 'agent'=>'resource', 'category'=>'string'],
'udm_cat_path' => ['array', 'agent'=>'resource', 'category'=>'string'],
'udm_check_charset' => ['bool', 'agent'=>'resource', 'charset'=>'string'],
'udm_check_stored' => ['int', 'agent'=>'', 'link'=>'int', 'doc_id'=>'string'],
'udm_clear_search_limits' => ['bool', 'agent'=>'resource'],
'udm_close_stored' => ['int', 'agent'=>'', 'link'=>'int'],
'udm_crc32' => ['int', 'agent'=>'resource', 'str'=>'string'],
'udm_errno' => ['int', 'agent'=>'resource'],
'udm_error' => ['string', 'agent'=>'resource'],
'udm_find' => ['resource', 'agent'=>'resource', 'query'=>'string'],
'udm_free_agent' => ['int', 'agent'=>'resource'],
'udm_free_ispell_data' => ['bool', 'agent'=>'int'],
'udm_free_res' => ['bool', 'res'=>'resource'],
'udm_get_doc_count' => ['int', 'agent'=>'resource'],
'udm_get_res_field' => ['string', 'res'=>'resource', 'row'=>'int', 'field'=>'int'],
'udm_get_res_param' => ['string', 'res'=>'resource', 'param'=>'int'],
'udm_hash32' => ['int', 'agent'=>'resource', 'str'=>'string'],
'udm_load_ispell_data' => ['bool', 'agent'=>'resource', 'var'=>'int', 'val1'=>'string', 'val2'=>'string', 'flag'=>'int'],
'udm_open_stored' => ['int', 'agent'=>'', 'storedaddr'=>'string'],
'udm_set_agent_param' => ['bool', 'agent'=>'resource', 'var'=>'int', 'val'=>'string'],
'ui\draw\text\font\fontfamilies' => ['array'],
'ui\quit' => ['void'],
'ui\run' => ['void', 'flags='=>'int'],
'uksort' => ['bool', '&rw_array_arg'=>'array', 'cmp_function'=>'callable'],
'umask' => ['int', 'mask='=>'int'],
'UnderflowException::__clone' => ['void'],
'UnderflowException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?UnderflowException'],
'UnderflowException::__toString' => ['string'],
'UnderflowException::getCode' => ['int'],
'UnderflowException::getFile' => ['string'],
'UnderflowException::getLine' => ['int'],
'UnderflowException::getMessage' => ['string'],
'UnderflowException::getPrevious' => ['Throwable|UnderflowException|null'],
'UnderflowException::getTrace' => ['array'],
'UnderflowException::getTraceAsString' => ['string'],
'UnexpectedValueException::__clone' => ['void'],
'UnexpectedValueException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable|?UnexpectedValueException'],
'UnexpectedValueException::__toString' => ['string'],
'UnexpectedValueException::getCode' => ['int'],
'UnexpectedValueException::getFile' => ['string'],
'UnexpectedValueException::getLine' => ['int'],
'UnexpectedValueException::getMessage' => ['string'],
'UnexpectedValueException::getPrevious' => ['Throwable|UnexpectedValueException|null'],
'UnexpectedValueException::getTrace' => ['array'],
'UnexpectedValueException::getTraceAsString' => ['string'],
'uniqid' => ['string', 'prefix='=>'string', 'more_entropy='=>'bool'],
'unixtojd' => ['int', 'timestamp='=>'int'],
'unlink' => ['bool', 'filename'=>'string', 'context='=>'resource'],
'unpack' => ['array', 'format'=>'string', 'data'=>'string', 'offset='=>'int'],
'unregister_tick_function' => ['void', 'function_name'=>'string'],
'unserialize' => ['mixed', 'variable_representation'=>'string', 'allowed_classes='=>'array'],
'unset' => ['void', 'var='=>'mixed', '...args='=>'mixed'],
'untaint' => ['bool', '&rw_string'=>'string', '&...rw_strings='=>'string'],
'uopz_allow_exit' => ['void', 'allow'=>'bool'],
'uopz_backup' => ['void', 'class'=>'string', 'function'=>'string'],
'uopz_backup\'1' => ['void', 'function'=>'string'],
'uopz_compose' => ['void', 'name'=>'string', 'classes'=>'array', 'methods='=>'array', 'properties='=>'array', 'flags='=>'int'],
'uopz_copy' => ['Closure', 'class'=>'string', 'function'=>'string'],
'uopz_copy\'1' => ['Closure', 'function'=>'string'],
'uopz_delete' => ['void', 'class'=>'string', 'function'=>'string'],
'uopz_delete\'1' => ['void', 'function'=>'string'],
'uopz_extend' => ['void', 'class'=>'string', 'parent'=>'string'],
'uopz_flags' => ['int', 'class'=>'string', 'function'=>'string', 'flags'=>'int'],
'uopz_flags\'1' => ['int', 'function'=>'string', 'flags'=>'int'],
'uopz_function' => ['void', 'class'=>'string', 'function'=>'string', 'handler'=>'Closure', 'modifiers='=>'int'],
'uopz_function\'1' => ['void', 'function'=>'string', 'handler'=>'Closure', 'modifiers='=>'int'],
'uopz_get_exit_status' => ['mixed'],
'uopz_get_mock' => ['mixed', 'class'=>'string'],
'uopz_get_return' => ['mixed', 'class='=>'string', 'function'=>'string'],
'uopz_implement' => ['void', 'class'=>'string', 'interface'=>'string'],
'uopz_overload' => ['void', 'opcode'=>'int', 'callable'=>'Callable'],
'uopz_redefine' => ['void', 'class'=>'string', 'constant'=>'string', 'value'=>'mixed'],
'uopz_redefine\'1' => ['void', 'constant'=>'string', 'value'=>'mixed'],
'uopz_rename' => ['void', 'class'=>'string', 'function'=>'string', 'rename'=>'string'],
'uopz_rename\'1' => ['void', 'function'=>'string', 'rename'=>'string'],
'uopz_restore' => ['void', 'class'=>'string', 'function'=>'string'],
'uopz_restore\'1' => ['void', 'function'=>'string'],
'uopz_set_mock' => ['void', 'class'=>'string', 'mock'=>'object|string'],
'uopz_set_return' => ['bool', 'class='=>'string', 'function'=>'string', 'value'=>'mixed', 'execute='=>'bool'],
'uopz_set_return\'1' => ['bool', 'function'=>'string', 'value'=>'mixed', 'execute='=>'bool'],
'uopz_undefine' => ['void', 'class'=>'string', 'constant'=>'string'],
'uopz_undefine\'1' => ['void', 'constant'=>'string'],
'uopz_unset_mock' => ['void', 'class'=>'string'],
'uopz_unset_return' => ['bool', 'class='=>'string', 'function'=>'string'],
'uopz_unset_return\'1' => ['bool', 'function'=>'string'],
'urldecode' => ['string', 'str'=>'string'],
'urlencode' => ['string', 'str'=>'string'],
'use_soap_error_handler' => ['bool', 'handler='=>'bool'],
'usleep' => ['void', 'micro_seconds'=>'int'],
'usort' => ['bool', '&rw_array_arg'=>'array', 'cmp_function'=>'callable'],
'utf8_decode' => ['string', 'data'=>'string'],
'utf8_encode' => ['string', 'data'=>'string'],
'V8Js::__construct' => ['void', 'object_name='=>'string', 'variables='=>'array', 'extensions='=>'array', 'report_uncaught_exceptions='=>'bool', 'snapshot_blob='=>'string'],
'V8Js::clearPendingException' => [''],
'V8Js::compileString' => ['resource', 'script'=>'', 'identifier='=>'string'],
'V8Js::createSnapshot' => ['false|string', 'embed_source'=>'string'],
'V8Js::executeScript' => ['', 'script'=>'resource', 'flags='=>'int', 'time_limit='=>'int', 'memory_limit='=>'int'],
'V8Js::executeString' => ['mixed', 'script'=>'string', 'identifier='=>'string', 'flags='=>'int'],
'V8Js::getExtensions' => ['array'],
'V8Js::getPendingException' => ['V8JsException'],
'V8Js::registerExtension' => ['bool', 'extension_name'=>'string', 'script'=>'string', 'dependencies='=>'array', 'auto_enable='=>'bool'],
'V8Js::setAverageObjectSize' => ['', 'average_object_size'=>'int'],
'V8Js::setMemoryLimit' => ['', 'limit'=>'int'],
'V8Js::setModuleLoader' => ['', 'loader'=>'callable'],
'V8Js::setModuleNormaliser' => ['', 'normaliser'=>'callable'],
'V8Js::setTimeLimit' => ['', 'limit'=>'int'],
'V8JsException::getJsFileName' => ['string'],
'V8JsException::getJsLineNumber' => ['int'],
'V8JsException::getJsSourceLine' => ['int'],
'V8JsException::getJsTrace' => ['string'],
'V8JsScriptException::__clone' => ['void'],
'V8JsScriptException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?\Exception|?\Throwable'],
'V8JsScriptException::__toString' => ['string'],
'V8JsScriptException::__wakeup' => ['void'],
'V8JsScriptException::getCode' => ['int'],
'V8JsScriptException::getFile' => ['string'],
'V8JsScriptException::getJsEndColumn' => ['int'],
'V8JsScriptException::getJsFileName' => ['string'],
'V8JsScriptException::getJsLineNumber' => ['int'],
'V8JsScriptException::getJsSourceLine' => ['string'],
'V8JsScriptException::getJsStartColumn' => ['int'],
'V8JsScriptException::getJsTrace' => ['string'],
'V8JsScriptException::getLine' => ['int'],
'V8JsScriptException::getMessage' => ['string'],
'V8JsScriptException::getPrevious' => ['Exception|Throwable'],
'V8JsScriptException::getTrace' => ['array'],
'V8JsScriptException::getTraceAsString' => ['string'],
'var_dump' => ['void', 'var'=>'mixed', '...args='=>'mixed'],
'var_export' => ['string|null', 'var'=>'mixed', 'return='=>'bool'],
'VARIANT::__construct' => ['void', 'value='=>'mixed', 'type='=>'int', 'codepage='=>'int'],
'variant_abs' => ['mixed', 'left'=>'mixed'],
'variant_add' => ['mixed', 'left'=>'mixed', 'right'=>'mixed'],
'variant_and' => ['mixed', 'left'=>'mixed', 'right'=>'mixed'],
'variant_cast' => ['object', 'variant'=>'object', 'type'=>'int'],
'variant_cat' => ['mixed', 'left'=>'mixed', 'right'=>'mixed'],
'variant_cmp' => ['int', 'left'=>'mixed', 'right'=>'mixed', 'lcid='=>'int', 'flags='=>'int'],
'variant_date_from_timestamp' => ['object', 'timestamp'=>'int'],
'variant_date_to_timestamp' => ['int', 'variant'=>'object'],
'variant_div' => ['mixed', 'left'=>'mixed', 'right'=>'mixed'],
'variant_eqv' => ['mixed', 'left'=>'mixed', 'right'=>'mixed'],
'variant_fix' => ['mixed', 'left'=>'mixed'],
'variant_get_type' => ['int', 'variant'=>'object'],
'variant_idiv' => ['mixed', 'left'=>'mixed', 'right'=>'mixed'],
'variant_imp' => ['mixed', 'left'=>'mixed', 'right'=>'mixed'],
'variant_int' => ['mixed', 'left'=>'mixed'],
'variant_mod' => ['mixed', 'left'=>'mixed', 'right'=>'mixed'],
'variant_mul' => ['mixed', 'left'=>'mixed', 'right'=>'mixed'],
'variant_neg' => ['mixed', 'left'=>'mixed'],
'variant_not' => ['mixed', 'left'=>'mixed'],
'variant_or' => ['mixed', 'left'=>'mixed', 'right'=>'mixed'],
'variant_pow' => ['mixed', 'left'=>'mixed', 'right'=>'mixed'],
'variant_round' => ['mixed', 'left'=>'mixed', 'decimals'=>'int'],
'variant_set' => ['void', 'variant'=>'object', 'value'=>'mixed'],
'variant_set_type' => ['void', 'variant'=>'object', 'type'=>'int'],
'variant_sub' => ['mixed', 'left'=>'mixed', 'right'=>'mixed'],
'variant_xor' => ['mixed', 'left'=>'mixed', 'right'=>'mixed'],
'VarnishAdmin::__construct' => ['void', 'args='=>'array'],
'VarnishAdmin::auth' => ['bool'],
'VarnishAdmin::ban' => ['int', 'vcl_regex'=>'string'],
'VarnishAdmin::banUrl' => ['int', 'vcl_regex'=>'string'],
'VarnishAdmin::clearPanic' => ['int'],
'VarnishAdmin::connect' => ['bool'],
'VarnishAdmin::disconnect' => ['bool'],
'VarnishAdmin::getPanic' => ['string'],
'VarnishAdmin::getParams' => ['array'],
'VarnishAdmin::isRunning' => ['bool'],
'VarnishAdmin::setCompat' => ['void', 'compat'=>'int'],
'VarnishAdmin::setHost' => ['void', 'host'=>'string'],
'VarnishAdmin::setIdent' => ['void', 'ident'=>'string'],
'VarnishAdmin::setParam' => ['int', 'name'=>'string', 'value'=>'string|int'],
'VarnishAdmin::setPort' => ['void', 'port'=>'int'],
'VarnishAdmin::setSecret' => ['void', 'secret'=>'string'],
'VarnishAdmin::setTimeout' => ['void', 'timeout'=>'int'],
'VarnishAdmin::start' => ['int'],
'VarnishAdmin::stop' => ['int'],
'VarnishLog::__construct' => ['void', 'args='=>'array'],
'VarnishLog::getLine' => ['array'],
'VarnishLog::getTagName' => ['string', 'index'=>'int'],
'VarnishStat::__construct' => ['void', 'args='=>'array'],
'VarnishStat::getSnapshot' => ['array'],
'version_compare' => ['int', 'version1'=>'string', 'version2'=>'string'],
'version_compare\'1' => ['bool', 'version1'=>'string', 'version2'=>'string', 'operator'=>'string'],
'vfprintf' => ['int', 'stream'=>'resource', 'format'=>'string', 'args'=>'array'],
'virtual' => ['bool', 'uri'=>'string'],
'vpopmail_add_alias_domain' => ['bool', 'domain'=>'string', 'aliasdomain'=>'string'],
'vpopmail_add_alias_domain_ex' => ['bool', 'olddomain'=>'string', 'newdomain'=>'string'],
'vpopmail_add_domain' => ['bool', 'domain'=>'string', 'dir'=>'string', 'uid'=>'int', 'gid'=>'int'],
'vpopmail_add_domain_ex' => ['bool', 'domain'=>'string', 'passwd'=>'string', 'quota='=>'string', 'bounce='=>'string', 'apop='=>'bool'],
'vpopmail_add_user' => ['bool', 'user'=>'string', 'domain'=>'string', 'password'=>'string', 'gecos='=>'string', 'apop='=>'bool'],
'vpopmail_alias_add' => ['bool', 'user'=>'string', 'domain'=>'string', 'alias'=>'string'],
'vpopmail_alias_del' => ['bool', 'user'=>'string', 'domain'=>'string'],
'vpopmail_alias_del_domain' => ['bool', 'domain'=>'string'],
'vpopmail_alias_get' => ['array', 'alias'=>'string', 'domain'=>'string'],
'vpopmail_alias_get_all' => ['array', 'domain'=>'string'],
'vpopmail_auth_user' => ['bool', 'user'=>'string', 'domain'=>'string', 'password'=>'string', 'apop='=>'string'],
'vpopmail_del_domain' => ['bool', 'domain'=>'string'],
'vpopmail_del_domain_ex' => ['bool', 'domain'=>'string'],
'vpopmail_del_user' => ['bool', 'user'=>'string', 'domain'=>'string'],
'vpopmail_error' => ['string'],
'vpopmail_passwd' => ['bool', 'user'=>'string', 'domain'=>'string', 'password'=>'string', 'apop='=>'bool'],
'vpopmail_set_user_quota' => ['bool', 'user'=>'string', 'domain'=>'string', 'quota'=>'string'],
'vprintf' => ['int', 'format'=>'string', 'args'=>'array'],
'vsprintf' => ['string', 'format'=>'string', 'args'=>'array'],
'w32api_deftype' => ['bool', 'typename'=>'string', 'member1_type'=>'string', 'member1_name'=>'string', '...args='=>'string'],
'w32api_init_dtype' => ['resource', 'typename'=>'string', 'value'=>'', '...args='=>''],
'w32api_invoke_function' => ['', 'funcname'=>'string', 'argument'=>'', '...args='=>''],
'w32api_register_function' => ['bool', 'library'=>'string', 'function_name'=>'string', 'return_type'=>'string'],
'w32api_set_call_method' => ['', 'method'=>'int'],
'wddx_add_vars' => ['bool', 'packet_id'=>'resource', 'var_names'=>'mixed', '...vars='=>'mixed'],
'wddx_deserialize' => ['mixed', 'packet'=>'string'],
'wddx_packet_end' => ['string', 'packet_id'=>'resource'],
'wddx_packet_start' => ['resource', 'comment='=>'string'],
'wddx_serialize_value' => ['string', 'var'=>'mixed', 'comment='=>'string'],
'wddx_serialize_vars' => ['string', 'var_name'=>'mixed', '...vars='=>'mixed'],
'WeakMap::__construct' => ['void'],
'WeakMap::count' => ['int'],
'WeakMap::current' => ['mixed'],
'WeakMap::key' => ['object'],
'WeakMap::next' => ['void'],
'WeakMap::offsetExists' => ['bool', 'object'=>'object'],
'WeakMap::offsetGet' => ['mixed', 'object'=>'object'],
'WeakMap::offsetSet' => ['void', 'object'=>'object', 'value'=>'mixed'],
'WeakMap::offsetUnset' => ['void', 'object'=>'object'],
'WeakMap::rewind' => ['void'],
'WeakMap::valid' => ['bool'],
'Weakref::acquire' => ['bool'],
'Weakref::get' => ['object'],
'Weakref::release' => ['bool'],
'Weakref::valid' => ['bool'],
'webObj::convertToString' => ['string'],
'webObj::free' => ['void'],
'webObj::set' => ['int', 'property_name'=>'string', 'new_value'=>''],
'webObj::updateFromString' => ['int', 'snippet'=>'string'],
'win32_continue_service' => ['int', 'servicename'=>'string', 'machine='=>'string'],
'win32_create_service' => ['mixed', 'details'=>'array', 'machine='=>'string'],
'win32_delete_service' => ['mixed', 'servicename'=>'string', 'machine='=>'string'],
'win32_get_last_control_message' => ['int'],
'win32_pause_service' => ['int', 'servicename'=>'string', 'machine='=>'string'],
'win32_ps_list_procs' => ['array'],
'win32_ps_stat_mem' => ['array'],
'win32_ps_stat_proc' => ['array', 'pid='=>'int'],
'win32_query_service_status' => ['mixed', 'servicename'=>'string', 'machine='=>'string'],
'win32_set_service_status' => ['bool', 'status'=>'int', 'checkpoint='=>'int'],
'win32_start_service' => ['int', 'servicename'=>'string', 'machine='=>'string'],
'win32_start_service_ctrl_dispatcher' => ['mixed', 'name'=>'string'],
'win32_stop_service' => ['int', 'servicename'=>'string', 'machine='=>'string'],
'wincache_fcache_fileinfo' => ['array', 'summaryonly='=>'bool'],
'wincache_fcache_meminfo' => ['array'],
'wincache_lock' => ['bool', 'key'=>'string', 'isglobal='=>'bool'],
'wincache_ocache_fileinfo' => ['array', 'summaryonly='=>'bool'],
'wincache_ocache_meminfo' => ['array'],
'wincache_refresh_if_changed' => ['bool', 'files='=>'array'],
'wincache_rplist_fileinfo' => ['array', 'summaryonly='=>'bool'],
'wincache_rplist_meminfo' => ['array'],
'wincache_scache_info' => ['array', 'summaryonly='=>'bool'],
'wincache_scache_meminfo' => ['array'],
'wincache_ucache_add' => ['bool', 'key'=>'string', 'value'=>'', 'ttl='=>'int'],
'wincache_ucache_add\'1' => ['bool', 'values'=>'array', 'unused='=>'', 'ttl='=>'int'],
'wincache_ucache_cas' => ['bool', 'key'=>'string', 'old_value'=>'int', 'new_value'=>'int'],
'wincache_ucache_clear' => ['bool'],
'wincache_ucache_dec' => ['mixed', 'key'=>'string', 'dec_by='=>'int', 'success='=>'bool'],
'wincache_ucache_delete' => ['bool', 'key'=>'mixed'],
'wincache_ucache_exists' => ['bool', 'key'=>'string'],
'wincache_ucache_get' => ['mixed', 'key'=>'mixed', '&w_success='=>'bool'],
'wincache_ucache_inc' => ['mixed', 'key'=>'string', 'inc_by='=>'int', 'success='=>'bool'],
'wincache_ucache_info' => ['array', 'summaryonly='=>'bool', 'key='=>'string'],
'wincache_ucache_meminfo' => ['array'],
'wincache_ucache_set' => ['bool', 'key'=>'', 'value'=>'', 'ttl='=>'int'],
'wincache_ucache_set\'1' => ['bool', 'values'=>'array', 'unused='=>'', 'ttl='=>'int'],
'wincache_unlock' => ['bool', 'key'=>'string'],
'wordwrap' => ['string', 'str'=>'string', 'width='=>'int', 'break='=>'string', 'cut='=>'bool'],
'Worker::__construct' => ['void'],
'Worker::chunk' => ['array', 'size'=>'int', 'preserve'=>'bool'],
'Worker::collect' => ['int', 'collector='=>'Callable'],
'Worker::count' => ['int'],
'Worker::detach' => ['void'],
'Worker::getCreatorId' => ['int'],
'Worker::getCurrentThread' => ['Thread'],
'Worker::getCurrentThreadId' => ['int'],
'Worker::getStacked' => ['int'],
'Worker::getTerminationInfo' => ['array'],
'Worker::getThreadId' => ['int'],
'Worker::globally' => ['mixed'],
'Worker::isJoined' => ['bool'],
'Worker::isRunning' => ['bool'],
'Worker::isShutdown' => ['bool'],
'Worker::isStarted' => ['bool'],
'Worker::isTerminated' => ['bool'],
'Worker::isWaiting' => ['bool'],
'Worker::isWorking' => ['bool'],
'Worker::join' => ['bool'],
'Worker::kill' => ['bool'],
'Worker::lock' => ['bool'],
'Worker::merge' => ['bool', 'from'=>'', 'overwrite='=>'mixed'],
'Worker::notify' => ['bool'],
'Worker::offsetExists' => ['bool', 'offset'=>'mixed'],
'Worker::offsetGet' => ['mixed', 'offset'=>'mixed'],
'Worker::offsetSet' => ['void', 'offset'=>'mixed', 'value'=>'mixed'],
'Worker::offsetUnset' => ['void', 'offset'=>'mixed'],
'Worker::pop' => ['bool'],
'Worker::run' => ['void'],
'Worker::shift' => ['bool'],
'Worker::shutdown' => ['bool'],
'Worker::stack' => ['int', '&rw_work'=>'Threaded'],
'Worker::start' => ['bool', 'options='=>'int'],
'Worker::synchronized' => ['mixed', 'block'=>'Closure', '_='=>'mixed'],
'Worker::unlock' => ['bool'],
'Worker::unstack' => ['int', '&rw_work='=>'Threaded'],
'Worker::wait' => ['bool', 'timeout='=>'int'],
'xattr_get' => ['string', 'filename'=>'string', 'name'=>'string', 'flags='=>'int'],
'xattr_list' => ['array', 'filename'=>'string', 'flags='=>'int'],
'xattr_remove' => ['bool', 'filename'=>'string', 'name'=>'string', 'flags='=>'int'],
'xattr_set' => ['bool', 'filename'=>'string', 'name'=>'string', 'value'=>'string', 'flags='=>'int'],
'xattr_supported' => ['bool', 'filename'=>'string', 'flags='=>'int'],
'xcache_asm' => ['string', 'filename'=>'string'],
'xcache_clear_cache' => ['void', 'type'=>'int', 'id='=>'int'],
'xcache_coredump' => ['string', 'op_type'=>'int'],
'xcache_count' => ['int', 'type'=>'int'],
'xcache_coverager_decode' => ['array', 'data'=>'string'],
'xcache_coverager_get' => ['array', 'clean='=>'bool|false'],
'xcache_coverager_start' => ['void', 'clean='=>'bool|true'],
'xcache_coverager_stop' => ['void', 'clean='=>'bool|false'],
'xcache_dasm_file' => ['string', 'filename'=>'string'],
'xcache_dasm_string' => ['string', 'code'=>'string'],
'xcache_dec' => ['int', 'name'=>'string', 'value='=>'int|mixed', 'ttl='=>'int'],
'xcache_decode' => ['bool', 'filename'=>'string'],
'xcache_encode' => ['string', 'filename'=>'string'],
'xcache_get' => ['mixed', 'name'=>'string'],
'xcache_get_data_type' => ['string', 'type'=>'int'],
'xcache_get_op_spec' => ['string', 'op_type'=>'int'],
'xcache_get_op_type' => ['string', 'op_type'=>'int'],
'xcache_get_opcode' => ['string', 'opcode'=>'int'],
'xcache_get_opcode_spec' => ['string', 'opcode'=>'int'],
'xcache_inc' => ['int', 'name'=>'string', 'value='=>'int|mixed', 'ttl='=>'int'],
'xcache_info' => ['array', 'type'=>'int', 'id'=>'int'],
'xcache_is_autoglobal' => ['string', 'name'=>'string'],
'xcache_isset' => ['bool', 'name'=>'string'],
'xcache_list' => ['array', 'type'=>'int', 'id'=>'int'],
'xcache_set' => ['bool', 'name'=>'string', 'value'=>'mixed', 'ttl='=>'int'],
'xcache_unset' => ['bool', 'name'=>'string'],
'xcache_unset_by_prefix' => ['bool', 'prefix'=>'string'],
'Xcom::__construct' => ['void', 'fabric_url='=>'string', 'fabric_token='=>'string', 'capability_token='=>'string'],
'Xcom::decode' => ['object', 'avro_msg'=>'string', 'json_schema'=>'string'],
'Xcom::encode' => ['string', 'data'=>'stdClass', 'avro_schema'=>'string'],
'Xcom::getDebugOutput' => ['string'],
'Xcom::getLastResponse' => ['string'],
'Xcom::getLastResponseInfo' => ['array'],
'Xcom::getOnboardingURL' => ['string', 'capability_name'=>'string', 'agreement_url'=>'string'],
'Xcom::send' => ['int', 'topic'=>'string', 'data'=>'mixed', 'json_schema='=>'string', 'http_headers='=>'array'],
'Xcom::sendAsync' => ['int', 'topic'=>'string', 'data'=>'mixed', 'json_schema='=>'string', 'http_headers='=>'array'],
'xdebug_break' => ['bool'],
'xdebug_call_class' => ['string', 'depth=' => 'int'],
'xdebug_call_file' => ['string', 'depth=' => 'int'],
'xdebug_call_function' => ['string', 'depth=' => 'int'],
'xdebug_call_line' => ['int', 'depth=' => 'int'],
'xdebug_clear_aggr_profiling_data' => ['bool'],
'xdebug_code_coverage_started' => ['bool'],
'xdebug_debug_zval' => ['void', '...varName'=>'string'],
'xdebug_debug_zval_stdout' => ['void', '...varName'=>'string'],
'xdebug_disable' => ['void'],
'xdebug_dump_aggr_profiling_data' => ['bool'],
'xdebug_dump_superglobals' => ['void'],
'xdebug_enable' => ['void'],
'xdebug_get_code_coverage' => ['array'],
'xdebug_get_collected_errors' => ['string', 'clean='=>'bool|false'],
'xdebug_get_declared_vars' => ['array'],
'xdebug_get_formatted_function_stack' => [''],
'xdebug_get_function_count' => ['int'],
'xdebug_get_function_stack' => ['array', 'message='=>'string', 'options='=>'int'],
'xdebug_get_headers' => ['array'],
'xdebug_get_monitored_functions' => ['array'],
'xdebug_get_profiler_filename' => ['string'],
'xdebug_get_stack_depth' => ['int'],
'xdebug_get_tracefile_name' => ['string'],
'xdebug_is_debugger_active' => ['bool'],
'xdebug_is_enabled' => ['bool'],
'xdebug_memory_usage' => ['int'],
'xdebug_peak_memory_usage' => ['int'],
'xdebug_print_function_stack' => ['array', 'message='=>'string', 'options=' => 'int'],
'xdebug_set_filter' => ['void', 'group' => 'int', 'list_type' => 'int', 'configuration' => 'array'],
'xdebug_start_code_coverage' => ['void', 'options='=>'int'],
'xdebug_start_error_collection' => ['void'],
'xdebug_start_function_monitor' => ['void', 'list_of_functions_to_monitor'=>'string[]'],
'xdebug_start_trace' => ['void', 'trace_file'=>'', 'options='=>'int|mixed'],
'xdebug_stop_code_coverage' => ['void', 'cleanup='=>'bool|true'],
'xdebug_stop_error_collection' => ['void'],
'xdebug_stop_function_monitor' => ['void'],
'xdebug_stop_trace' => ['void'],
'xdebug_time_index' => ['float'],
'xdebug_var_dump' => ['void', '...var'=>''],
'xdiff_file_bdiff' => ['bool', 'old_file'=>'string', 'new_file'=>'string', 'dest'=>'string'],
'xdiff_file_bdiff_size' => ['int', 'file'=>'string'],
'xdiff_file_bpatch' => ['bool', 'file'=>'string', 'patch'=>'string', 'dest'=>'string'],
'xdiff_file_diff' => ['bool', 'old_file'=>'string', 'new_file'=>'string', 'dest'=>'string', 'context='=>'int', 'minimal='=>'bool'],
'xdiff_file_diff_binary' => ['bool', 'old_file'=>'string', 'new_file'=>'string', 'dest'=>'string'],
'xdiff_file_merge3' => ['mixed', 'old_file'=>'string', 'new_file1'=>'string', 'new_file2'=>'string', 'dest'=>'string'],
'xdiff_file_patch' => ['mixed', 'file'=>'string', 'patch'=>'string', 'dest'=>'string', 'flags='=>'int'],
'xdiff_file_patch_binary' => ['bool', 'file'=>'string', 'patch'=>'string', 'dest'=>'string'],
'xdiff_file_rabdiff' => ['bool', 'old_file'=>'string', 'new_file'=>'string', 'dest'=>'string'],
'xdiff_string_bdiff' => ['string', 'old_data'=>'string', 'new_data'=>'string'],
'xdiff_string_bdiff_size' => ['int', 'patch'=>'string'],
'xdiff_string_bpatch' => ['string', 'str'=>'string', 'patch'=>'string'],
'xdiff_string_diff' => ['string', 'old_data'=>'string', 'new_data'=>'string', 'context='=>'int', 'minimal='=>'bool'],
'xdiff_string_diff_binary' => ['string', 'old_data'=>'string', 'new_data'=>'string'],
'xdiff_string_merge3' => ['mixed', 'old_data'=>'string', 'new_data1'=>'string', 'new_data2'=>'string', 'error='=>'string'],
'xdiff_string_patch' => ['string', 'str'=>'string', 'patch'=>'string', 'flags='=>'int', 'error='=>'string'],
'xdiff_string_patch_binary' => ['string', 'str'=>'string', 'patch'=>'string'],
'xdiff_string_rabdiff' => ['string', 'old_data'=>'string', 'new_data'=>'string'],
'xhprof_disable' => ['array'],
'xhprof_enable' => ['void', 'flags='=>'int', 'options='=>'array'],
'xhprof_sample_disable' => ['array'],
'xhprof_sample_enable' => ['void'],
'xml_error_string' => ['string', 'code'=>'int'],
'xml_get_current_byte_index' => ['int', 'parser'=>'resource'],
'xml_get_current_column_number' => ['int', 'parser'=>'resource'],
'xml_get_current_line_number' => ['int', 'parser'=>'resource'],
'xml_get_error_code' => ['int', 'parser'=>'resource'],
'xml_parse' => ['int', 'parser'=>'resource', 'data'=>'string', 'isfinal='=>'bool'],
'xml_parse_into_struct' => ['int', 'parser'=>'resource', 'data'=>'string', '&w_values'=>'array', '&w_index='=>'array'],
'xml_parser_create' => ['resource', 'encoding='=>'string'],
'xml_parser_create_ns' => ['resource', 'encoding='=>'string', 'sep='=>'string'],
'xml_parser_free' => ['bool', 'parser'=>'resource'],
'xml_parser_get_option' => ['mixed', 'parser'=>'resource', 'option'=>'int'],
'xml_parser_set_option' => ['bool', 'parser'=>'resource', 'option'=>'int', 'value'=>'mixed'],
'xml_set_character_data_handler' => ['bool', 'parser'=>'resource', 'hdl'=>'string'],
'xml_set_default_handler' => ['bool', 'parser'=>'resource', 'hdl'=>'string'],
'xml_set_element_handler' => ['bool', 'parser'=>'resource', 'shdl'=>'string', 'ehdl'=>'string'],
'xml_set_end_namespace_decl_handler' => ['bool', 'parser'=>'resource', 'hdl'=>'string'],
'xml_set_external_entity_ref_handler' => ['bool', 'parser'=>'resource', 'hdl'=>'string'],
'xml_set_notation_decl_handler' => ['bool', 'parser'=>'resource', 'hdl'=>'string'],
'xml_set_object' => ['bool', 'parser'=>'resource', 'obj'=>'object'],
'xml_set_processing_instruction_handler' => ['bool', 'parser'=>'resource', 'hdl'=>'string'],
'xml_set_start_namespace_decl_handler' => ['bool', 'parser'=>'resource', 'hdl'=>'string'],
'xml_set_unparsed_entity_decl_handler' => ['bool', 'parser'=>'resource', 'hdl'=>'string'],
'XMLDiff\Base::__construct' => ['void', 'nsname'=>'string'],
'XMLDiff\Base::diff' => ['mixed', 'from'=>'mixed', 'to'=>'mixed'],
'XMLDiff\Base::merge' => ['mixed', 'src'=>'mixed', 'diff'=>'mixed'],
'XMLDiff\DOM::diff' => ['DOMDocument', 'from'=>'DOMDocument', 'to'=>'DOMDocument'],
'XMLDiff\DOM::merge' => ['DOMDocument', 'src'=>'DOMDocument', 'diff'=>'DOMDocument'],
'XMLDiff\File::diff' => ['string', 'from'=>'string', 'to'=>'string'],
'XMLDiff\File::merge' => ['string', 'src'=>'string', 'diff'=>'string'],
'XMLDiff\Memory::diff' => ['string', 'from'=>'string', 'to'=>'string'],
'XMLDiff\Memory::merge' => ['string', 'src'=>'string', 'diff'=>'string'],
'XMLReader::close' => ['bool'],
'XMLReader::expand' => ['DOMNode', 'basenode='=>'DOMNode'],
'XMLReader::getAttribute' => ['string|null', 'name'=>'string'],
'XMLReader::getAttributeNo' => ['string|null', 'index'=>'int'],
'XMLReader::getAttributeNs' => ['string|null', 'name'=>'string', 'namespaceuri'=>'string'],
'XMLReader::getParserProperty' => ['bool', 'property'=>'int'],
'XMLReader::isValid' => ['bool'],
'XMLReader::lookupNamespace' => ['?string', 'prefix'=>'string'],
'XMLReader::moveToAttribute' => ['bool', 'name'=>'string'],
'XMLReader::moveToAttributeNo' => ['bool', 'index'=>'int'],
'XMLReader::moveToAttributeNs' => ['bool', 'localname'=>'string', 'namespaceuri'=>'string'],
'XMLReader::moveToElement' => ['bool'],
'XMLReader::moveToFirstAttribute' => ['bool'],
'XMLReader::moveToNextAttribute' => ['bool'],
'XMLReader::next' => ['bool', 'localname='=>'string'],
'XMLReader::open' => ['bool', 'uri'=>'string', 'encoding='=>'?string', 'options='=>'int'],
'XMLReader::read' => ['bool'],
'XMLReader::readInnerXML' => ['string'],
'XMLReader::readOuterXML' => ['string'],
'XMLReader::readString' => ['string'],
'XMLReader::setParserProperty' => ['bool', 'property'=>'int', 'value'=>'bool'],
'XMLReader::setRelaxNGSchema' => ['bool', 'filename'=>'string'],
'XMLReader::setRelaxNGSchemaSource' => ['bool', 'source'=>'string'],
'XMLReader::setSchema' => ['bool', 'filename'=>'string'],
'XMLReader::XML' => ['bool', 'source'=>'string', 'encoding='=>'?string', 'options='=>'int'],
'xmlrpc_decode' => ['?array', 'xml'=>'string', 'encoding='=>'string'],
'xmlrpc_decode_request' => ['?array', 'xml'=>'string', '&w_method'=>'string', 'encoding='=>'string'],
'xmlrpc_encode' => ['string', 'value'=>'mixed'],
'xmlrpc_encode_request' => ['string', 'method'=>'string', 'params'=>'mixed', 'output_options='=>'array'],
'xmlrpc_get_type' => ['string', 'value'=>'mixed'],
'xmlrpc_is_fault' => ['bool', 'arg'=>'array'],
'xmlrpc_parse_method_descriptions' => ['array', 'xml'=>'string'],
'xmlrpc_server_add_introspection_data' => ['int', 'server'=>'resource', 'desc'=>'array'],
'xmlrpc_server_call_method' => ['string', 'server'=>'resource', 'xml'=>'string', 'user_data'=>'mixed', 'output_options='=>'array'],
'xmlrpc_server_create' => ['resource'],
'xmlrpc_server_destroy' => ['int', 'server'=>'resource'],
'xmlrpc_server_register_introspection_callback' => ['bool', 'server'=>'resource', 'function'=>'string'],
'xmlrpc_server_register_method' => ['bool', 'server'=>'resource', 'method_name'=>'string', 'function'=>'string'],
'xmlrpc_set_type' => ['bool', '&rw_value'=>'string|DateTime', 'type'=>'string'],
'XMLWriter::endAttribute' => ['bool'],
'XMLWriter::endCData' => ['bool'],
'XMLWriter::endComment' => ['bool'],
'XMLWriter::endDocument' => ['bool'],
'XMLWriter::endDTD' => ['bool', 'xmlwriter='=>''],
'XMLWriter::endDTDAttlist' => ['bool'],
'XMLWriter::endDTDElement' => ['bool'],
'XMLWriter::endDTDEntity' => ['bool'],
'XMLWriter::endElement' => ['bool'],
'XMLWriter::endPI' => ['bool'],
'XMLWriter::flush' => ['', 'empty='=>'bool', 'xmlwriter='=>''],
'XMLWriter::fullEndElement' => ['bool'],
'XMLWriter::openMemory' => ['resource'],
'XMLWriter::openURI' => ['resource', 'uri'=>'string'],
'XMLWriter::outputMemory' => ['string', 'flush='=>'bool', 'xmlwriter='=>''],
'XMLWriter::setIndent' => ['bool', 'indent'=>'bool'],
'XMLWriter::setIndentString' => ['bool', 'indentstring'=>'string'],
'XMLWriter::startAttribute' => ['bool', 'name'=>'string'],
'XMLWriter::startAttributeNS' => ['bool', 'prefix'=>'string', 'name'=>'string', 'uri'=>'string'],
'XMLWriter::startCData' => ['bool'],
'XMLWriter::startComment' => ['bool'],
'XMLWriter::startDocument' => ['bool', 'version='=>'string', 'encoding='=>'string', 'standalone='=>'string'],
'XMLWriter::startDTD' => ['bool', 'qualifiedname'=>'string', 'publicid='=>'string', 'systemid='=>'string'],
'XMLWriter::startDTDAttlist' => ['bool', 'name'=>'string'],
'XMLWriter::startDTDElement' => ['bool', 'qualifiedname'=>'string'],
'XMLWriter::startDTDEntity' => ['bool', 'name'=>'string', 'isparam'=>'bool'],
'XMLWriter::startElement' => ['bool', 'name'=>'string'],
'XMLWriter::startElementNS' => ['bool', 'prefix'=>'string', 'name'=>'string', 'uri'=>'string'],
'XMLWriter::startPI' => ['bool', 'target'=>'string'],
'XMLWriter::text' => ['bool', 'content'=>'string'],
'XMLWriter::writeAttribute' => ['bool', 'name'=>'string', 'value'=>'string'],
'XMLWriter::writeAttributeNS' => ['bool', 'prefix'=>'string', 'name'=>'string', 'uri'=>'string', 'content'=>'string'],
'XMLWriter::writeCData' => ['bool', 'content'=>'string'],
'XMLWriter::writeComment' => ['bool', 'content'=>'string'],
'XMLWriter::writeDTD' => ['bool', 'name'=>'string', 'publicid='=>'string', 'systemid='=>'string', 'subset='=>'string'],
'XMLWriter::writeDTDAttlist' => ['bool', 'name'=>'string', 'content'=>'string'],
'XMLWriter::writeDTDElement' => ['bool', 'name'=>'string', 'content'=>'string'],
'XMLWriter::writeDTDEntity' => ['bool', 'name'=>'string', 'content'=>'string', 'pe'=>'bool', 'pubid'=>'string', 'sysid'=>'string', 'ndataid'=>'string'],
'XMLWriter::writeElement' => ['bool', 'name'=>'string', 'content='=>'string|null'],
'XMLWriter::writeElementNS' => ['bool', 'prefix'=>'string', 'name'=>'string', 'uri'=>'string', 'content='=>'string|null'],
'XMLWriter::writePI' => ['bool', 'target'=>'string', 'content'=>'string'],
'XMLWriter::writeRaw' => ['bool', 'content'=>'string'],
'xmlwriter_end_attribute' => ['bool', 'xmlwriter'=>'resource'],
'xmlwriter_end_cdata' => ['bool', 'xmlwriter'=>'resource'],
'xmlwriter_end_comment' => ['bool', 'xmlwriter'=>'resource'],
'xmlwriter_end_document' => ['bool', 'xmlwriter'=>'resource'],
'xmlwriter_end_dtd' => ['bool', 'xmlwriter'=>'resource'],
'xmlwriter_end_dtd_attlist' => ['bool', 'xmlwriter'=>'resource'],
'xmlwriter_end_dtd_element' => ['bool', 'xmlwriter'=>'resource'],
'xmlwriter_end_dtd_entity' => ['bool', 'xmlwriter'=>'resource'],
'xmlwriter_end_element' => ['bool', 'xmlwriter'=>'resource'],
'xmlwriter_end_pi' => ['bool', 'xmlwriter'=>'resource'],
'xmlwriter_flush' => ['', 'xmlwriter'=>'resource', 'empty='=>'bool'],
'xmlwriter_full_end_element' => ['bool', 'xmlwriter'=>'resource'],
'xmlwriter_open_memory' => ['resource'],
'xmlwriter_open_uri' => ['resource', 'source'=>'string'],
'xmlwriter_output_memory' => ['string', 'xmlwriter'=>'resource', 'flush='=>'bool'],
'xmlwriter_set_indent' => ['bool', 'xmlwriter'=>'resource', 'indent'=>'bool'],
'xmlwriter_set_indent_string' => ['bool', 'xmlwriter'=>'resource', 'indentstring'=>'string'],
'xmlwriter_start_attribute' => ['bool', 'xmlwriter'=>'resource', 'name'=>'string'],
'xmlwriter_start_attribute_ns' => ['bool', 'xmlwriter'=>'resource', 'prefix'=>'string', 'name'=>'string', 'uri'=>'string'],
'xmlwriter_start_cdata' => ['bool', 'xmlwriter'=>'resource'],
'xmlwriter_start_comment' => ['bool', 'xmlwriter'=>'resource'],
'xmlwriter_start_document' => ['bool', 'xmlwriter'=>'resource', 'version'=>'string', 'encoding'=>'string', 'standalone'=>'string'],
'xmlwriter_start_dtd' => ['bool', 'xmlwriter'=>'resource', 'name'=>'string', 'pubid'=>'string', 'sysid'=>'string'],
'xmlwriter_start_dtd_attlist' => ['bool', 'xmlwriter'=>'resource', 'name'=>'string'],
'xmlwriter_start_dtd_element' => ['bool', 'xmlwriter'=>'resource', 'name'=>'string'],
'xmlwriter_start_dtd_entity' => ['bool', 'xmlwriter'=>'resource', 'name'=>'string', 'isparam'=>'bool'],
'xmlwriter_start_element' => ['bool', 'xmlwriter'=>'resource', 'name'=>'string'],
'xmlwriter_start_element_ns' => ['bool', 'xmlwriter'=>'resource', 'prefix'=>'string', 'name'=>'string', 'uri'=>'string'],
'xmlwriter_start_pi' => ['bool', 'xmlwriter'=>'resource', 'target'=>'string'],
'xmlwriter_text' => ['bool', 'xmlwriter'=>'resource', 'content'=>'string'],
'xmlwriter_write_attribute' => ['bool', 'xmlwriter'=>'resource', 'name'=>'string', 'content'=>'string'],
'xmlwriter_write_attribute_ns' => ['bool', 'xmlwriter'=>'resource', 'prefix'=>'string', 'name'=>'string', 'uri'=>'string', 'content'=>'string'],
'xmlwriter_write_cdata' => ['bool', 'xmlwriter'=>'resource', 'content'=>'string'],
'xmlwriter_write_comment' => ['bool', 'xmlwriter'=>'resource', 'content'=>'string'],
'xmlwriter_write_dtd' => ['bool', 'xmlwriter'=>'resource', 'name'=>'string', 'pubid'=>'string', 'sysid'=>'string', 'subset'=>'string'],
'xmlwriter_write_dtd_attlist' => ['bool', 'xmlwriter'=>'resource', 'name'=>'string', 'content'=>'string'],
'xmlwriter_write_dtd_element' => ['bool', 'xmlwriter'=>'resource', 'name'=>'string', 'content'=>'string'],
'xmlwriter_write_dtd_entity' => ['bool', 'xmlwriter'=>'resource', 'name'=>'string', 'content'=>'string', 'pe'=>'int', 'pubid'=>'string', 'sysid'=>'string', 'ndataid'=>'string'],
'xmlwriter_write_element' => ['bool', 'xmlwriter'=>'resource', 'name'=>'string', 'content'=>'string'],
'xmlwriter_write_element_ns' => ['bool', 'xmlwriter'=>'resource', 'prefix'=>'string', 'name'=>'string', 'uri'=>'string', 'content'=>'string'],
'xmlwriter_write_pi' => ['bool', 'xmlwriter'=>'resource', 'target'=>'string', 'content'=>'string'],
'xmlwriter_write_raw' => ['bool', 'xmlwriter'=>'resource', 'content'=>'string'],
'xpath_new_context' => ['XPathContext', 'dom_document'=>'DOMDocument'],
'xpath_register_ns' => ['bool', 'xpath_context'=>'xpathcontext', 'prefix'=>'string', 'uri'=>'string'],
'xpath_register_ns_auto' => ['bool', 'xpath_context'=>'xpathcontext', 'context_node='=>'object'],
'xptr_new_context' => ['XPathContext'],
'xsl_xsltprocessor_get_parameter' => ['string', 'namespace'=>'string', 'name'=>'string'],
'xsl_xsltprocessor_get_security_prefs' => ['int'],
'xsl_xsltprocessor_has_exslt_support' => ['bool'],
'xsl_xsltprocessor_register_php_functions' => ['', 'restrict'=>''],
'xsl_xsltprocessor_remove_parameter' => ['bool', 'namespace'=>'string', 'name'=>'string'],
'xsl_xsltprocessor_set_parameter' => ['bool', 'namespace'=>'string', 'name'=>'', 'value'=>'string'],
'xsl_xsltprocessor_set_profiling' => ['bool', 'filename'=>'string'],
'xsl_xsltprocessor_set_security_prefs' => ['int', 'securityprefs'=>'int'],
'xsl_xsltprocessor_transform_to_uri' => ['int', 'doc'=>'DOMDocument', 'uri'=>'string'],
'xsl_xsltprocessor_transform_to_xml' => ['string', 'doc'=>'DOMDocument'],
'xslt_backend_info' => ['string'],
'xslt_backend_name' => ['string'],
'xslt_backend_version' => ['string'],
'xslt_create' => ['resource'],
'xslt_errno' => ['int', 'xh'=>''],
'xslt_error' => ['string', 'xh'=>''],
'xslt_free' => ['', 'xh'=>''],
'xslt_getopt' => ['int', 'processor'=>''],
'xslt_process' => ['', 'xh'=>'', 'xmlcontainer'=>'string', 'xslcontainer'=>'string', 'resultcontainer='=>'string', 'arguments='=>'array', 'parameters='=>'array'],
'xslt_set_base' => ['', 'xh'=>'', 'uri'=>'string'],
'xslt_set_encoding' => ['', 'xh'=>'', 'encoding'=>'string'],
'xslt_set_error_handler' => ['', 'xh'=>'', 'handler'=>''],
'xslt_set_log' => ['', 'xh'=>'', 'log='=>''],
'xslt_set_object' => ['bool', 'processor'=>'', 'obj'=>'object'],
'xslt_set_sax_handler' => ['', 'xh'=>'', 'handlers'=>'array'],
'xslt_set_sax_handlers' => ['', 'processor'=>'', 'handlers'=>'array'],
'xslt_set_scheme_handler' => ['', 'xh'=>'', 'handlers'=>'array'],
'xslt_set_scheme_handlers' => ['', 'xh'=>'', 'handlers'=>'array'],
'xslt_setopt' => ['', 'processor'=>'', 'newmask'=>'int'],
'XSLTProcessor::getParameter' => ['string', 'namespaceuri'=>'string', 'localname'=>'string'],
'XsltProcessor::getSecurityPrefs' => ['int'],
'XSLTProcessor::hasExsltSupport' => ['bool'],
'XSLTProcessor::importStylesheet' => ['bool', 'stylesheet'=>'object'],
'XSLTProcessor::registerPHPFunctions' => ['void', 'restrict='=>'mixed'],
'XSLTProcessor::removeParameter' => ['bool', 'namespaceuri'=>'string', 'localname'=>'string'],
'XSLTProcessor::setParameter' => ['bool', 'namespace'=>'string', 'name'=>'string', 'value'=>'string'],
'XSLTProcessor::setParameter\'1' => ['bool', 'namespace'=>'string', 'options'=>'array'],
'XSLTProcessor::setProfiling' => ['bool', 'filename'=>'string'],
'XsltProcessor::setSecurityPrefs' => ['int', 'securityPrefs'=>'int'],
'XSLTProcessor::transformToDoc' => ['DOMDocument', 'doc'=>'DOMNode'],
'XSLTProcessor::transformToURI' => ['int', 'doc'=>'DOMDocument', 'uri'=>'string'],
'XSLTProcessor::transformToXML' => ['string', 'doc'=>'DOMDocument'],
'Yaconf::get' => ['mixed', 'name'=>'string', 'default_value='=>'mixed'],
'Yaconf::has' => ['bool', 'name'=>'string'],
'Yaf_Action_Abstract::__construct' => ['void', 'request'=>'Yaf_Request_Abstract', 'response'=>'Yaf_Response_Abstract', 'view'=>'Yaf_View_Interface', 'invokeArgs='=>'?array'],
'Yaf_Action_Abstract::display' => ['bool', 'tpl'=>'string', 'parameters='=>'?array'],
'Yaf_Action_Abstract::execute' => ['mixed', 'arg='=>'mixed', '...args='=>'mixed'],
'Yaf_Action_Abstract::forward' => ['bool', 'module'=>'string', 'controller='=>'string', 'action='=>'string', 'parameters='=>'?array'],
'Yaf_Action_Abstract::getController' => ['Yaf_Controller_Abstract'],
'Yaf_Action_Abstract::getInvokeArg' => ['mixed|null', 'name'=>'string'],
'Yaf_Action_Abstract::getInvokeArgs' => ['array'],
'Yaf_Action_Abstract::getModuleName' => ['string'],
'Yaf_Action_Abstract::getRequest' => ['Yaf_Request_Abstract'],
'Yaf_Action_Abstract::getResponse' => ['Yaf_Response_Abstract'],
'Yaf_Action_Abstract::getView' => ['Yaf_View_Interface'],
'Yaf_Action_Abstract::getViewpath' => ['string'],
'Yaf_Action_Abstract::init' => [''],
'Yaf_Action_Abstract::initView' => ['Yaf_Response_Abstract', 'options='=>'?array'],
'Yaf_Action_Abstract::redirect' => ['bool', 'url'=>'string'],
'Yaf_Action_Abstract::render' => ['string', 'tpl'=>'string', 'parameters='=>'?array'],
'Yaf_Action_Abstract::setViewpath' => ['bool', 'view_directory'=>'string'],
'Yaf_Application::__clone' => ['void'],
'Yaf_Application::__construct' => ['void', 'config'=>'mixed', 'envrion='=>'string'],
'Yaf_Application::__destruct' => ['void'],
'Yaf_Application::__sleep' => ['void'],
'Yaf_Application::__wakeup' => ['void'],
'Yaf_Application::app' => ['void'],
'Yaf_Application::bootstrap' => ['void', 'bootstrap='=>'Yaf_Bootstrap_Abstract'],
'Yaf_Application::clearLastError' => ['Yaf_Application'],
'Yaf_Application::environ' => ['void'],
'Yaf_Application::execute' => ['void', 'entry'=>'callable', '...args'=>'string'],
'Yaf_Application::getAppDirectory' => ['Yaf_Application'],
'Yaf_Application::getConfig' => ['Yaf_Config_Abstract'],
'Yaf_Application::getDispatcher' => ['Yaf_Dispatcher'],
'Yaf_Application::getLastErrorMsg' => ['string'],
'Yaf_Application::getLastErrorNo' => ['int'],
'Yaf_Application::getModules' => ['array'],
'Yaf_Application::run' => ['void'],
'Yaf_Application::setAppDirectory' => ['Yaf_Application', 'directory'=>'string'],
'Yaf_Config_Abstract::get' => ['mixed', 'name'=>'string', 'value'=>'mixed'],
'Yaf_Config_Abstract::readonly' => ['bool'],
'Yaf_Config_Abstract::set' => ['Yaf_Config_Abstract'],
'Yaf_Config_Abstract::toArray' => ['array'],
'Yaf_Config_Ini::__construct' => ['void', 'config_file'=>'string', 'section='=>'string'],
'Yaf_Config_Ini::__get' => ['void', 'name='=>'string'],
'Yaf_Config_Ini::__isset' => ['void', 'name'=>'string'],
'Yaf_Config_Ini::__set' => ['void', 'name'=>'string', 'value'=>'mixed'],
'Yaf_Config_Ini::count' => ['void'],
'Yaf_Config_Ini::current' => ['void'],
'Yaf_Config_Ini::get' => ['mixed', 'name='=>'mixed'],
'Yaf_Config_Ini::key' => ['void'],
'Yaf_Config_Ini::next' => ['void'],
'Yaf_Config_Ini::offsetExists' => ['void', 'name'=>'string'],
'Yaf_Config_Ini::offsetGet' => ['void', 'name'=>'string'],
'Yaf_Config_Ini::offsetSet' => ['void', 'name'=>'string', 'value'=>'string'],
'Yaf_Config_Ini::offsetUnset' => ['void', 'name'=>'string'],
'Yaf_Config_Ini::readonly' => ['void'],
'Yaf_Config_Ini::rewind' => ['void'],
'Yaf_Config_Ini::set' => ['Yaf_Config_Abstract', 'name'=>'string', 'value'=>'mixed'],
'Yaf_Config_Ini::toArray' => ['array'],
'Yaf_Config_Ini::valid' => ['void'],
'Yaf_Config_Simple::__construct' => ['void', 'config_file'=>'string', 'section='=>'string'],
'Yaf_Config_Simple::__get' => ['void', 'name='=>'string'],
'Yaf_Config_Simple::__isset' => ['void', 'name'=>'string'],
'Yaf_Config_Simple::__set' => ['void', 'name'=>'string', 'value'=>'string'],
'Yaf_Config_Simple::count' => ['void'],
'Yaf_Config_Simple::current' => ['void'],
'Yaf_Config_Simple::get' => ['mixed', 'name='=>'mixed'],
'Yaf_Config_Simple::key' => ['void'],
'Yaf_Config_Simple::next' => ['void'],
'Yaf_Config_Simple::offsetExists' => ['void', 'name'=>'string'],
'Yaf_Config_Simple::offsetGet' => ['void', 'name'=>'string'],
'Yaf_Config_Simple::offsetSet' => ['void', 'name'=>'string', 'value'=>'string'],
'Yaf_Config_Simple::offsetUnset' => ['void', 'name'=>'string'],
'Yaf_Config_Simple::readonly' => ['void'],
'Yaf_Config_Simple::rewind' => ['void'],
'Yaf_Config_Simple::set' => ['Yaf_Config_Abstract', 'name'=>'string', 'value'=>'mixed'],
'Yaf_Config_Simple::toArray' => ['array'],
'Yaf_Config_Simple::valid' => ['void'],
'Yaf_Controller_Abstract::__clone' => ['void'],
'Yaf_Controller_Abstract::__construct' => ['void'],
'Yaf_Controller_Abstract::display' => ['bool', 'tpl'=>'string', 'parameters='=>'array'],
'Yaf_Controller_Abstract::forward' => ['void', 'action'=>'string', 'parameters='=>'array'],
'Yaf_Controller_Abstract::forward\'1' => ['void', 'controller'=>'string', 'action'=>'string', 'parameters='=>'array'],
'Yaf_Controller_Abstract::forward\'2' => ['void', 'module'=>'string', 'controller'=>'string', 'action'=>'string', 'parameters='=>'array'],
'Yaf_Controller_Abstract::getInvokeArg' => ['void', 'name'=>'string'],
'Yaf_Controller_Abstract::getInvokeArgs' => ['void'],
'Yaf_Controller_Abstract::getModuleName' => ['string'],
'Yaf_Controller_Abstract::getRequest' => ['Yaf_Request_Abstract'],
'Yaf_Controller_Abstract::getResponse' => ['Yaf_Response_Abstract'],
'Yaf_Controller_Abstract::getView' => ['Yaf_View_Interface'],
'Yaf_Controller_Abstract::getViewpath' => ['void'],
'Yaf_Controller_Abstract::init' => ['void'],
'Yaf_Controller_Abstract::initView' => ['void', 'options='=>'array'],
'Yaf_Controller_Abstract::redirect' => ['bool', 'url'=>'string'],
'Yaf_Controller_Abstract::render' => ['string', 'tpl'=>'string', 'parameters='=>'array'],
'Yaf_Controller_Abstract::setViewpath' => ['void', 'view_directory'=>'string'],
'Yaf_Dispatcher::__clone' => ['void'],
'Yaf_Dispatcher::__construct' => ['void'],
'Yaf_Dispatcher::__sleep' => ['void'],
'Yaf_Dispatcher::__wakeup' => ['void'],
'Yaf_Dispatcher::autoRender' => ['Yaf_Dispatcher', 'flag='=>'bool'],
'Yaf_Dispatcher::catchException' => ['Yaf_Dispatcher', 'flag='=>'bool'],
'Yaf_Dispatcher::disableView' => ['bool'],
'Yaf_Dispatcher::dispatch' => ['Yaf_Response_Abstract', 'request'=>'Yaf_Request_Abstract'],
'Yaf_Dispatcher::enableView' => ['Yaf_Dispatcher'],
'Yaf_Dispatcher::flushInstantly' => ['Yaf_Dispatcher', 'flag='=>'bool'],
'Yaf_Dispatcher::getApplication' => ['Yaf_Application'],
'Yaf_Dispatcher::getInstance' => ['Yaf_Dispatcher'],
'Yaf_Dispatcher::getRequest' => ['Yaf_Request_Abstract'],
'Yaf_Dispatcher::getRouter' => ['Yaf_Router'],
'Yaf_Dispatcher::initView' => ['Yaf_View_Interface', 'templates_dir'=>'string', 'options='=>'array'],
'Yaf_Dispatcher::registerPlugin' => ['Yaf_Dispatcher', 'plugin'=>'Yaf_Plugin_Abstract'],
'Yaf_Dispatcher::returnResponse' => ['Yaf_Dispatcher', 'flag'=>'bool'],
'Yaf_Dispatcher::setDefaultAction' => ['Yaf_Dispatcher', 'action'=>'string'],
'Yaf_Dispatcher::setDefaultController' => ['Yaf_Dispatcher', 'controller'=>'string'],
'Yaf_Dispatcher::setDefaultModule' => ['Yaf_Dispatcher', 'module'=>'string'],
'Yaf_Dispatcher::setErrorHandler' => ['Yaf_Dispatcher', 'callback'=>'call', 'error_types'=>'int'],
'Yaf_Dispatcher::setRequest' => ['Yaf_Dispatcher', 'request'=>'Yaf_Request_Abstract'],
'Yaf_Dispatcher::setView' => ['Yaf_Dispatcher', 'view'=>'Yaf_View_Interface'],
'Yaf_Dispatcher::throwException' => ['Yaf_Dispatcher', 'flag='=>'bool'],
'Yaf_Exception::__construct' => ['void'],
'Yaf_Exception::getPrevious' => ['void'],
'Yaf_Loader::__clone' => ['void'],
'Yaf_Loader::__construct' => ['void'],
'Yaf_Loader::__sleep' => ['void'],
'Yaf_Loader::__wakeup' => ['void'],
'Yaf_Loader::autoload' => ['void'],
'Yaf_Loader::clearLocalNamespace' => ['void'],
'Yaf_Loader::getInstance' => ['void'],
'Yaf_Loader::getLibraryPath' => ['Yaf_Loader', 'is_global='=>'bool'],
'Yaf_Loader::getLocalNamespace' => ['void'],
'Yaf_Loader::import' => ['void'],
'Yaf_Loader::isLocalName' => ['void'],
'Yaf_Loader::registerLocalNamespace' => ['void', 'prefix'=>'mixed'],
'Yaf_Loader::setLibraryPath' => ['Yaf_Loader', 'directory'=>'string', 'is_global='=>'bool'],
'Yaf_Plugin_Abstract::dispatchLoopShutdown' => ['void', 'request'=>'Yaf_Request_Abstract', 'response'=>'Yaf_Response_Abstract'],
'Yaf_Plugin_Abstract::dispatchLoopStartup' => ['void', 'request'=>'Yaf_Request_Abstract', 'response'=>'Yaf_Response_Abstract'],
'Yaf_Plugin_Abstract::postDispatch' => ['void', 'request'=>'Yaf_Request_Abstract', 'response'=>'Yaf_Response_Abstract'],
'Yaf_Plugin_Abstract::preDispatch' => ['void', 'request'=>'Yaf_Request_Abstract', 'response'=>'Yaf_Response_Abstract'],
'Yaf_Plugin_Abstract::preResponse' => ['void', 'request'=>'Yaf_Request_Abstract', 'response'=>'Yaf_Response_Abstract'],
'Yaf_Plugin_Abstract::routerShutdown' => ['void', 'request'=>'Yaf_Request_Abstract', 'response'=>'Yaf_Response_Abstract'],
'Yaf_Plugin_Abstract::routerStartup' => ['void', 'request'=>'Yaf_Request_Abstract', 'response'=>'Yaf_Response_Abstract'],
'Yaf_Registry::__clone' => ['void'],
'Yaf_Registry::__construct' => ['void'],
'Yaf_Registry::del' => ['void', 'name'=>'string'],
'Yaf_Registry::get' => ['mixed', 'name'=>'string'],
'Yaf_Registry::has' => ['bool', 'name'=>'string'],
'Yaf_Registry::set' => ['bool', 'name'=>'string', 'value'=>'string'],
'Yaf_Request_Abstract::getActionName' => ['void'],
'Yaf_Request_Abstract::getBaseUri' => ['void'],
'Yaf_Request_Abstract::getControllerName' => ['void'],
'Yaf_Request_Abstract::getEnv' => ['void', 'name'=>'string', 'default='=>'string'],
'Yaf_Request_Abstract::getException' => ['void'],
'Yaf_Request_Abstract::getLanguage' => ['void'],
'Yaf_Request_Abstract::getMethod' => ['void'],
'Yaf_Request_Abstract::getModuleName' => ['void'],
'Yaf_Request_Abstract::getParam' => ['void', 'name'=>'string', 'default='=>'string'],
'Yaf_Request_Abstract::getParams' => ['void'],
'Yaf_Request_Abstract::getRequestUri' => ['void'],
'Yaf_Request_Abstract::getServer' => ['void', 'name'=>'string', 'default='=>'string'],
'Yaf_Request_Abstract::isCli' => ['void'],
'Yaf_Request_Abstract::isDispatched' => ['void'],
'Yaf_Request_Abstract::isGet' => ['void'],
'Yaf_Request_Abstract::isHead' => ['void'],
'Yaf_Request_Abstract::isOptions' => ['void'],
'Yaf_Request_Abstract::isPost' => ['void'],
'Yaf_Request_Abstract::isPut' => ['void'],
'Yaf_Request_Abstract::isRouted' => ['void'],
'Yaf_Request_Abstract::isXmlHttpRequest' => ['void'],
'Yaf_Request_Abstract::setActionName' => ['void', 'action'=>'string'],
'Yaf_Request_Abstract::setBaseUri' => ['bool', 'uir'=>'string'],
'Yaf_Request_Abstract::setControllerName' => ['void', 'controller'=>'string'],
'Yaf_Request_Abstract::setDispatched' => ['void'],
'Yaf_Request_Abstract::setModuleName' => ['void', 'module'=>'string'],
'Yaf_Request_Abstract::setParam' => ['void', 'name'=>'string', 'value='=>'string'],
'Yaf_Request_Abstract::setRequestUri' => ['void', 'uir'=>'string'],
'Yaf_Request_Abstract::setRouted' => ['void', 'flag='=>'string'],
'Yaf_Request_Http::__clone' => ['void'],
'Yaf_Request_Http::__construct' => ['void'],
'Yaf_Request_Http::get' => ['mixed', 'name'=>'string', 'default='=>'string'],
'Yaf_Request_Http::getActionName' => ['string'],
'Yaf_Request_Http::getBaseUri' => ['string'],
'Yaf_Request_Http::getControllerName' => ['string'],
'Yaf_Request_Http::getCookie' => ['mixed', 'name'=>'string', 'default='=>'string'],
'Yaf_Request_Http::getEnv' => ['mixed', 'name='=>'string', 'default='=>'mixed'],
'Yaf_Request_Http::getException' => ['Yaf_Exception'],
'Yaf_Request_Http::getFiles' => ['void'],
'Yaf_Request_Http::getLanguage' => ['string'],
'Yaf_Request_Http::getMethod' => ['string'],
'Yaf_Request_Http::getModuleName' => ['string'],
'Yaf_Request_Http::getParam' => ['mixed', 'name'=>'string', 'default='=>'mixed'],
'Yaf_Request_Http::getParams' => ['array'],
'Yaf_Request_Http::getPost' => ['mixed', 'name'=>'string', 'default='=>'string'],
'Yaf_Request_Http::getQuery' => ['mixed', 'name'=>'string', 'default='=>'string'],
'Yaf_Request_Http::getRaw' => ['mixed'],
'Yaf_Request_Http::getRequest' => ['void'],
'Yaf_Request_Http::getRequestUri' => ['string'],
'Yaf_Request_Http::getServer' => ['mixed', 'name='=>'string', 'default='=>'mixed'],
'Yaf_Request_Http::isCli' => ['bool'],
'Yaf_Request_Http::isDispatched' => ['bool'],
'Yaf_Request_Http::isGet' => ['bool'],
'Yaf_Request_Http::isHead' => ['bool'],
'Yaf_Request_Http::isOptions' => ['bool'],
'Yaf_Request_Http::isPost' => ['bool'],
'Yaf_Request_Http::isPut' => ['bool'],
'Yaf_Request_Http::isRouted' => ['bool'],
'Yaf_Request_Http::isXmlHttpRequest' => ['bool'],
'Yaf_Request_Http::setActionName' => ['Yaf_Request_Abstract|bool', 'action'=>'string'],
'Yaf_Request_Http::setBaseUri' => ['bool', 'uri'=>'string'],
'Yaf_Request_Http::setControllerName' => ['Yaf_Request_Abstract|bool', 'controller'=>'string'],
'Yaf_Request_Http::setDispatched' => ['bool'],
'Yaf_Request_Http::setModuleName' => ['Yaf_Request_Abstract|bool', 'module'=>'string'],
'Yaf_Request_Http::setParam' => ['Yaf_Request_Abstract|bool', 'name'=>'array|string', 'value='=>'string'],
'Yaf_Request_Http::setRequestUri' => ['', 'uri'=>'string'],
'Yaf_Request_Http::setRouted' => ['Yaf_Request_Abstract|bool'],
'Yaf_Request_Simple::__clone' => ['void'],
'Yaf_Request_Simple::__construct' => ['void'],
'Yaf_Request_Simple::get' => ['void'],
'Yaf_Request_Simple::getActionName' => ['string'],
'Yaf_Request_Simple::getBaseUri' => ['string'],
'Yaf_Request_Simple::getControllerName' => ['string'],
'Yaf_Request_Simple::getCookie' => ['void'],
'Yaf_Request_Simple::getEnv' => ['mixed', 'name='=>'string', 'default='=>'mixed'],
'Yaf_Request_Simple::getException' => ['Yaf_Exception'],
'Yaf_Request_Simple::getFiles' => ['void'],
'Yaf_Request_Simple::getLanguage' => ['string'],
'Yaf_Request_Simple::getMethod' => ['string'],
'Yaf_Request_Simple::getModuleName' => ['string'],
'Yaf_Request_Simple::getParam' => ['mixed', 'name'=>'string', 'default='=>'mixed'],
'Yaf_Request_Simple::getParams' => ['array'],
'Yaf_Request_Simple::getPost' => ['void'],
'Yaf_Request_Simple::getQuery' => ['void'],
'Yaf_Request_Simple::getRequest' => ['void'],
'Yaf_Request_Simple::getRequestUri' => ['string'],
'Yaf_Request_Simple::getServer' => ['mixed', 'name='=>'string', 'default='=>'mixed'],
'Yaf_Request_Simple::isCli' => ['bool'],
'Yaf_Request_Simple::isDispatched' => ['bool'],
'Yaf_Request_Simple::isGet' => ['bool'],
'Yaf_Request_Simple::isHead' => ['bool'],
'Yaf_Request_Simple::isOptions' => ['bool'],
'Yaf_Request_Simple::isPost' => ['bool'],
'Yaf_Request_Simple::isPut' => ['bool'],
'Yaf_Request_Simple::isRouted' => ['bool'],
'Yaf_Request_Simple::isXmlHttpRequest' => ['void'],
'Yaf_Request_Simple::setActionName' => ['Yaf_Request_Abstract|bool', 'action'=>'string'],
'Yaf_Request_Simple::setBaseUri' => ['bool', 'uri'=>'string'],
'Yaf_Request_Simple::setControllerName' => ['Yaf_Request_Abstract|bool', 'controller'=>'string'],
'Yaf_Request_Simple::setDispatched' => ['bool'],
'Yaf_Request_Simple::setModuleName' => ['Yaf_Request_Abstract|bool', 'module'=>'string'],
'Yaf_Request_Simple::setParam' => ['Yaf_Request_Abstract|bool', 'name'=>'array|string', 'value='=>'string'],
'Yaf_Request_Simple::setRequestUri' => ['', 'uri'=>'string'],
'Yaf_Request_Simple::setRouted' => ['Yaf_Request_Abstract|bool'],
'Yaf_Response_Abstract::__clone' => ['void'],
'Yaf_Response_Abstract::__construct' => ['void'],
'Yaf_Response_Abstract::__destruct' => ['void'],
'Yaf_Response_Abstract::__toString' => ['string'],
'Yaf_Response_Abstract::appendBody' => ['bool', 'content'=>'string', 'key='=>'string'],
'Yaf_Response_Abstract::clearBody' => ['bool', 'key='=>'string'],
'Yaf_Response_Abstract::clearHeaders' => ['void'],
'Yaf_Response_Abstract::getBody' => ['mixed', 'key='=>'string'],
'Yaf_Response_Abstract::getHeader' => ['void'],
'Yaf_Response_Abstract::prependBody' => ['bool', 'content'=>'string', 'key='=>'string'],
'Yaf_Response_Abstract::response' => ['void'],
'Yaf_Response_Abstract::setAllHeaders' => ['void'],
'Yaf_Response_Abstract::setBody' => ['bool', 'content'=>'string', 'key='=>'string'],
'Yaf_Response_Abstract::setHeader' => ['void'],
'Yaf_Response_Abstract::setRedirect' => ['void'],
'Yaf_Response_Cli::__clone' => [''],
'Yaf_Response_Cli::__construct' => ['void'],
'Yaf_Response_Cli::__destruct' => [''],
'Yaf_Response_Cli::__toString' => ['string'],
'Yaf_Response_Cli::appendBody' => ['bool', 'content'=>'string', 'key='=>'string'],
'Yaf_Response_Cli::clearBody' => ['bool', 'key='=>'string'],
'Yaf_Response_Cli::getBody' => ['mixed', 'key='=>'null|string'],
'Yaf_Response_Cli::prependBody' => ['bool', 'content'=>'string', 'key='=>'string'],
'Yaf_Response_Cli::setBody' => ['bool', 'content'=>'string', 'key='=>'string'],
'Yaf_Response_Http::__clone' => [''],
'Yaf_Response_Http::__construct' => ['void'],
'Yaf_Response_Http::__destruct' => [''],
'Yaf_Response_Http::__toString' => ['string'],
'Yaf_Response_Http::appendBody' => ['bool', 'content'=>'string', 'key='=>'string'],
'Yaf_Response_Http::clearBody' => ['bool', 'key='=>'string'],
'Yaf_Response_Http::clearHeaders' => ['Yaf_Response_Abstract|false', 'name='=>'string'],
'Yaf_Response_Http::getBody' => ['mixed', 'key='=>'null|string'],
'Yaf_Response_Http::getHeader' => ['mixed', 'name='=>'string'],
'Yaf_Response_Http::prependBody' => ['bool', 'content'=>'string', 'key='=>'string'],
'Yaf_Response_Http::response' => ['bool'],
'Yaf_Response_Http::setAllHeaders' => ['bool', 'headers'=>'array'],
'Yaf_Response_Http::setBody' => ['bool', 'content'=>'string', 'key='=>'string'],
'Yaf_Response_Http::setHeader' => ['bool', 'name'=>'string', 'value'=>'string', 'replace='=>'bool|false', 'response_code='=>'int'],
'Yaf_Response_Http::setRedirect' => ['bool', 'url'=>'string'],
'Yaf_Route_Interface::__construct' => ['void'],
'Yaf_Route_Interface::assemble' => ['string', 'info'=>'array', 'query='=>'array'],
'Yaf_Route_Interface::route' => ['bool', 'request'=>'Yaf_Request_Abstract'],
'Yaf_Route_Map::__construct' => ['void', 'controller_prefer='=>'string', 'delimiter='=>'string'],
'Yaf_Route_Map::assemble' => ['string', 'info'=>'array', 'query='=>'array'],
'Yaf_Route_Map::route' => ['bool', 'request'=>'Yaf_Request_Abstract'],
'Yaf_Route_Regex::__construct' => ['void', 'match'=>'string', 'route'=>'array', 'map='=>'array', 'verify='=>'array', 'reverse='=>'string'],
'Yaf_Route_Regex::addConfig' => ['Yaf_Router|bool', 'config'=>'Yaf_Config_Abstract'],
'Yaf_Route_Regex::addRoute' => ['Yaf_Router|bool', 'name'=>'string', 'route'=>'Yaf_Route_Interface'],
'Yaf_Route_Regex::assemble' => ['string', 'info'=>'array', 'query='=>'array'],
'Yaf_Route_Regex::getCurrentRoute' => ['string'],
'Yaf_Route_Regex::getRoute' => ['Yaf_Route_Interface', 'name'=>'string'],
'Yaf_Route_Regex::getRoutes' => ['Yaf_Route_Interface[]'],
'Yaf_Route_Regex::route' => ['bool', 'request'=>'Yaf_Request_Abstract'],
'Yaf_Route_Rewrite::__construct' => ['void', 'match'=>'string', 'route'=>'array', 'verify='=>'array'],
'Yaf_Route_Rewrite::addConfig' => ['Yaf_Router|bool', 'config'=>'Yaf_Config_Abstract'],
'Yaf_Route_Rewrite::addRoute' => ['Yaf_Router|bool', 'name'=>'string', 'route'=>'Yaf_Route_Interface'],
'Yaf_Route_Rewrite::assemble' => ['string', 'info'=>'array', 'query='=>'array'],
'Yaf_Route_Rewrite::getCurrentRoute' => ['string'],
'Yaf_Route_Rewrite::getRoute' => ['Yaf_Route_Interface', 'name'=>'string'],
'Yaf_Route_Rewrite::getRoutes' => ['Yaf_Route_Interface[]'],
'Yaf_Route_Rewrite::route' => ['bool', 'request'=>'Yaf_Request_Abstract'],
'Yaf_Route_Simple::__construct' => ['void', 'module_name'=>'string', 'controller_name'=>'string', 'action_name'=>'string'],
'Yaf_Route_Simple::assemble' => ['string', 'info'=>'array', 'query='=>'array'],
'Yaf_Route_Simple::route' => ['bool', 'request'=>'Yaf_Request_Abstract'],
'Yaf_Route_Static::assemble' => ['string', 'info'=>'array', 'query='=>'array'],
'Yaf_Route_Static::match' => ['void', 'uri'=>'string'],
'Yaf_Route_Static::route' => ['bool', 'request'=>'Yaf_Request_Abstract'],
'Yaf_Route_Supervar::__construct' => ['void', 'supervar_name'=>'string'],
'Yaf_Route_Supervar::assemble' => ['string', 'info'=>'array', 'query='=>'array'],
'Yaf_Route_Supervar::route' => ['bool', 'request'=>'Yaf_Request_Abstract'],
'Yaf_Router::__construct' => ['void'],
'Yaf_Router::addConfig' => ['bool', 'config'=>'Yaf_Config_Abstract'],
'Yaf_Router::addRoute' => ['bool', 'name'=>'string', 'route'=>'Yaf_Route_Abstract'],
'Yaf_Router::getCurrentRoute' => ['string'],
'Yaf_Router::getRoute' => ['Yaf_Route_Interface', 'name'=>'string'],
'Yaf_Router::getRoutes' => ['mixed'],
'Yaf_Router::route' => ['bool', 'request'=>'Yaf_Request_Abstract'],
'Yaf_Session::__clone' => ['void'],
'Yaf_Session::__construct' => ['void'],
'Yaf_Session::__get' => ['void', 'name'=>'string'],
'Yaf_Session::__isset' => ['void', 'name'=>'string'],
'Yaf_Session::__set' => ['void', 'name'=>'string', 'value'=>'string'],
'Yaf_Session::__sleep' => ['void'],
'Yaf_Session::__unset' => ['void', 'name'=>'string'],
'Yaf_Session::__wakeup' => ['void'],
'Yaf_Session::count' => ['void'],
'Yaf_Session::current' => ['void'],
'Yaf_Session::del' => ['void', 'name'=>'string'],
'Yaf_Session::get' => ['mixed', 'name'=>'string'],
'Yaf_Session::getInstance' => ['void'],
'Yaf_Session::has' => ['void', 'name'=>'string'],
'Yaf_Session::key' => ['void'],
'Yaf_Session::next' => ['void'],
'Yaf_Session::offsetExists' => ['void', 'name'=>'string'],
'Yaf_Session::offsetGet' => ['void', 'name'=>'string'],
'Yaf_Session::offsetSet' => ['void', 'name'=>'string', 'value'=>'string'],
'Yaf_Session::offsetUnset' => ['void', 'name'=>'string'],
'Yaf_Session::rewind' => ['void'],
'Yaf_Session::set' => ['Yaf_Session|bool', 'name'=>'string', 'value'=>'mixed'],
'Yaf_Session::start' => ['void'],
'Yaf_Session::valid' => ['void'],
'Yaf_View_Interface::assign' => ['bool', 'name'=>'string', 'value='=>'string'],
'Yaf_View_Interface::display' => ['bool', 'tpl'=>'string', 'tpl_vars='=>'array'],
'Yaf_View_Interface::getScriptPath' => ['void'],
'Yaf_View_Interface::render' => ['string', 'tpl'=>'string', 'tpl_vars='=>'array'],
'Yaf_View_Interface::setScriptPath' => ['void', 'template_dir'=>'string'],
'Yaf_View_Simple::__construct' => ['void', 'tempalte_dir'=>'string', 'options='=>'array'],
'Yaf_View_Simple::__get' => ['void', 'name='=>'string'],
'Yaf_View_Simple::__isset' => ['void', 'name'=>'string'],
'Yaf_View_Simple::__set' => ['void', 'name'=>'string', 'value'=>'mixed'],
'Yaf_View_Simple::assign' => ['bool', 'name'=>'string', 'value='=>'mixed'],
'Yaf_View_Simple::assignRef' => ['bool', 'name'=>'string', '&rw_value'=>'mixed'],
'Yaf_View_Simple::clear' => ['bool', 'name='=>'string'],
'Yaf_View_Simple::display' => ['bool', 'tpl'=>'string', 'tpl_vars='=>'array'],
'Yaf_View_Simple::eval' => ['string', 'tpl_content'=>'string', 'tpl_vars='=>'array'],
'Yaf_View_Simple::getScriptPath' => ['string'],
'Yaf_View_Simple::render' => ['string', 'tpl'=>'string', 'tpl_vars='=>'array'],
'Yaf_View_Simple::setScriptPath' => ['bool', 'template_dir'=>'string'],
'yaml_emit' => ['string', 'data'=>'mixed', 'encoding='=>'int', 'linebreak='=>'int'],
'yaml_emit_file' => ['bool', 'filename'=>'string', 'data'=>'mixed', 'encoding='=>'int', 'linebreak='=>'int'],
'yaml_parse' => ['mixed', 'input'=>'string', 'pos='=>'int', 'ndocs='=>'int', 'callbacks='=>'array'],
'yaml_parse_file' => ['mixed', 'filename'=>'string', 'pos='=>'int', 'ndocs='=>'int', 'callbacks='=>'array'],
'yaml_parse_url' => ['mixed', 'url'=>'string', 'pos='=>'int', 'ndocs='=>'int', 'callbacks='=>'array'],
'Yar_Client::__call' => ['void', 'method'=>'string', 'parameters'=>'array'],
'Yar_Client::__construct' => ['void', 'url'=>'string'],
'Yar_Client::setOpt' => ['bool', 'name'=>'int', 'value'=>'mixed'],
'Yar_Client_Exception::getType' => ['void'],
'Yar_Concurrent_Client::call' => ['int', 'uri'=>'string', 'method'=>'string', 'parameters'=>'array', 'callback='=>'callable'],
'Yar_Concurrent_Client::loop' => ['bool', 'callback='=>'callable', 'error_callback='=>'callable'],
'Yar_Concurrent_Client::reset' => ['bool'],
'Yar_Server::__construct' => ['void', 'obj'=>'Object'],
'Yar_Server::handle' => ['bool'],
'Yar_Server_Exception::getType' => ['string'],
'yaz_addinfo' => ['string', 'id'=>'resource'],
'yaz_ccl_conf' => ['void', 'id'=>'resource', 'config'=>'array'],
'yaz_ccl_parse' => ['bool', 'id'=>'resource', 'query'=>'string', 'result'=>'array'],
'yaz_close' => ['bool', 'id'=>'resource'],
'yaz_connect' => ['mixed', 'zurl'=>'string', 'options='=>'mixed'],
'yaz_database' => ['bool', 'id'=>'resource', 'databases'=>'string'],
'yaz_element' => ['bool', 'id'=>'resource', 'elementset'=>'string'],
'yaz_errno' => ['int', 'id'=>'resource'],
'yaz_error' => ['string', 'id'=>'resource'],
'yaz_es' => ['void', 'id'=>'resource', 'type'=>'string', 'args'=>'array'],
'yaz_es_result' => ['array', 'id'=>'resource'],
'yaz_get_option' => ['string', 'id'=>'resource', 'name'=>'string'],
'yaz_hits' => ['int', 'id'=>'resource', 'searchresult='=>'array'],
'yaz_itemorder' => ['void', 'id'=>'resource', 'args'=>'array'],
'yaz_present' => ['bool', 'id'=>'resource'],
'yaz_range' => ['void', 'id'=>'resource', 'start'=>'int', 'number'=>'int'],
'yaz_record' => ['string', 'id'=>'resource', 'pos'=>'int', 'type'=>'string'],
'yaz_scan' => ['void', 'id'=>'resource', 'type'=>'string', 'startterm'=>'string', 'flags='=>'array'],
'yaz_scan_result' => ['array', 'id'=>'resource', 'result='=>'array'],
'yaz_schema' => ['void', 'id'=>'resource', 'schema'=>'string'],
'yaz_search' => ['bool', 'id'=>'resource', 'type'=>'string', 'query'=>'string'],
'yaz_set_option' => ['', 'id'=>'', 'name'=>'string', 'value'=>'string', 'options'=>'array'],
'yaz_sort' => ['void', 'id'=>'resource', 'criteria'=>'string'],
'yaz_syntax' => ['void', 'id'=>'resource', 'syntax'=>'string'],
'yaz_wait' => ['mixed', 'options='=>'array'],
'yp_all' => ['void', 'domain'=>'string', 'map'=>'string', 'callback'=>'string'],
'yp_cat' => ['array', 'domain'=>'string', 'map'=>'string'],
'yp_err_string' => ['string', 'errorcode'=>'int'],
'yp_errno' => ['int'],
'yp_first' => ['array', 'domain'=>'string', 'map'=>'string'],
'yp_get_default_domain' => ['string'],
'yp_master' => ['string', 'domain'=>'string', 'map'=>'string'],
'yp_match' => ['string', 'domain'=>'string', 'map'=>'string', 'key'=>'string'],
'yp_next' => ['array', 'domain'=>'string', 'map'=>'string', 'key'=>'string'],
'yp_order' => ['int', 'domain'=>'string', 'map'=>'string'],
'zem_get_extension_info_by_id' => [''],
'zem_get_extension_info_by_name' => [''],
'zem_get_extensions_info' => [''],
'zem_get_license_info' => [''],
'zend_current_obfuscation_level' => ['int'],
'zend_disk_cache_clear' => ['bool', 'namespace='=>'mixed|string'],
'zend_disk_cache_delete' => ['mixed|null', 'key'=>''],
'zend_disk_cache_fetch' => ['mixed|null', 'key'=>''],
'zend_disk_cache_store' => ['bool', 'key'=>'', 'value'=>'', 'ttl='=>'int|mixed'],
'zend_get_id' => ['array', 'all_ids='=>'all_ids|false'],
'zend_is_configuration_changed' => [''],
'zend_loader_current_file' => ['string'],
'zend_loader_enabled' => ['bool'],
'zend_loader_file_encoded' => ['bool'],
'zend_loader_file_licensed' => ['array'],
'zend_loader_install_license' => ['bool', 'license_file'=>'license_file', 'override'=>'override'],
'zend_logo_guid' => ['string'],
'zend_obfuscate_class_name' => ['string', 'class_name'=>'class_name'],
'zend_obfuscate_function_name' => ['string', 'function_name'=>'function_name'],
'zend_optimizer_version' => ['string'],
'zend_runtime_obfuscate' => ['void'],
'zend_send_buffer' => ['bool', 'buffer'=>'buffer', 'mime_type'=>'mime_type', 'custom_headers'=>'custom_headers'],
'zend_send_file' => ['bool', 'filename'=>'filename', 'mime_type'=>'mime_type', 'custom_headers'=>'custom_headers'],
'zend_set_configuration_changed' => [''],
'zend_shm_cache_clear' => ['bool', 'namespace='=>'mixed|string'],
'zend_shm_cache_delete' => ['mixed|null', 'key'=>''],
'zend_shm_cache_fetch' => ['mixed|null', 'key'=>''],
'zend_shm_cache_store' => ['bool', 'key'=>'', 'value'=>'', 'ttl='=>'int|mixed'],
'zend_thread_id' => ['int'],
'zend_version' => ['string'],
'ZendAPI_Job::addJobToQueue' => ['int', 'jobqueue_url'=>'string', 'password'=>'string'],
'ZendAPI_Job::getApplicationID' => [''],
'ZendAPI_Job::getEndTime' => [''],
'ZendAPI_Job::getGlobalVariables' => [''],
'ZendAPI_Job::getHost' => [''],
'ZendAPI_Job::getID' => [''],
'ZendAPI_Job::getInterval' => [''],
'ZendAPI_Job::getJobDependency' => [''],
'ZendAPI_Job::getJobName' => [''],
'ZendAPI_Job::getJobPriority' => [''],
'ZendAPI_Job::getJobStatus' => ['int'],
'ZendAPI_Job::getLastPerformedStatus' => ['int'],
'ZendAPI_Job::getOutput' => ['An'],
'ZendAPI_Job::getPreserved' => [''],
'ZendAPI_Job::getProperties' => ['array'],
'ZendAPI_Job::getScheduledTime' => [''],
'ZendAPI_Job::getScript' => [''],
'ZendAPI_Job::getTimeToNextRepeat' => ['int'],
'ZendAPI_Job::getUserVariables' => [''],
'ZendAPI_Job::setApplicationID' => ['', 'app_id'=>''],
'ZendAPI_Job::setGlobalVariables' => ['', 'vars'=>''],
'ZendAPI_Job::setJobDependency' => ['', 'job_id'=>''],
'ZendAPI_Job::setJobName' => ['', 'name'=>''],
'ZendAPI_Job::setJobPriority' => ['', 'priority'=>'int'],
'ZendAPI_Job::setPreserved' => ['', 'preserved'=>''],
'ZendAPI_Job::setRecurrenceData' => ['', 'interval'=>'', 'end_time='=>'mixed'],
'ZendAPI_Job::setScheduledTime' => ['', 'timestamp'=>''],
'ZendAPI_Job::setScript' => ['', 'script'=>''],
'ZendAPI_Job::setUserVariables' => ['', 'vars'=>''],
'ZendAPI_Job::ZendAPI_Job' => ['Job', 'script'=>'script'],
'ZendAPI_Queue::addJob' => ['int', '&job'=>'Job'],
'ZendAPI_Queue::getAllApplicationIDs' => ['array'],
'ZendAPI_Queue::getAllhosts' => ['array'],
'ZendAPI_Queue::getHistoricJobs' => ['array', 'status'=>'int', 'start_time'=>'', 'end_time'=>'', 'index'=>'int', 'count'=>'int', '&total'=>'int'],
'ZendAPI_Queue::getJob' => ['Job', 'job_id'=>'int'],
'ZendAPI_Queue::getJobsInQueue' => ['array', 'filter_options='=>'array', 'max_jobs='=>'int', 'with_globals_and_output='=>'bool|false'],
'ZendAPI_Queue::getLastError' => ['string'],
'ZendAPI_Queue::getNumOfJobsInQueue' => ['int', 'filter_options='=>'array'],
'ZendAPI_Queue::getStatistics' => ['array'],
'ZendAPI_Queue::isScriptExists' => ['bool', 'path'=>'string'],
'ZendAPI_Queue::isSuspend' => ['bool'],
'ZendAPI_Queue::login' => ['bool', 'password'=>'string', 'application_id='=>'int'],
'ZendAPI_Queue::removeJob' => ['bool', 'job_id'=>'array|int'],
'ZendAPI_Queue::requeueJob' => ['bool', 'job'=>'Job'],
'ZendAPI_Queue::resumeJob' => ['bool', 'job_id'=>'array|int'],
'ZendAPI_Queue::resumeQueue' => ['bool'],
'ZendAPI_Queue::setMaxHistoryTime' => ['bool'],
'ZendAPI_Queue::suspendJob' => ['bool', 'job_id'=>'array|int'],
'ZendAPI_Queue::suspendQueue' => ['bool'],
'ZendAPI_Queue::updateJob' => ['int', '&job'=>'Job'],
'ZendAPI_Queue::zendapi_queue' => ['ZendAPI_Queue', 'queue_url'=>'string'],
'zip_close' => ['void', 'zip'=>'resource'],
'zip_entry_close' => ['bool', 'zip_ent'=>'resource'],
'zip_entry_compressedsize' => ['int', 'zip_entry'=>'resource'],
'zip_entry_compressionmethod' => ['string', 'zip_entry'=>'resource'],
'zip_entry_filesize' => ['int', 'zip_entry'=>'resource'],
'zip_entry_name' => ['string', 'zip_entry'=>'resource'],
'zip_entry_open' => ['bool', 'zip_dp'=>'resource', 'zip_entry'=>'resource', 'mode='=>'string'],
'zip_entry_read' => ['string', 'zip_entry'=>'resource', 'len='=>'int'],
'zip_open' => ['resource', 'filename'=>'string'],
'zip_read' => ['resource', 'zip'=>'resource'],
'ZipArchive::addEmptyDir' => ['bool', 'dirname'=>'string'],
'ZipArchive::addFile' => ['bool', 'filepath'=>'string', 'entryname='=>'string', 'start='=>'int', 'length='=>'int'],
'ZipArchive::addFromString' => ['bool', 'entryname'=>'string', 'content'=>'string'],
'ZipArchive::addGlob' => ['bool', 'pattern'=>'string', 'flags='=>'int', 'options='=>'array'],
'ZipArchive::addPattern' => ['bool', 'pattern'=>'string', 'path='=>'string', 'options='=>'array'],
'ZipArchive::close' => ['bool'],
'ZipArchive::count' => ['int'],
'ZipArchive::createEmptyDir' => ['bool', 'dirname'=>'string'],
'ZipArchive::deleteIndex' => ['bool', 'index'=>'int'],
'ZipArchive::deleteName' => ['bool', 'name'=>'string'],
'ZipArchive::extractTo' => ['bool', 'pathto'=>'string', 'files='=>'string[]|string'],
'ZipArchive::getArchiveComment' => ['string', 'flags='=>'int'],
'ZipArchive::getCommentIndex' => ['string', 'index'=>'int', 'flags='=>'int'],
'ZipArchive::getCommentName' => ['string', 'name'=>'string', 'flags='=>'int'],
'ZipArchive::getExternalAttributesIndex' => ['bool', 'index'=>'int', '&w_opsys'=>'int', '&w_attr'=>'int', 'flags='=>'int'],
'ZipArchive::getExternalAttributesName' => ['bool', 'name'=>'string', '&w_opsys'=>'int', '&w_attr'=>'int', 'flags='=>'int'],
'ZipArchive::getFromIndex' => ['string', 'index'=>'int', 'len='=>'int', 'flags='=>'int'],
'ZipArchive::getFromName' => ['string', 'entryname'=>'string', 'len='=>'int', 'flags='=>'int'],
'ZipArchive::getNameIndex' => ['string', 'index'=>'int', 'flags='=>'int'],
'ZipArchive::getStatusString' => ['string'],
'ZipArchive::getStream' => ['resource', 'entryname'=>'string'],
'ZipArchive::locateName' => ['int', 'filename'=>'string', 'flags='=>'int'],
'ZipArchive::open' => ['mixed', 'source'=>'string', 'flags='=>'int'],
'ZipArchive::renameIndex' => ['bool', 'index'=>'int', 'new_name'=>'string'],
'ZipArchive::renameName' => ['bool', 'name'=>'string', 'new_name'=>'string'],
'ZipArchive::setArchiveComment' => ['bool', 'comment'=>'string'],
'ZipArchive::setCommentIndex' => ['bool', 'index'=>'int', 'comment'=>'string'],
'ZipArchive::setCommentName' => ['bool', 'name'=>'string', 'comment'=>'string'],
'ZipArchive::setCompressionIndex' => ['bool', 'index'=>'int', 'comp_method'=>'int', 'comp_flags='=>'int'],
'ZipArchive::setCompressionName' => ['bool', 'name'=>'string', 'comp_method'=>'int', 'comp_flags='=>'int'],
'ZipArchive::setEncryptionIndex' => ['bool', 'index'=>'int', 'method'=>'string', 'password='=>'string'],
'ZipArchive::setEncryptionName' => ['bool', 'name'=>'string', 'method'=>'int', 'password='=>'string'],
'ZipArchive::setExternalAttributesIndex' => ['bool', 'index'=>'int', 'opsys'=>'int', 'attr'=>'int', 'flags='=>'int'],
'ZipArchive::setExternalAttributesName' => ['bool', 'name'=>'string', 'opsys'=>'int', 'attr'=>'int', 'flags='=>'int'],
'ZipArchive::setPassword' => ['bool', 'password'=>'string'],
'ZipArchive::statIndex' => ['array|false', 'index'=>'int', 'flags='=>'int'],
'ZipArchive::statName' => ['array|false', 'filename'=>'string', 'flags='=>'int'],
'ZipArchive::unchangeAll' => ['bool'],
'ZipArchive::unchangeArchive' => ['bool'],
'ZipArchive::unchangeIndex' => ['bool', 'index'=>'int'],
'ZipArchive::unchangeName' => ['bool', 'name'=>'string'],
'zlib_decode' => ['string', 'data'=>'string', 'max_decoded_len='=>'int'],
'zlib_encode' => ['string', 'data'=>'string', 'encoding'=>'int', 'level='=>'string|int'],
'zlib_get_coding_type' => ['string|false'],
'ZMQ::__construct' => ['void'],
'ZMQContext::__construct' => ['void', 'io_threads='=>'int', 'is_persistent='=>'bool'],
'ZMQContext::getOpt' => ['mixed', 'key'=>'string'],
'ZMQContext::getSocket' => ['ZMQSocket', 'type'=>'int', 'persistent_id='=>'string', 'on_new_socket='=>'callable'],
'ZMQContext::isPersistent' => ['bool'],
'ZMQContext::setOpt' => ['ZMQContext', 'key'=>'int', 'value'=>'mixed'],
'ZMQDevice::__construct' => ['void', 'frontend'=>'ZMQSocket', 'backend'=>'ZMQSocket', 'listener='=>'ZMQSocket'],
'ZMQDevice::getIdleTimeout' => ['ZMQDevice'],
'ZMQDevice::getTimerTimeout' => ['ZMQDevice'],
'ZMQDevice::run' => ['void'],
'ZMQDevice::setIdleCallback' => ['ZMQDevice', 'cb_func'=>'callable', 'timeout'=>'int', 'user_data='=>'mixed'],
'ZMQDevice::setIdleTimeout' => ['ZMQDevice', 'timeout'=>'int'],
'ZMQDevice::setTimerCallback' => ['ZMQDevice', 'cb_func'=>'callable', 'timeout'=>'int', 'user_data='=>'mixed'],
'ZMQDevice::setTimerTimeout' => ['ZMQDevice', 'timeout'=>'int'],
'ZMQPoll::add' => ['string', 'entry'=>'mixed', 'type'=>'int'],
'ZMQPoll::clear' => ['ZMQPoll'],
'ZMQPoll::count' => ['int'],
'ZMQPoll::getLastErrors' => ['array'],
'ZMQPoll::poll' => ['int', '&w_readable'=>'array', '&w_writable'=>'array', 'timeout='=>'int'],
'ZMQPoll::remove' => ['bool', 'item'=>'mixed'],
'ZMQSocket::__construct' => ['void', 'context'=>'ZMQContext', 'type'=>'int', 'persistent_id='=>'string', 'on_new_socket='=>'callable'],
'ZMQSocket::bind' => ['ZMQSocket', 'dsn'=>'string', 'force='=>'bool'],
'ZMQSocket::connect' => ['ZMQSocket', 'dsn'=>'string', 'force='=>'bool'],
'ZMQSocket::disconnect' => ['ZMQSocket', 'dsn'=>'string'],
'ZMQSocket::getEndpoints' => ['array'],
'ZMQSocket::getPersistentId' => ['string'],
'ZMQSocket::getSocketType' => ['int'],
'ZMQSocket::getSockOpt' => ['mixed', 'key'=>'string'],
'ZMQSocket::isPersistent' => ['bool'],
'ZMQSocket::recv' => ['string', 'mode='=>'int'],
'ZMQSocket::recvMulti' => ['string', 'mode='=>'int'],
'ZMQSocket::send' => ['ZMQSocket', 'message'=>'array', 'mode='=>'int'],
'ZMQSocket::send\'1' => ['ZMQSocket', 'message'=>'string', 'mode='=>'int'],
'ZMQSocket::sendmulti' => ['ZMQSocket', 'message'=>'array', 'mode='=>'int'],
'ZMQSocket::setSockOpt' => ['ZMQSocket', 'key'=>'int', 'value'=>'mixed'],
'ZMQSocket::unbind' => ['ZMQSocket', 'dsn'=>'string'],
'Zookeeper::addAuth' => ['bool', 'scheme'=>'string', 'cert'=>'string', 'completion_cb='=>'callable'],
'Zookeeper::connect' => ['void', 'host'=>'string', 'watcher_cb='=>'callable', 'recv_timeout='=>'int'],
'Zookeeper::create' => ['string', 'path'=>'string', 'value'=>'string', 'acls'=>'array', 'flags='=>'int'],
'Zookeeper::delete' => ['bool', 'path'=>'string', 'version='=>'int'],
'Zookeeper::exists' => ['bool', 'path'=>'string', 'watcher_cb='=>'callable'],
'Zookeeper::get' => ['string', 'path'=>'string', 'watcher_cb='=>'callable', 'stat='=>'array', 'max_size='=>'int'],
'Zookeeper::getAcl' => ['array', 'path'=>'string'],
'Zookeeper::getChildren' => ['array', 'path'=>'string', 'watcher_cb='=>'callable'],
'Zookeeper::getClientId' => ['int'],
'Zookeeper::getRecvTimeout' => ['int'],
'Zookeeper::getState' => ['int'],
'Zookeeper::isRecoverable' => ['bool'],
'Zookeeper::set' => ['bool', 'path'=>'string', 'value'=>'string', 'version='=>'int', 'stat='=>'array'],
'Zookeeper::setAcl' => ['bool', 'path'=>'string', 'version'=>'int', 'acl'=>'array'],
'Zookeeper::setDebugLevel' => ['bool', 'logLevel'=>'int'],
'Zookeeper::setDeterministicConnOrder' => ['bool', 'yesOrNo'=>'bool'],
'Zookeeper::setLogStream' => ['bool', 'stream'=>'resource'],
'Zookeeper::setWatcher' => ['bool', 'watcher_cb'=>'callable'],
'zookeeper_dispatch' => ['void'],
];
src/Reflection/SignatureMap/ParameterSignature.php 0000666 00000002074 13436755504 0016362 0 ustar 00 name = $name;
$this->optional = $optional;
$this->type = $type;
$this->passedByReference = $passedByReference;
$this->variadic = $variadic;
}
public function getName(): string
{
return $this->name;
}
public function isOptional(): bool
{
return $this->optional;
}
public function getType(): Type
{
return $this->type;
}
public function passedByReference(): PassedByReference
{
return $this->passedByReference;
}
public function isVariadic(): bool
{
return $this->variadic;
}
}
src/Reflection/SignatureMap/FunctionSignature.php 0000666 00000001727 13436755504 0016233 0 ustar 00 $parameters
* @param \PHPStan\Type\Type $returnType
* @param bool $variadic
*/
public function __construct(
array $parameters,
Type $returnType,
bool $variadic
)
{
$this->parameters = $parameters;
$this->returnType = $returnType;
$this->variadic = $variadic;
}
/**
* @return array
*/
public function getParameters(): array
{
return $this->parameters;
}
public function getReturnType(): Type
{
return $this->returnType;
}
public function isVariadic(): bool
{
return $this->variadic;
}
}
src/Reflection/SignatureMap/SignatureMapParser.php 0000666 00000006761 13436755504 0016343 0 ustar 00 typeStringResolver = $typeNodeResolver;
}
/**
* @param mixed[] $map
* @param string|null $className
* @return \PHPStan\Reflection\SignatureMap\FunctionSignature
*/
public function getFunctionSignature(array $map, ?string $className): FunctionSignature
{
$parameterSignatures = $this->getParameters(array_slice($map, 1));
$hasVariadic = false;
foreach ($parameterSignatures as $parameterSignature) {
if ($parameterSignature->isVariadic()) {
$hasVariadic = true;
break;
}
}
return new FunctionSignature(
$parameterSignatures,
$this->getTypeFromString($map[0], $className),
$hasVariadic
);
}
private function getTypeFromString(string $typeString, ?string $className): Type
{
if ($typeString === '') {
return new MixedType(true);
}
$parts = explode('|', $typeString);
$types = [];
foreach ($parts as $part) {
$isNullable = false;
if (substr($part, 0, 1) === '?') {
$isNullable = true;
$part = substr($part, 1);
}
if ($part === 'OCI-Lob' || $part === 'OCI-Collection') {
$type = new ObjectType($part);
} else {
$type = $this->typeStringResolver->resolve($part, new NameScope(null, [], $className));
}
if ($isNullable) {
$type = TypeCombinator::addNull($type);
}
$types[] = $type;
}
return TypeCombinator::union(...$types);
}
/**
* @param array $parameterMap
* @return array
*/
private function getParameters(array $parameterMap): array
{
$parameterSignatures = [];
foreach ($parameterMap as $parameterName => $typeString) {
[$name, $isOptional, $passedByReference, $isVariadic] = $this->getParameterInfoFromName($parameterName);
$parameterSignatures[] = new ParameterSignature(
$name,
$isOptional,
$this->getTypeFromString($typeString, null),
$passedByReference,
$isVariadic
);
}
return $parameterSignatures;
}
/**
* @param string $parameterNameString
* @return mixed[]
*/
private function getParameterInfoFromName(string $parameterNameString): array
{
$matches = \Nette\Utils\Strings::match(
$parameterNameString,
'#^(?P&(?:\.\.\.)?r?w?_?)?(?P\.\.\.)?(?P[^=]+)?(?P=)?($)#'
);
if ($matches === null || !isset($matches['optional'])) {
throw new \PHPStan\ShouldNotHappenException();
}
$isVariadic = $matches['variadic'] !== '';
$reference = $matches['reference'];
if (strpos($reference, '&...') === 0) {
$reference = '&' . substr($reference, 4);
$isVariadic = true;
}
if (strpos($reference, '&rw') === 0) {
$passedByReference = PassedByReference::createReadsArgument();
} elseif (strpos($reference, '&w') === 0) {
$passedByReference = PassedByReference::createCreatesNewVariable();
} else {
$passedByReference = PassedByReference::createNo();
}
$isOptional = $isVariadic || $matches['optional'] !== '';
$name = $matches['name'] !== '' ? $matches['name'] : '...';
return [$name, $isOptional, $passedByReference, $isVariadic];
}
}
src/Reflection/SignatureMap/SignatureMapProvider.php 0000666 00000002331 13436755504 0016666 0 ustar 00 parser = $parser;
}
public function hasFunctionSignature(string $name): bool
{
$signatureMap = self::getSignatureMap();
return array_key_exists($name, $signatureMap);
}
public function getFunctionSignature(string $functionName, ?string $className): FunctionSignature
{
if (!$this->hasFunctionSignature($functionName)) {
throw new \PHPStan\ShouldNotHappenException();
}
$signatureMap = self::getSignatureMap();
return $this->parser->getFunctionSignature(
$signatureMap[$functionName],
$className
);
}
/**
* @return mixed[]
*/
private static function getSignatureMap(): array
{
if (self::$signatureMap === null) {
$signatureMap = require __DIR__ . '/functionMap.php';
if (!is_array($signatureMap)) {
throw new \PHPStan\ShouldNotHappenException('Signature map could not be loaded.');
}
self::$signatureMap = $signatureMap;
}
return self::$signatureMap;
}
}
src/Reflection/ParametersAcceptor.php 0000666 00000000640 13436755504 0013742 0 ustar 00
*/
public function getParameters(): array;
public function isVariadic(): bool;
public function getReturnType(): Type;
}
src/Reflection/MethodsClassReflectionExtension.php 0000666 00000000456 13436755504 0016464 0 ustar 00 getType($arg->value);
if ($arg->unpack) {
$unpack = true;
$types[] = $type->getIterableValueType();
} else {
$types[] = $type;
}
}
return self::selectFromTypes($types, $parametersAcceptors, $unpack);
}
/**
* @param \PHPStan\Type\Type[] $types
* @param ParametersAcceptor[] $parametersAcceptors
* @param bool $unpack
* @return ParametersAcceptor
*/
public static function selectFromTypes(
array $types,
array $parametersAcceptors,
bool $unpack
): ParametersAcceptor
{
if (count($parametersAcceptors) === 1) {
return $parametersAcceptors[0];
}
$typesCount = count($types);
$acceptableAcceptors = [];
foreach ($parametersAcceptors as $parametersAcceptor) {
if ($unpack) {
$acceptableAcceptors[] = $parametersAcceptor;
continue;
}
$functionParametersMinCount = 0;
$functionParametersMaxCount = 0;
foreach ($parametersAcceptor->getParameters() as $parameter) {
if (!$parameter->isOptional()) {
$functionParametersMinCount++;
}
$functionParametersMaxCount++;
}
if ($typesCount < $functionParametersMinCount) {
continue;
}
if (
!$parametersAcceptor->isVariadic()
&& $typesCount > $functionParametersMaxCount
) {
continue;
}
$acceptableAcceptors[] = $parametersAcceptor;
}
if (count($acceptableAcceptors) === 0) {
return self::combineAcceptors($parametersAcceptors);
}
if (count($acceptableAcceptors) === 1) {
return $acceptableAcceptors[0];
}
$winningAcceptors = [];
$winningCertainty = null;
foreach ($acceptableAcceptors as $acceptableAcceptor) {
$isSuperType = TrinaryLogic::createYes();
foreach ($acceptableAcceptor->getParameters() as $i => $parameter) {
if (!isset($types[$i])) {
if (!$unpack || count($types) <= 0) {
break;
}
$type = $types[count($types) - 1];
} else {
$type = $types[$i];
}
if ($parameter->getType() instanceof MixedType) {
$isSuperType = $isSuperType->and(TrinaryLogic::createMaybe());
} else {
$isSuperType = $isSuperType->and($parameter->getType()->isSuperTypeOf($type));
}
}
if ($isSuperType->no()) {
continue;
}
if ($winningCertainty === null) {
$winningAcceptors[] = $acceptableAcceptor;
$winningCertainty = $isSuperType;
} else {
$comparison = $winningCertainty->compareTo($isSuperType);
if ($comparison === $isSuperType) {
$winningAcceptors = [$acceptableAcceptor];
$winningCertainty = $isSuperType;
} elseif ($comparison === null) {
$winningAcceptors[] = $acceptableAcceptor;
}
}
}
if (count($winningAcceptors) === 0) {
return self::combineAcceptors($acceptableAcceptors);
}
return self::combineAcceptors($winningAcceptors);
}
/**
* @param ParametersAcceptor[] $acceptors
* @return ParametersAcceptor
*/
public static function combineAcceptors(array $acceptors): ParametersAcceptor
{
if (count($acceptors) === 1) {
return $acceptors[0];
}
$minimumNumberOfParameters = null;
foreach ($acceptors as $acceptor) {
$acceptorParametersMinCount = 0;
foreach ($acceptor->getParameters() as $parameter) {
if ($parameter->isOptional()) {
continue;
}
$acceptorParametersMinCount++;
}
if ($minimumNumberOfParameters !== null && $minimumNumberOfParameters <= $acceptorParametersMinCount) {
continue;
}
$minimumNumberOfParameters = $acceptorParametersMinCount;
}
$parameters = [];
$isVariadic = false;
$returnType = null;
foreach ($acceptors as $acceptor) {
if ($returnType === null) {
$returnType = $acceptor->getReturnType();
} else {
$returnType = TypeCombinator::union($returnType, $acceptor->getReturnType());
}
$isVariadic = $isVariadic || $acceptor->isVariadic();
foreach ($acceptor->getParameters() as $i => $parameter) {
if (!isset($parameters[$i])) {
$parameters[$i] = new NativeParameterReflection(
$parameter->getName(),
$i + 1 > $minimumNumberOfParameters,
$parameter->getType(),
$parameter->passedByReference(),
$parameter->isVariadic()
);
continue;
}
$isVariadic = $parameters[$i]->isVariadic() || $parameter->isVariadic();
$parameters[$i] = new NativeParameterReflection(
$parameters[$i]->getName() !== $parameter->getName() ? sprintf('%s|%s', $parameters[$i]->getName(), $parameter->getName()) : $parameter->getName(),
$i + 1 > $minimumNumberOfParameters,
TypeCombinator::union($parameters[$i]->getType(), $parameter->getType()),
$parameters[$i]->passedByReference()->combine($parameter->passedByReference()),
$isVariadic
);
if ($isVariadic) {
$parameters = array_slice($parameters, 0, $i + 1);
break;
}
}
}
/** @var \PHPStan\Type\Type $returnType */
$returnType = $returnType;
return new FunctionVariant($parameters, $isVariadic, $returnType);
}
}
src/Reflection/FunctionReflection.php 0000666 00000000520 13436755504 0013753 0 ustar 00 fileTypeMapper = $fileTypeMapper;
}
public function hasProperty(ClassReflection $classReflection, string $propertyName): bool
{
if (!isset($this->properties[$classReflection->getName()])) {
$this->properties[$classReflection->getName()] = $this->createProperties($classReflection, $classReflection);
}
return isset($this->properties[$classReflection->getName()][$propertyName]);
}
public function getProperty(ClassReflection $classReflection, string $propertyName): PropertyReflection
{
return $this->properties[$classReflection->getName()][$propertyName];
}
/**
* @param \PHPStan\Reflection\ClassReflection $classReflection
* @param \PHPStan\Reflection\ClassReflection $declaringClass
* @return \PHPStan\Reflection\PropertyReflection[]
*/
private function createProperties(
ClassReflection $classReflection,
ClassReflection $declaringClass
): array
{
$properties = [];
foreach ($classReflection->getTraits() as $traitClass) {
$properties += $this->createProperties($traitClass, $classReflection);
}
foreach ($classReflection->getParents() as $parentClass) {
$properties += $this->createProperties($parentClass, $parentClass);
foreach ($parentClass->getTraits() as $traitClass) {
$properties += $this->createProperties($traitClass, $parentClass);
}
}
foreach ($classReflection->getInterfaces() as $interfaceClass) {
$properties += $this->createProperties($interfaceClass, $interfaceClass);
}
$fileName = $classReflection->getFileName();
if ($fileName === false) {
return $properties;
}
$docComment = $classReflection->getNativeReflection()->getDocComment();
if ($docComment === false) {
return $properties;
}
$resolvedPhpDoc = $this->fileTypeMapper->getResolvedPhpDoc($fileName, $classReflection->getName(), null, $docComment);
foreach ($resolvedPhpDoc->getPropertyTags() as $propertyName => $propertyTag) {
$properties[$propertyName] = new AnnotationPropertyReflection(
$declaringClass,
$propertyTag->getType(),
$propertyTag->isReadable(),
$propertyTag->isWritable()
);
}
return $properties;
}
}
src/Reflection/Annotations/AnnotationsMethodsClassReflectionExtension.php 0000666 00000006331 13436755504 0023175 0 ustar 00 fileTypeMapper = $fileTypeMapper;
}
public function hasMethod(ClassReflection $classReflection, string $methodName): bool
{
if (!isset($this->methods[$classReflection->getName()])) {
$this->methods[$classReflection->getName()] = $this->createMethods($classReflection, $classReflection);
}
return isset($this->methods[$classReflection->getName()][$methodName]);
}
public function getMethod(ClassReflection $classReflection, string $methodName): MethodReflection
{
return $this->methods[$classReflection->getName()][$methodName];
}
/**
* @param ClassReflection $classReflection
* @param ClassReflection $declaringClass
* @return MethodReflection[]
*/
private function createMethods(
ClassReflection $classReflection,
ClassReflection $declaringClass
): array
{
$methods = [];
foreach ($classReflection->getTraits() as $traitClass) {
$methods += $this->createMethods($traitClass, $classReflection);
}
foreach ($classReflection->getParents() as $parentClass) {
$methods += $this->createMethods($parentClass, $parentClass);
foreach ($parentClass->getTraits() as $traitClass) {
$methods += $this->createMethods($traitClass, $parentClass);
}
}
foreach ($classReflection->getInterfaces() as $interfaceClass) {
$methods += $this->createMethods($interfaceClass, $interfaceClass);
}
$fileName = $classReflection->getFileName();
if ($fileName === false) {
return $methods;
}
$docComment = $classReflection->getNativeReflection()->getDocComment();
if ($docComment === false) {
return $methods;
}
$resolvedPhpDoc = $this->fileTypeMapper->getResolvedPhpDoc($fileName, $classReflection->getName(), null, $docComment);
foreach ($resolvedPhpDoc->getMethodTags() as $methodName => $methodTag) {
$parameters = [];
foreach ($methodTag->getParameters() as $parameterName => $parameterTag) {
$parameters[] = new AnnotationsMethodParameterReflection(
$parameterName,
$parameterTag->getType(),
$parameterTag->passedByReference(),
$parameterTag->isOptional(),
$parameterTag->isVariadic()
);
}
$methods[$methodName] = new AnnotationMethodReflection(
$methodName,
$declaringClass,
$methodTag->getReturnType(),
$parameters,
$methodTag->isStatic(),
$this->detectMethodVariadic($parameters)
);
}
return $methods;
}
/**
* @param AnnotationsMethodParameterReflection[] $parameters
* @return bool
*/
private function detectMethodVariadic(array $parameters): bool
{
if ($parameters === []) {
return false;
}
$possibleVariadicParameterIndex = count($parameters) - 1;
$possibleVariadicParameter = $parameters[$possibleVariadicParameterIndex];
return $possibleVariadicParameter->isVariadic();
}
}
src/Reflection/Annotations/AnnotationMethodReflection.php 0000666 00000004035 13436755504 0017743 0 ustar 00 name = $name;
$this->declaringClass = $declaringClass;
$this->returnType = $returnType;
$this->parameters = $parameters;
$this->isStatic = $isStatic;
$this->isVariadic = $isVariadic;
}
public function getDeclaringClass(): ClassReflection
{
return $this->declaringClass;
}
public function getPrototype(): ClassMemberReflection
{
return $this;
}
public function isStatic(): bool
{
return $this->isStatic;
}
public function isPrivate(): bool
{
return false;
}
public function isPublic(): bool
{
return true;
}
public function getName(): string
{
return $this->name;
}
/**
* @return \PHPStan\Reflection\ParametersAcceptor[]
*/
public function getVariants(): array
{
if ($this->variants === null) {
$this->variants = [
new FunctionVariant(
$this->parameters,
$this->isVariadic,
$this->returnType
),
];
}
return $this->variants;
}
}
src/Reflection/Annotations/AnnotationsMethodParameterReflection.php 0000666 00000002220 13436755504 0021761 0 ustar 00 name = $name;
$this->type = $type;
$this->passedByReference = $passedByReference;
$this->isOptional = $isOptional;
$this->isVariadic = $isVariadic;
}
public function getName(): string
{
return $this->name;
}
public function isOptional(): bool
{
return $this->isOptional;
}
public function getType(): Type
{
return $this->type;
}
public function passedByReference(): PassedByReference
{
return $this->passedByReference;
}
public function isVariadic(): bool
{
return $this->isVariadic;
}
}
src/Reflection/Annotations/AnnotationPropertyReflection.php 0000666 00000002243 13436755504 0020346 0 ustar 00 declaringClass = $declaringClass;
$this->type = $type;
$this->readable = $readable;
$this->writable = $writable;
}
public function getDeclaringClass(): ClassReflection
{
return $this->declaringClass;
}
public function isStatic(): bool
{
return false;
}
public function isPrivate(): bool
{
return false;
}
public function isPublic(): bool
{
return true;
}
public function getType(): Type
{
return $this->type;
}
public function isReadable(): bool
{
return $this->readable;
}
public function isWritable(): bool
{
return $this->writable;
}
}
src/Reflection/PassedByReference.php 0000666 00000002775 13436755504 0013522 0 ustar 00 value = $value;
}
private static function create(int $value): self
{
if (!array_key_exists($value, self::$registry)) {
self::$registry[$value] = new self($value);
}
return self::$registry[$value];
}
public static function createNo(): self
{
return self::create(self::NO);
}
public static function createCreatesNewVariable(): self
{
return self::create(self::CREATES_NEW_VARIABLE);
}
public static function createReadsArgument(): self
{
return self::create(self::READS_ARGUMENT);
}
public function no(): bool
{
return $this->value === self::NO;
}
public function yes(): bool
{
return !$this->no();
}
public function equals(self $other): bool
{
return $this->value === $other->value;
}
public function createsNewVariable(): bool
{
return $this->value === self::CREATES_NEW_VARIABLE;
}
public function combine(self $other): self
{
if ($this->value > $other->value) {
return $this;
} elseif ($this->value < $other->value) {
return $other;
}
return $this;
}
/**
* @param mixed[] $properties
* @return self
*/
public static function __set_state(array $properties): self
{
return new self($properties['value']);
}
}
src/Reflection/DeprecatableReflection.php 0000666 00000000217 13436755504 0014544 0 ustar 00 originalParser = $originalParser;
}
/**
* @param string $file path to a file to parse
* @return \PhpParser\Node[]
*/
public function parseFile(string $file): array
{
if (!isset($this->cachedNodesByFile[$file])) {
$this->cachedNodesByFile[$file] = $this->originalParser->parseFile($file);
}
return $this->cachedNodesByFile[$file];
}
/**
* @param string $sourceCode
* @return \PhpParser\Node[]
*/
public function parseString(string $sourceCode): array
{
if (!isset($this->cachedNodesByString[$sourceCode])) {
$this->cachedNodesByString[$sourceCode] = $this->originalParser->parseString($sourceCode);
}
return $this->cachedNodesByString[$sourceCode];
}
}
src/Parser/Parser.php 0000666 00000000535 13436755504 0010557 0 ustar 00 parser = $parser;
$this->traverser = $traverser;
}
/**
* @param string $file path to a file to parse
* @return \PhpParser\Node[]
*/
public function parseFile(string $file): array
{
$contents = file_get_contents($file);
if ($contents === false) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->parseString($contents);
}
/**
* @param string $sourceCode
* @return \PhpParser\Node[]
*/
public function parseString(string $sourceCode): array
{
$nodes = $this->parser->parse($sourceCode);
if ($nodes === null) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->traverser->traverse($nodes);
}
}
src/Parser/FunctionCallStatementFinder.php 0000666 00000001733 13436755504 0014722 0 ustar 00 findFunctionCallInStatements($functionNames, $statement);
if ($result !== null) {
return $result;
}
}
if (!($statement instanceof \PhpParser\Node)) {
continue;
}
if ($statement instanceof FuncCall && $statement->name instanceof Name) {
if (in_array((string) $statement->name, $functionNames, true)) {
return $statement;
}
}
$result = $this->findFunctionCallInStatements($functionNames, $statement);
if ($result !== null) {
return $result;
}
}
return null;
}
}
src/Command/AnalyseCommand.php 0000666 00000010732 13436755504 0012340 0 ustar 00 setName(self::NAME)
->setDescription('Analyses source code')
->setDefinition([
new InputArgument('paths', InputArgument::OPTIONAL | InputArgument::IS_ARRAY, 'Paths with source code to run analysis on'),
new InputOption('configuration', 'c', InputOption::VALUE_REQUIRED, 'Path to project configuration file'),
new InputOption(self::OPTION_LEVEL, 'l', InputOption::VALUE_REQUIRED, 'Level of rule options - the higher the stricter'),
new InputOption(ErrorsConsoleStyle::OPTION_NO_PROGRESS, null, InputOption::VALUE_NONE, 'Do not show progress bar, only results'),
new InputOption('debug', null, InputOption::VALUE_NONE, 'Show debug information - which file is analysed, do not catch internal errors'),
new InputOption('autoload-file', 'a', InputOption::VALUE_REQUIRED, 'Project\'s additional autoload file path'),
new InputOption('error-format', null, InputOption::VALUE_REQUIRED, 'Format in which to print the result of the analysis', 'table'),
new InputOption('errorFormat', null, InputOption::VALUE_REQUIRED, '[deprecated] Use --error-format instead'),
new InputOption('memory-limit', null, InputOption::VALUE_REQUIRED, 'Memory limit for analysis'),
]);
}
/**
* @return string[]
*/
public function getAliases(): array
{
return ['analyze'];
}
protected function initialize(InputInterface $input, OutputInterface $output): void
{
if ((bool) $input->getOption('debug')) {
$this->getApplication()->setCatchExceptions(false);
return;
}
}
protected function execute(InputInterface $input, OutputInterface $output): int
{
$paths = $input->getArgument('paths');
$memoryLimit = $input->getOption('memory-limit');
$autoloadFile = $input->getOption('autoload-file');
$configuration = $input->getOption('configuration');
$level = $input->getOption(self::OPTION_LEVEL);
if (
!is_array($paths)
|| (!is_string($memoryLimit) && $memoryLimit !== null)
|| (!is_string($autoloadFile) && $autoloadFile !== null)
|| (!is_string($configuration) && $configuration !== null)
|| (!is_string($level) && $level !== null)
) {
throw new \PHPStan\ShouldNotHappenException();
}
try {
$inceptionResult = CommandHelper::begin(
$input,
$output,
$paths,
$memoryLimit,
$autoloadFile,
$configuration,
$level
);
} catch (\PHPStan\Command\InceptionNotSuccessfulException $e) {
return 1;
}
$errorOutput = $inceptionResult->getErrorOutput();
$errorFormat = $input->getOption('error-format');
$oldErrorFormat = $input->getOption('errorFormat');
if ($oldErrorFormat !== null) {
$errorOutput->writeln('Note: Using the option --errorFormat is deprecated. Use --error-format instead.');
$errorFormat = $oldErrorFormat;
}
if (!is_string($errorFormat) && $errorFormat !== null) {
throw new \PHPStan\ShouldNotHappenException();
}
$container = $inceptionResult->getContainer();
$errorFormatterServiceName = sprintf('errorFormatter.%s', $errorFormat);
if (!$container->hasService($errorFormatterServiceName)) {
$errorOutput->writeln(sprintf(
'Error formatter "%s" not found. Available error formatters are: %s',
$errorFormat,
implode(', ', array_map(static function (string $name) {
return substr($name, strlen('errorFormatter.'));
}, $container->findByType(ErrorFormatter::class)))
));
return 1;
}
/** @var ErrorFormatter $errorFormatter */
$errorFormatter = $container->getService($errorFormatterServiceName);
/** @var AnalyseApplication $application */
$application = $container->getByType(AnalyseApplication::class);
$debug = $input->getOption('debug');
if (!is_bool($debug)) {
throw new \PHPStan\ShouldNotHappenException();
}
return $inceptionResult->handleReturn(
$application->analyse(
$inceptionResult->getFiles(),
$inceptionResult->isOnlyFiles(),
$inceptionResult->getConsoleStyle(),
$errorFormatter,
$inceptionResult->isDefaultLevelUsed(),
$debug
)
);
}
}
src/Command/ErrorFormatter/JsonErrorFormatter.php 0000666 00000002715 13436755504 0016233 0 ustar 00 pretty = $pretty;
}
public function formatErrors(AnalysisResult $analysisResult, OutputStyle $style): int
{
$errorsArray = [
'totals' => [
'errors' => count($analysisResult->getNotFileSpecificErrors()),
'file_errors' => count($analysisResult->getFileSpecificErrors()),
],
'files' => [],
'errors' => [],
];
foreach ($analysisResult->getFileSpecificErrors() as $fileSpecificError) {
$file = $fileSpecificError->getFile();
if (!array_key_exists($file, $errorsArray['files'])) {
$errorsArray['files'][$file] = [
'errors' => 0,
'messages' => [],
];
}
$errorsArray['files'][$file]['errors']++;
$errorsArray['files'][$file]['messages'][] = [
'message' => $fileSpecificError->getMessage(),
'line' => $fileSpecificError->getLine(),
'ignorable' => $fileSpecificError->canBeIgnored(),
];
}
foreach ($analysisResult->getNotFileSpecificErrors() as $notFileSpecificError) {
$errorsArray['errors'][] = $notFileSpecificError;
}
$json = Json::encode($errorsArray, $this->pretty ? Json::PRETTY : 0);
$style->write($json);
return $analysisResult->hasErrors() ? 1 : 0;
}
}
src/Command/ErrorFormatter/TableErrorFormatter.php 0000666 00000004036 13436755504 0016347 0 ustar 00 relativePathHelper = $relativePathHelper;
}
public function formatErrors(
AnalysisResult $analysisResult,
OutputStyle $style
): int
{
if (!$analysisResult->hasErrors()) {
$style->success('No errors');
if ($analysisResult->isDefaultLevelUsed()) {
$style->note(sprintf(
'PHPStan is performing only the most basic checks. You can pass a higher rule level through the --%s option (the default and current level is %d) to analyse code more thoroughly.',
AnalyseCommand::OPTION_LEVEL,
AnalyseCommand::DEFAULT_LEVEL
));
}
return 0;
}
/** @var array $fileErrors */
$fileErrors = [];
foreach ($analysisResult->getFileSpecificErrors() as $fileSpecificError) {
if (!isset($fileErrors[$fileSpecificError->getFile()])) {
$fileErrors[$fileSpecificError->getFile()] = [];
}
$fileErrors[$fileSpecificError->getFile()][] = $fileSpecificError;
}
foreach ($fileErrors as $file => $errors) {
$rows = [];
foreach ($errors as $error) {
$rows[] = [
(string) $error->getLine(),
$error->getMessage(),
];
}
$relativeFilePath = $this->relativePathHelper->getRelativePath($file);
$style->table(['Line', $relativeFilePath], $rows);
}
if (count($analysisResult->getNotFileSpecificErrors()) > 0) {
$style->table(['Error'], array_map(static function (string $error): array {
return [$error];
}, $analysisResult->getNotFileSpecificErrors()));
}
$style->error(sprintf($analysisResult->getTotalErrorsCount() === 1 ? 'Found %d error' : 'Found %d errors', $analysisResult->getTotalErrorsCount()));
return 1;
}
}
src/Command/ErrorFormatter/RelativePathHelper.php 0000666 00000000666 13436755504 0016157 0 ustar 00 relativePathHelper = $relativePathHelper;
}
/**
* Formats the errors and outputs them to the console.
*
* @param \PHPStan\Command\AnalysisResult $analysisResult
* @param \Symfony\Component\Console\Style\OutputStyle $style
* @return int Error code.
*/
public function formatErrors(
AnalysisResult $analysisResult,
OutputStyle $style
): int
{
$style->writeln('');
$style->writeln('');
foreach ($this->groupByFile($analysisResult) as $relativeFilePath => $errors) {
$style->writeln(sprintf(
'',
$this->escape($relativeFilePath)
));
foreach ($errors as $error) {
$style->writeln(sprintf(
' ',
$this->escape((string) $error->getLine()),
$this->escape((string) $error->getMessage())
));
}
$style->writeln('');
}
$style->writeln('');
return $analysisResult->hasErrors() ? 1 : 0;
}
/**
* Escapes values for using in XML
*
* @param string $string
* @return string
*/
protected function escape(string $string): string
{
return htmlspecialchars($string, ENT_XML1 | ENT_COMPAT, 'UTF-8');
}
/**
* Group errors by file
*
* @param AnalysisResult $analysisResult
* @return array Array that have as key the relative path of file
* and as value an array with occured errors.
*/
private function groupByFile(AnalysisResult $analysisResult): array
{
$files = [];
/** @var \PHPStan\Analyser\Error $fileSpecificError */
foreach ($analysisResult->getFileSpecificErrors() as $fileSpecificError) {
$relativeFilePath = $this->relativePathHelper->getRelativePath(
$fileSpecificError->getFile()
);
$files[$relativeFilePath][] = $fileSpecificError;
}
return $files;
}
}
src/Command/ErrorFormatter/RawErrorFormatter.php 0000666 00000001437 13436755504 0016053 0 ustar 00 hasErrors()) {
return 0;
}
foreach ($analysisResult->getNotFileSpecificErrors() as $notFileSpecificError) {
$style->writeln(sprintf('?:?:%s', $notFileSpecificError));
}
foreach ($analysisResult->getFileSpecificErrors() as $fileSpecificError) {
$style->writeln(
sprintf(
'%s:%d:%s',
$fileSpecificError->getFile(),
$fileSpecificError->getLine() ?? '?',
$fileSpecificError->getMessage()
)
);
}
return 1;
}
}
src/Command/ErrorFormatter/ErrorFormatter.php 0000666 00000000755 13436755504 0015403 0 ustar 00 files = $files;
$this->onlyFiles = $onlyFiles;
$this->consoleStyle = $consoleStyle;
$this->errorOutput = $errorOutput;
$this->container = $container;
$this->isDefaultLevelUsed = $isDefaultLevelUsed;
$this->memoryLimitFile = $memoryLimitFile;
}
/**
* @return string[]
*/
public function getFiles(): array
{
return $this->files;
}
public function isOnlyFiles(): bool
{
return $this->onlyFiles;
}
public function getConsoleStyle(): OutputStyle
{
return $this->consoleStyle;
}
public function getErrorOutput(): OutputInterface
{
return $this->errorOutput;
}
public function getContainer(): Container
{
return $this->container;
}
public function isDefaultLevelUsed(): bool
{
return $this->isDefaultLevelUsed;
}
public function handleReturn(int $exitCode): int
{
@unlink($this->memoryLimitFile);
return $exitCode;
}
}
src/Command/ErrorsConsoleStyle.php 0000666 00000005756 13436755504 0013277 0 ustar 00 showProgress = $input->hasOption(self::OPTION_NO_PROGRESS) && !(bool) $input->getOption(self::OPTION_NO_PROGRESS);
$this->output = $output;
}
/**
* @param string[] $headers
* @param string[][] $rows
*/
public function table(array $headers, array $rows): void
{
/** @var int $terminalWidth */
$terminalWidth = (new \Symfony\Component\Console\Terminal())->getWidth();
$maxHeaderWidth = strlen($headers[0]);
foreach ($rows as $row) {
$length = strlen($row[0]);
if ($maxHeaderWidth !== 0 && $length <= $maxHeaderWidth) {
continue;
}
$maxHeaderWidth = $length;
}
$wrap = static function ($rows) use ($terminalWidth, $maxHeaderWidth) {
return array_map(static function ($row) use ($terminalWidth, $maxHeaderWidth) {
return array_map(static function ($s) use ($terminalWidth, $maxHeaderWidth) {
if ($terminalWidth > $maxHeaderWidth + 5) {
return wordwrap(
$s,
$terminalWidth - $maxHeaderWidth - 5,
"\n",
true
);
}
return $s;
}, $row);
}, $rows);
};
parent::table($headers, $wrap($rows));
}
/**
* @phpcsSuppress SlevomatCodingStandard.TypeHints.TypeHintDeclaration.MissingParameterTypeHint
* @param int $max
*/
public function createProgressBar($max = 0): ProgressBar
{
$this->progressBar = parent::createProgressBar($max);
return $this->progressBar;
}
/**
* @phpcsSuppress SlevomatCodingStandard.TypeHints.TypeHintDeclaration.MissingParameterTypeHint
* @param int $max
*/
public function progressStart($max = 0): void
{
if (!$this->showProgress) {
return;
}
parent::progressStart($max);
}
/**
* @phpcsSuppress SlevomatCodingStandard.TypeHints.TypeHintDeclaration.MissingParameterTypeHint
* @param int $step
*/
public function progressAdvance($step = 1): void
{
if (!$this->showProgress) {
return;
}
if ($this->output->isDecorated() && $step > 0) {
$stepTime = (time() - $this->progressBar->getStartTime()) / $step;
if ($stepTime > 0 && $stepTime < 1) {
$this->progressBar->setRedrawFrequency((int) (1 / $stepTime));
} else {
$this->progressBar->setRedrawFrequency(1);
}
}
$this->progressBar->setProgress($this->progressBar->getProgress() + $step);
}
public function progressFinish(): void
{
if (!$this->showProgress) {
return;
}
parent::progressFinish();
}
}
src/Command/AnalysisResult.php 0000666 00000003665 13436755504 0012436 0 ustar 00 getFile(),
$a->getLine(),
$a->getMessage(),
] <=> [
$b->getFile(),
$b->getLine(),
$b->getMessage(),
];
}
);
$this->fileSpecificErrors = $fileSpecificErrors;
$this->notFileSpecificErrors = $notFileSpecificErrors;
$this->defaultLevelUsed = $defaultLevelUsed;
$this->currentDirectory = $currentDirectory;
}
public function hasErrors(): bool
{
return $this->getTotalErrorsCount() > 0;
}
public function getTotalErrorsCount(): int
{
return count($this->fileSpecificErrors) + count($this->notFileSpecificErrors);
}
/**
* @return \PHPStan\Analyser\Error[] sorted by their file name, line number and message
*/
public function getFileSpecificErrors(): array
{
return $this->fileSpecificErrors;
}
/**
* @return string[]
*/
public function getNotFileSpecificErrors(): array
{
return $this->notFileSpecificErrors;
}
public function isDefaultLevelUsed(): bool
{
return $this->defaultLevelUsed;
}
/**
* @deprecated Use \PHPStan\File\RelativePathHelper instead
* @return string
*/
public function getCurrentDirectory(): string
{
return $this->currentDirectory;
}
}
src/Command/CommandHelper.php 0000666 00000022343 13436755504 0012164 0 ustar 00 getErrorOutput() : $output;
$consoleStyle = new ErrorsConsoleStyle($input, $output);
if ($memoryLimit !== null) {
if (\Nette\Utils\Strings::match($memoryLimit, '#^-?\d+[kMG]?$#i') === null) {
$errorOutput->writeln(sprintf('Invalid memory limit format "%s".', $memoryLimit));
throw new \PHPStan\Command\InceptionNotSuccessfulException();
}
if (ini_set('memory_limit', $memoryLimit) === false) {
$errorOutput->writeln(sprintf('Memory limit "%s" cannot be set.', $memoryLimit));
throw new \PHPStan\Command\InceptionNotSuccessfulException();
}
}
$currentWorkingDirectory = getcwd();
if ($currentWorkingDirectory === false) {
throw new \PHPStan\ShouldNotHappenException();
}
$fileHelper = new FileHelper($currentWorkingDirectory);
if ($autoloadFile !== null && is_file($autoloadFile)) {
$autoloadFile = $fileHelper->absolutizePath($autoloadFile);
if (is_file($autoloadFile)) {
(static function (string $file): void {
require_once $file;
})($autoloadFile);
}
}
if ($projectConfigFile === null) {
foreach (['phpstan.neon', 'phpstan.neon.dist'] as $discoverableConfigName) {
$discoverableConfigFile = $currentWorkingDirectory . DIRECTORY_SEPARATOR . $discoverableConfigName;
if (is_file($discoverableConfigFile)) {
$projectConfigFile = $discoverableConfigFile;
$errorOutput->writeln(sprintf('Note: Using configuration file %s.', $projectConfigFile));
break;
}
}
}
$defaultLevelUsed = false;
if ($projectConfigFile === null && $level === null) {
$level = self::DEFAULT_LEVEL;
$defaultLevelUsed = true;
}
$containerFactory = new ContainerFactory($currentWorkingDirectory);
if ($projectConfigFile !== null) {
if (!is_file($projectConfigFile)) {
$errorOutput->writeln(sprintf('Project config file at path %s does not exist.', $projectConfigFile));
throw new \PHPStan\Command\InceptionNotSuccessfulException();
}
$loader = (new LoaderFactory())->createLoader();
$projectConfig = $loader->load($projectConfigFile, null);
$defaultParameters = [
'rootDir' => $containerFactory->getRootDirectory(),
'currentWorkingDirectory' => $containerFactory->getCurrentWorkingDirectory(),
];
if (isset($projectConfig['parameters']['tmpDir'])) {
$tmpDir = Helpers::expand($projectConfig['parameters']['tmpDir'], $defaultParameters);
}
if ($level === null && isset($projectConfig['parameters']['level'])) {
$level = $projectConfig['parameters']['level'];
}
if (count($paths) === 0 && isset($projectConfig['parameters']['paths'])) {
$paths = Helpers::expand($projectConfig['parameters']['paths'], $defaultParameters);
}
}
if (count($paths) === 0) {
$errorOutput->writeln('At least one path must be specified to analyse.');
throw new \PHPStan\Command\InceptionNotSuccessfulException();
}
$additionalConfigFiles = [];
if ($level !== null) {
$levelConfigFile = sprintf('%s/config.level%s.neon', $containerFactory->getConfigDirectory(), $level);
if (!is_file($levelConfigFile)) {
$errorOutput->writeln(sprintf('Level config file %s was not found.', $levelConfigFile));
throw new \PHPStan\Command\InceptionNotSuccessfulException();
}
$additionalConfigFiles[] = $levelConfigFile;
}
if ($projectConfigFile !== null) {
$additionalConfigFiles[] = $projectConfigFile;
}
if (!isset($tmpDir)) {
$tmpDir = sys_get_temp_dir() . '/phpstan';
if (!@mkdir($tmpDir, 0777, true) && !is_dir($tmpDir)) {
$errorOutput->writeln(sprintf('Cannot create a temp directory %s', $tmpDir));
throw new \PHPStan\Command\InceptionNotSuccessfulException();
}
}
$paths = array_map(static function (string $path) use ($fileHelper): string {
return $fileHelper->absolutizePath($path);
}, $paths);
$container = $containerFactory->create($tmpDir, $additionalConfigFiles, $paths);
$memoryLimitFile = $container->parameters['memoryLimitFile'];
if (file_exists($memoryLimitFile)) {
$memoryLimitFileContents = file_get_contents($memoryLimitFile);
if ($memoryLimitFileContents === false) {
throw new \PHPStan\ShouldNotHappenException();
}
$errorOutput->writeln('PHPStan crashed in the previous run probably because of excessive memory consumption.');
$errorOutput->writeln(sprintf('It consumed around %s of memory.', $memoryLimitFileContents));
$errorOutput->writeln('');
$errorOutput->writeln('');
$errorOutput->writeln('To avoid this issue, allow to use more memory with the --memory-limit option.');
@unlink($memoryLimitFile);
}
self::setUpSignalHandler($consoleStyle, $memoryLimitFile);
if (!isset($container->parameters['customRulesetUsed'])) {
$errorOutput->writeln('');
$errorOutput->writeln('No rules detected');
$errorOutput->writeln('');
$errorOutput->writeln('You have the following choices:');
$errorOutput->writeln('');
$errorOutput->writeln('* while running the analyse option, use the --level option to adjust your rule level - the higher the stricter');
$errorOutput->writeln('');
$errorOutput->writeln(sprintf('* create your own custom ruleset by selecting which rules you want to check by copying the service definitions from the built-in config level files in %s>.', $fileHelper->normalizePath(__DIR__ . '/../../conf')));
$errorOutput->writeln(' * in this case, don\'t forget to define parameter customRulesetUsed> in your config file.');
$errorOutput->writeln('');
throw new \PHPStan\Command\InceptionNotSuccessfulException();
} elseif ((bool) $container->parameters['customRulesetUsed']) {
$defaultLevelUsed = false;
}
foreach ($container->parameters['autoload_files'] as $autoloadFile) {
(static function (string $file): void {
require_once $file;
})($fileHelper->normalizePath($autoloadFile));
}
if (count($container->parameters['autoload_directories']) > 0) {
$robotLoader = new \Nette\Loaders\RobotLoader();
$robotLoader->acceptFiles = array_map(static function (string $extension): string {
return sprintf('*.%s', $extension);
}, $container->parameters['fileExtensions']);
$robotLoader->setTempDirectory($tmpDir);
foreach ($container->parameters['autoload_directories'] as $directory) {
$robotLoader->addDirectory($fileHelper->normalizePath($directory));
}
foreach ($container->parameters['excludes_analyse'] as $directory) {
$robotLoader->excludeDirectory($fileHelper->normalizePath($directory));
}
$robotLoader->register();
}
$bootstrapFile = $container->parameters['bootstrap'];
if ($bootstrapFile !== null) {
$bootstrapFile = $fileHelper->normalizePath($bootstrapFile);
if (!is_file($bootstrapFile)) {
$errorOutput->writeln(sprintf('Bootstrap file %s does not exist.', $bootstrapFile));
throw new \PHPStan\Command\InceptionNotSuccessfulException();
}
try {
(static function (string $file): void {
require_once $file;
})($bootstrapFile);
} catch (\Throwable $e) {
$errorOutput->writeln($e->getMessage());
throw new \PHPStan\Command\InceptionNotSuccessfulException();
}
}
$onlyFiles = true;
$files = [];
$fileExtensions = $container->parameters['fileExtensions'];
foreach ($paths as $path) {
if (!file_exists($path)) {
$errorOutput->writeln(sprintf('Path %s does not exist', $path));
throw new \PHPStan\Command\InceptionNotSuccessfulException();
} elseif (is_file($path)) {
$files[] = $fileHelper->normalizePath($path);
} else {
$finder = new Finder();
$finder->followLinks();
foreach ($finder->files()->name('*.{' . implode(',', $fileExtensions) . '}')->in($path) as $fileInfo) {
$files[] = $fileHelper->normalizePath($fileInfo->getPathname());
$onlyFiles = false;
}
}
}
$fileExcluder = $container->getByType(FileExcluder::class);
$files = array_filter($files, static function (string $file) use ($fileExcluder): bool {
return !$fileExcluder->isExcludedFromAnalysing($file);
});
return new InceptionResult(
$files,
$onlyFiles,
$consoleStyle,
$errorOutput,
$container,
$defaultLevelUsed,
$memoryLimitFile
);
}
private static function setUpSignalHandler(OutputStyle $consoleStyle, string $memoryLimitFile): void
{
if (!function_exists('pcntl_signal')) {
return;
}
pcntl_signal(SIGINT, static function () use ($consoleStyle, $memoryLimitFile): void {
if (file_exists($memoryLimitFile)) {
@unlink($memoryLimitFile);
}
$consoleStyle->newLine();
exit(1);
});
}
}
src/Command/InceptionNotSuccessfulException.php 0000666 00000000174 13436755504 0015774 0 ustar 00 analyser = $analyser;
$this->memoryLimitFile = $memoryLimitFile;
$this->fileHelper = $fileHelper;
$this->currentWorkingDirectory = $currentWorkingDirectory;
}
/**
* @param string[] $files
* @param bool $onlyFiles
* @param \Symfony\Component\Console\Style\OutputStyle $style
* @param \PHPStan\Command\ErrorFormatter\ErrorFormatter $errorFormatter
* @param bool $defaultLevelUsed
* @param bool $debug
* @return int Error code.
*/
public function analyse(
array $files,
bool $onlyFiles,
OutputStyle $style,
ErrorFormatter $errorFormatter,
bool $defaultLevelUsed,
bool $debug
): int
{
$this->updateMemoryLimitFile();
$errors = [];
if (!$debug) {
$progressStarted = false;
$fileOrder = 0;
$preFileCallback = null;
$postFileCallback = function () use ($style, &$progressStarted, $files, &$fileOrder): void {
if (!$progressStarted) {
$style->progressStart(count($files));
$progressStarted = true;
}
$style->progressAdvance();
if ($fileOrder % 100 === 0) {
$this->updateMemoryLimitFile();
}
$fileOrder++;
};
} else {
$preFileCallback = static function (string $file) use ($style): void {
$style->writeln($file);
};
$postFileCallback = null;
}
$errors = array_merge($errors, $this->analyser->analyse(
$files,
$onlyFiles,
$preFileCallback,
$postFileCallback,
$debug
));
if (isset($progressStarted) && $progressStarted) {
$style->progressFinish();
}
$fileSpecificErrors = [];
$notFileSpecificErrors = [];
foreach ($errors as $error) {
if (is_string($error)) {
$notFileSpecificErrors[] = $error;
} else {
$fileSpecificErrors[] = $error;
}
}
return $errorFormatter->formatErrors(
new AnalysisResult(
$fileSpecificErrors,
$notFileSpecificErrors,
$defaultLevelUsed,
$this->fileHelper->normalizePath($this->currentWorkingDirectory)
),
$style
);
}
private function updateMemoryLimitFile(): void
{
$bytes = memory_get_peak_usage(true);
$megabytes = ceil($bytes / 1024 / 1024);
file_put_contents($this->memoryLimitFile, sprintf('%d MB', $megabytes));
if (!function_exists('pcntl_signal_dispatch')) {
return;
}
pcntl_signal_dispatch();
}
}
src/Rules/UnusedFunctionParametersCheck.php 0000666 00000004342 13436755504 0015114 0 ustar 00 getUsedVariables($scope, $statements) as $variableName) {
if (!isset($unusedParameters[$variableName])) {
continue;
}
unset($unusedParameters[$variableName]);
}
$errors = [];
foreach (array_keys($unusedParameters) as $name) {
$errors[] = sprintf($unusedParameterMessage, $name);
}
return $errors;
}
/**
* @param \PHPStan\Analyser\Scope $scope
* @param \PhpParser\Node[]|\PhpParser\Node|scalar $node
* @return string[]
*/
private function getUsedVariables(Scope $scope, $node): array
{
$variableNames = [];
if ($node instanceof Node) {
if ($node instanceof Node\Expr\Variable && is_string($node->name) && $node->name !== 'this') {
return [$node->name];
}
if ($node instanceof Node\Expr\ClosureUse && is_string($node->var->name)) {
return [$node->var->name];
}
if (
$node instanceof Node\Expr\FuncCall
&& $node->name instanceof Node\Name
&& (string) $node->name === 'compact'
) {
foreach ($node->args as $arg) {
$argType = $scope->getType($arg->value);
if (!($argType instanceof ConstantStringType)) {
continue;
}
$variableNames[] = $argType->getValue();
}
}
foreach ($node->getSubNodeNames() as $subNodeName) {
if ($node instanceof Node\Expr\Closure && $subNodeName !== 'uses') {
continue;
}
$subNode = $node->{$subNodeName};
$variableNames = array_merge($variableNames, $this->getUsedVariables($scope, $subNode));
}
} elseif (is_array($node)) {
foreach ($node as $subNode) {
$variableNames = array_merge($variableNames, $this->getUsedVariables($scope, $subNode));
}
}
return $variableNames;
}
}
src/Rules/Cast/InvalidPartOfEncapsedStringRule.php 0000666 00000002300 13436755504 0016227 0 ustar 00 printer = $printer;
}
public function getNodeType(): string
{
return \PhpParser\Node\Scalar\Encapsed::class;
}
/**
* @param \PhpParser\Node\Scalar\Encapsed $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[] errors
*/
public function processNode(Node $node, Scope $scope): array
{
$messages = [];
foreach ($node->parts as $part) {
if ($part instanceof Node\Scalar\EncapsedStringPart) {
continue;
}
$partType = $scope->getType($part);
$stringPartType = $partType->toString();
if (!$stringPartType instanceof ErrorType) {
continue;
}
$messages[] = sprintf(
'Part %s (%s) of encapsed string cannot be cast to string.',
$this->printer->prettyPrintExpr($part),
$partType->describe(VerbosityLevel::value())
);
}
return $messages;
}
}
src/Rules/Cast/UselessCastRule.php 0000666 00000002005 13436755504 0013133 0 ustar 00 getType($node);
if ($castType instanceof ErrorType) {
return [];
}
$castType = TypeUtils::generalizeType($castType);
$expressionType = $scope->getType($node->expr);
if ($castType->isSuperTypeOf($expressionType)->yes()) {
return [
sprintf(
'Casting to %s something that\'s already %s.',
$castType->describe(VerbosityLevel::typeOnly()),
$expressionType->describe(VerbosityLevel::typeOnly())
),
];
}
return [];
}
}
src/Rules/Cast/InvalidCastRule.php 0000666 00000004413 13436755504 0013103 0 ustar 00 broker = $broker;
$this->ruleLevelHelper = $ruleLevelHelper;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr\Cast::class;
}
/**
* @param \PhpParser\Node\Expr\Cast $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[] errors
*/
public function processNode(Node $node, Scope $scope): array
{
$castTypeCallback = static function (Type $type) use ($node): ?Type {
if ($node instanceof \PhpParser\Node\Expr\Cast\Int_) {
return $type->toInteger();
} elseif ($node instanceof \PhpParser\Node\Expr\Cast\Bool_) {
return $type->toBoolean();
} elseif ($node instanceof \PhpParser\Node\Expr\Cast\Double) {
return $type->toFloat();
} elseif ($node instanceof \PhpParser\Node\Expr\Cast\String_) {
return $type->toString();
}
return null;
};
$typeResult = $this->ruleLevelHelper->findTypeToCheck(
$scope,
$node->expr,
'',
static function (Type $type) use ($castTypeCallback): bool {
$castType = $castTypeCallback($type);
if ($castType === null) {
return true;
}
return !$castType instanceof ErrorType;
}
);
$type = $typeResult->getType();
if ($type instanceof ErrorType) {
return [];
}
$castType = $castTypeCallback($type);
if ($castType instanceof ErrorType) {
$classReflection = $this->broker->getClass(get_class($node));
$shortName = $classReflection->getNativeReflection()->getShortName();
$shortName = strtolower($shortName);
if ($shortName === 'double') {
$shortName = 'float';
} else {
$shortName = substr($shortName, 0, -1);
}
return [
sprintf(
'Cannot cast %s to %s.',
$scope->getType($node->expr)->describe(VerbosityLevel::value()),
$shortName
),
];
}
return [];
}
}
src/Rules/FunctionReturnTypeCheck.php 0000666 00000003377 13436755504 0013755 0 ustar 00 ruleLevelHelper = $ruleLevelHelper;
}
/**
* @param \PHPStan\Analyser\Scope $scope
* @param \PHPStan\Type\Type $returnType
* @param \PhpParser\Node\Expr|null $returnValue
* @param string $emptyReturnStatementMessage
* @param string $voidMessage
* @param string $typeMismatchMessage
* @param bool $isGenerator
* @return string[]
*/
public function checkReturnType(
Scope $scope,
Type $returnType,
?Expr $returnValue,
string $emptyReturnStatementMessage,
string $voidMessage,
string $typeMismatchMessage,
bool $isGenerator
): array
{
if ($isGenerator) {
return [];
}
$isVoidSuperType = (new VoidType())->isSuperTypeOf($returnType);
if ($returnValue === null) {
if (!$isVoidSuperType->no()) {
return [];
}
return [
sprintf(
$emptyReturnStatementMessage,
$returnType->describe(VerbosityLevel::typeOnly())
),
];
}
$returnValueType = $scope->getType($returnValue);
if ($isVoidSuperType->yes()) {
return [
sprintf(
$voidMessage,
$returnValueType->describe(VerbosityLevel::typeOnly())
),
];
}
if (!$this->ruleLevelHelper->accepts($returnType, $returnValueType, $scope->isDeclareStrictTypes())) {
return [
sprintf(
$typeMismatchMessage,
$returnType->describe(VerbosityLevel::typeOnly()),
$returnValueType->describe(VerbosityLevel::typeOnly())
),
];
}
return [];
}
}
src/Rules/Exceptions/CaughtExceptionExistenceRule.php 0000666 00000003626 13436755504 0017100 0 ustar 00 broker = $broker;
$this->classCaseSensitivityCheck = $classCaseSensitivityCheck;
$this->checkClassCaseSensitivity = $checkClassCaseSensitivity;
}
public function getNodeType(): string
{
return Catch_::class;
}
/**
* @param \PhpParser\Node\Stmt\Catch_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (isset($node->types)) {
$classes = $node->types;
} elseif (isset($node->type)) {
$classes = [$node->type];
} else {
throw new \PHPStan\ShouldNotHappenException();
}
$errors = [];
foreach ($classes as $className) {
$class = (string) $className;
if (!$this->broker->hasClass($class)) {
$errors[] = sprintf('Caught class %s not found.', $class);
continue;
}
$classReflection = $this->broker->getClass($class);
if (!$classReflection->isInterface() && !$classReflection->getNativeReflection()->implementsInterface(\Throwable::class)) {
$errors[] = sprintf('Caught class %s is not an exception.', $classReflection->getDisplayName());
}
if (!$this->checkClassCaseSensitivity) {
continue;
}
$errors = array_merge(
$errors,
$this->classCaseSensitivityCheck->checkClassNames([$class])
);
}
return $errors;
}
}
src/Rules/Classes/ExistingClassInTraitUseRule.php 0000666 00000001655 13436755504 0016142 0 ustar 00 classCaseSensitivityCheck = $classCaseSensitivityCheck;
}
public function getNodeType(): string
{
return \PhpParser\Node\Stmt\TraitUse::class;
}
/**
* @param \PhpParser\Node\Stmt\TraitUse $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
return $this->classCaseSensitivityCheck->checkClassNames(
array_map(static function (Node\Name $traitName): string {
return (string) $traitName;
}, $node->traits)
);
}
}
src/Rules/Classes/InstantiationRule.php 0000666 00000011657 13436755504 0014241 0 ustar 00 broker = $broker;
$this->check = $check;
$this->classCaseSensitivityCheck = $classCaseSensitivityCheck;
}
public function getNodeType(): string
{
return New_::class;
}
/**
* @param \PhpParser\Node\Expr\New_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if ($node->class instanceof \PhpParser\Node\Name) {
$class = (string) $node->class;
} elseif ($node->class instanceof Node\Stmt\Class_) {
$anonymousClassType = $scope->getType($node);
if (!$anonymousClassType instanceof ObjectType) {
throw new \PHPStan\ShouldNotHappenException();
}
$class = $anonymousClassType->getClassName();
} else {
return [];
}
$lowercasedClass = strtolower($class);
$messages = [];
if ($lowercasedClass === 'static') {
if (!$scope->isInClass()) {
return [
sprintf('Using %s outside of class scope.', $class),
];
}
return [];
} elseif ($lowercasedClass === 'self') {
if (!$scope->isInClass()) {
return [
sprintf('Using %s outside of class scope.', $class),
];
}
$classReflection = $scope->getClassReflection();
} elseif ($lowercasedClass === 'parent') {
if (!$scope->isInClass()) {
return [
sprintf('Using %s outside of class scope.', $class),
];
}
if ($scope->getClassReflection()->getParentClass() === false) {
return [
sprintf(
'%s::%s() calls new parent but %s does not extend any class.',
$scope->getClassReflection()->getDisplayName(),
$scope->getFunctionName(),
$scope->getClassReflection()->getDisplayName()
),
];
}
$classReflection = $scope->getClassReflection()->getParentClass();
} else {
if (!$this->broker->hasClass($class)) {
return [
sprintf('Instantiated class %s not found.', $class),
];
} else {
$messages = $this->classCaseSensitivityCheck->checkClassNames([$class]);
}
$classReflection = $this->broker->getClass($class);
}
if ($classReflection->isInterface()) {
return [
sprintf('Cannot instantiate interface %s.', $classReflection->getDisplayName()),
];
}
if ($classReflection->isAbstract()) {
return [
sprintf('Instantiated class %s is abstract.', $classReflection->getDisplayName()),
];
}
if (!$classReflection->hasConstructor()) {
if (count($node->args) > 0) {
return array_merge($messages, [
sprintf(
'Class %s does not have a constructor and must be instantiated without any parameters.',
$classReflection->getDisplayName()
),
]);
}
return $messages;
}
$constructorReflection = $classReflection->getConstructor();
if (!$scope->canCallMethod($constructorReflection)) {
$messages[] = sprintf(
'Cannot instantiate class %s via %s constructor %s::%s().',
$classReflection->getDisplayName(),
$constructorReflection->isPrivate() ? 'private' : 'protected',
$constructorReflection->getDeclaringClass()->getDisplayName(),
$constructorReflection->getName()
);
}
return array_merge($messages, $this->check->check(
ParametersAcceptorSelector::selectFromArgs(
$scope,
$node->args,
$constructorReflection->getVariants()
),
$scope,
$node,
[
'Class ' . $classReflection->getDisplayName() . ' constructor invoked with %d parameter, %d required.',
'Class ' . $classReflection->getDisplayName() . ' constructor invoked with %d parameters, %d required.',
'Class ' . $classReflection->getDisplayName() . ' constructor invoked with %d parameter, at least %d required.',
'Class ' . $classReflection->getDisplayName() . ' constructor invoked with %d parameters, at least %d required.',
'Class ' . $classReflection->getDisplayName() . ' constructor invoked with %d parameter, %d-%d required.',
'Class ' . $classReflection->getDisplayName() . ' constructor invoked with %d parameters, %d-%d required.',
'Parameter #%d %s of class ' . $classReflection->getDisplayName() . ' constructor expects %s, %s given.',
'', // constructor does not have a return type
'Parameter #%d %s of class ' . $classReflection->getDisplayName() . ' constructor is passed by reference, so it expects variables only',
]
));
}
}
src/Rules/Classes/RequireParentConstructCallRule.php 0000666 00000007264 13436755504 0016703 0 ustar 00 isInClass()) {
throw new \PHPStan\ShouldNotHappenException();
}
if ($scope->isInTrait()) {
return [];
}
if ($node->name->name !== '__construct') {
return [];
}
$classReflection = $scope->getClassReflection()->getNativeReflection();
if ($classReflection->isInterface() || $classReflection->isAnonymous()) {
return [];
}
if ($this->callsParentConstruct($node)) {
if ($classReflection->getParentClass() === false) {
return [
sprintf(
'%s::__construct() calls parent constructor but does not extend any class.',
$classReflection->getName()
),
];
}
if ($this->getParentConstructorClass($classReflection) === false) {
return [
sprintf(
'%s::__construct() calls parent constructor but parent does not have one.',
$classReflection->getName()
),
];
}
} else {
$parentClass = $this->getParentConstructorClass($classReflection);
if ($parentClass !== false) {
return [
sprintf(
'%s::__construct() does not call parent constructor from %s.',
$classReflection->getName(),
$parentClass->getName()
),
];
}
}
return [];
}
private function callsParentConstruct(Node $parserNode): bool
{
if (!isset($parserNode->stmts)) {
return false;
}
foreach ($parserNode->stmts as $statement) {
if ($statement instanceof Node\Stmt\Expression) {
$statement = $statement->expr;
}
$statement = $this->ignoreErrorSuppression($statement);
if ($statement instanceof \PhpParser\Node\Expr\StaticCall) {
if (
$statement->class instanceof Name
&& ((string) $statement->class === 'parent')
&& $statement->name instanceof Node\Identifier
&& $statement->name->name === '__construct'
) {
return true;
}
} else {
if ($this->callsParentConstruct($statement)) {
return true;
}
}
}
return false;
}
/**
* @param \ReflectionClass $classReflection
* @return \ReflectionClass|false
*/
private function getParentConstructorClass(\ReflectionClass $classReflection)
{
while ($classReflection->getParentClass() !== false) {
$constructor = $classReflection->getParentClass()->hasMethod('__construct') ? $classReflection->getParentClass()->getMethod('__construct') : null;
$constructorWithClassName = $classReflection->getParentClass()->hasMethod($classReflection->getParentClass()->getName()) ? $classReflection->getParentClass()->getMethod($classReflection->getParentClass()->getName()) : null;
if (
(
$constructor !== null
&& $constructor->getDeclaringClass()->getName() === $classReflection->getParentClass()->getName()
&& !$constructor->isAbstract()
) || (
$constructorWithClassName !== null
&& $constructorWithClassName->getDeclaringClass()->getName() === $classReflection->getParentClass()->getName()
&& !$constructorWithClassName->isAbstract()
)
) {
return $classReflection->getParentClass();
}
$classReflection = $classReflection->getParentClass();
}
return false;
}
private function ignoreErrorSuppression(Node $statement): Node
{
if ($statement instanceof Node\Expr\ErrorSuppress) {
return $statement->expr;
}
return $statement;
}
}
src/Rules/Classes/ExistingClassInInstanceOfRule.php 0000666 00000003242 13436755504 0016425 0 ustar 00 broker = $broker;
$this->classCaseSensitivityCheck = $classCaseSensitivityCheck;
$this->checkClassCaseSensitivity = $checkClassCaseSensitivity;
}
public function getNodeType(): string
{
return Instanceof_::class;
}
/**
* @param \PhpParser\Node\Expr\Instanceof_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
$class = $node->class;
if (!($class instanceof \PhpParser\Node\Name)) {
return [];
}
$name = (string) $class;
$lowercaseName = strtolower($name);
if (in_array($lowercaseName, [
'self',
'static',
'parent',
], true)) {
if (!$scope->isInClass()) {
return [
sprintf('Using %s outside of class scope.', $lowercaseName),
];
}
return [];
}
if (!$this->broker->hasClass($name)) {
return [
sprintf('Class %s not found.', $name),
];
} elseif ($this->checkClassCaseSensitivity) {
return $this->classCaseSensitivityCheck->checkClassNames([$name]);
}
return [];
}
}
src/Rules/Classes/ExistingClassesInClassImplementsRule.php 0000666 00000001653 13436755504 0020033 0 ustar 00 classCaseSensitivityCheck = $classCaseSensitivityCheck;
}
public function getNodeType(): string
{
return Node\Stmt\Class_::class;
}
/**
* @param \PhpParser\Node\Stmt\Class_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
return $this->classCaseSensitivityCheck->checkClassNames(
array_map(static function (Node\Name $traitName): string {
return (string) $traitName;
}, $node->implements)
);
}
}
src/Rules/Classes/ExistingClassInClassExtendsRule.php 0000666 00000001570 13436755504 0016776 0 ustar 00 classCaseSensitivityCheck = $classCaseSensitivityCheck;
}
public function getNodeType(): string
{
return Node\Stmt\Class_::class;
}
/**
* @param \PhpParser\Node\Stmt\Class_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if ($node->extends === null) {
return [];
}
return $this->classCaseSensitivityCheck->checkClassNames([(string) $node->extends]);
}
}
src/Rules/Classes/UnusedConstructorParametersRule.php 0000666 00000003123 13436755504 0017137 0 ustar 00 check = $check;
}
public function getNodeType(): string
{
return ClassMethod::class;
}
/**
* @param \PhpParser\Node\Stmt\ClassMethod $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (!$scope->isInClass()) {
throw new \PHPStan\ShouldNotHappenException();
}
if ($node->name->name !== '__construct' || $node->stmts === null) {
return [];
}
if (count($node->params) === 0) {
return [];
}
$message = sprintf('Constructor of class %s has an unused parameter $%%s.', $scope->getClassReflection()->getDisplayName());
if ($scope->getClassReflection()->isAnonymous()) {
$message = 'Constructor of an anonymous class has an unused parameter $%s.';
}
return $this->check->getUnusedParameters(
$scope,
array_map(static function (Param $parameter): string {
if (!$parameter->var instanceof Variable || !is_string($parameter->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
return $parameter->var->name;
}, $node->params),
$node->stmts,
$message
);
}
}
src/Rules/Classes/ExistingClassesInInterfaceExtendsRule.php 0000666 00000001661 13436755504 0020162 0 ustar 00 classCaseSensitivityCheck = $classCaseSensitivityCheck;
}
public function getNodeType(): string
{
return Node\Stmt\Interface_::class;
}
/**
* @param \PhpParser\Node\Stmt\Interface_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
return $this->classCaseSensitivityCheck->checkClassNames(
array_map(static function (Node\Name $traitName): string {
return (string) $traitName;
}, $node->extends)
);
}
}
src/Rules/Classes/ImpossibleInstanceOfRule.php 0000666 00000003167 13436755504 0015472 0 ustar 00 checkAlwaysTrueInstanceof = $checkAlwaysTrueInstanceof;
}
public function getNodeType(): string
{
return Node\Expr\Instanceof_::class;
}
/**
* @param \PhpParser\Node\Expr\Instanceof_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
$instanceofType = $scope->getType($node);
if (!$instanceofType instanceof ConstantBooleanType) {
return [];
}
$expressionType = $scope->getType($node->expr);
if ($node->class instanceof Node\Name) {
$className = $scope->resolveName($node->class);
$type = new ObjectType($className);
} else {
$type = $scope->getType($node->class);
}
if (!$instanceofType->getValue()) {
return [
sprintf(
'Instanceof between %s and %s will always evaluate to false.',
$expressionType->describe(VerbosityLevel::typeOnly()),
$type->describe(VerbosityLevel::typeOnly())
),
];
} elseif ($this->checkAlwaysTrueInstanceof) {
return [
sprintf(
'Instanceof between %s and %s will always evaluate to true.',
$expressionType->describe(VerbosityLevel::typeOnly()),
$type->describe(VerbosityLevel::typeOnly())
),
];
}
return [];
}
}
src/Rules/Classes/ClassConstantRule.php 0000666 00000010620 13436755504 0014161 0 ustar 00 broker = $broker;
$this->ruleLevelHelper = $ruleLevelHelper;
$this->classCaseSensitivityCheck = $classCaseSensitivityCheck;
}
public function getNodeType(): string
{
return ClassConstFetch::class;
}
/**
* @param \PhpParser\Node\Expr\ClassConstFetch $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (!$node->name instanceof Node\Identifier) {
return [];
}
$constantName = $node->name->name;
$class = $node->class;
$messages = [];
if ($class instanceof \PhpParser\Node\Name) {
$className = (string) $class;
$lowercasedClassName = strtolower($className);
if (in_array($lowercasedClassName, ['self', 'static'], true)) {
if (!$scope->isInClass()) {
return [
sprintf('Using %s outside of class scope.', $className),
];
}
$className = $scope->getClassReflection()->getName();
} elseif ($lowercasedClassName === 'parent') {
if (!$scope->isInClass()) {
return [
sprintf('Using %s outside of class scope.', $className),
];
}
$currentClassReflection = $scope->getClassReflection();
if ($currentClassReflection->getParentClass() === false) {
return [
sprintf(
'Access to parent::%s but %s does not extend any class.',
$constantName,
$currentClassReflection->getDisplayName()
),
];
}
$className = $currentClassReflection->getParentClass()->getName();
} else {
if (!$this->broker->hasClass($className)) {
if (strtolower($constantName) === 'class') {
return [
sprintf('Class %s not found.', $className),
];
}
return [
sprintf('Access to constant %s on an unknown class %s.', $constantName, $className),
];
} else {
$messages = $this->classCaseSensitivityCheck->checkClassNames([$className]);
}
$className = $this->broker->getClass($className)->getName();
}
$classType = new ObjectType($className);
} else {
$classTypeResult = $this->ruleLevelHelper->findTypeToCheck(
$scope,
$class,
sprintf('Access to constant %s on an unknown class %%s.', $constantName),
static function (Type $type) use ($constantName): bool {
return $type->canAccessConstants()->yes() && $type->hasConstant($constantName);
}
);
$classType = $classTypeResult->getType();
if ($classType instanceof ErrorType) {
return $classTypeResult->getUnknownClassErrors();
}
}
if ((new StringType())->isSuperTypeOf($classType)->yes()) {
return $messages;
}
$typeForDescribe = $classType;
$classType = TypeCombinator::remove($classType, new StringType());
if (!$classType->canAccessConstants()->yes()) {
return array_merge($messages, [
sprintf('Cannot access constant %s on %s.', $constantName, $typeForDescribe->describe(VerbosityLevel::typeOnly())),
]);
}
if (strtolower($constantName) === 'class') {
return $messages;
}
if (!$classType->hasConstant($constantName)) {
return array_merge($messages, [
sprintf(
'Access to undefined constant %s::%s.',
$typeForDescribe->describe(VerbosityLevel::typeOnly()),
$constantName
),
]);
}
$constantReflection = $classType->getConstant($constantName);
if (!$scope->canAccessConstant($constantReflection)) {
return array_merge($messages, [
sprintf(
'Access to %s constant %s of class %s.',
$constantReflection->isPrivate() ? 'private' : 'protected',
$constantName,
$constantReflection->getDeclaringClass()->getDisplayName()
),
]);
}
return $messages;
}
}
src/Rules/Comparison/TernaryOperatorConstantConditionRule.php 0000666 00000001662 13436755504 0020646 0 ustar 00 helper = $helper;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr\Ternary::class;
}
/**
* @param \PhpParser\Node\Expr\Ternary $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(
\PhpParser\Node $node,
\PHPStan\Analyser\Scope $scope
): array
{
$exprType = $this->helper->getBooleanType($scope, $node->cond);
if ($exprType instanceof ConstantBooleanType) {
return [
sprintf(
'Ternary operator condition is always %s.',
$exprType->getValue() ? 'true' : 'false'
),
];
}
return [];
}
}
src/Rules/Comparison/ImpossibleCheckTypeHelper.php 0000666 00000012626 13436755504 0016345 0 ustar 00 broker = $broker;
$this->typeSpecifier = $typeSpecifier;
}
public function findSpecifiedType(
Scope $scope,
Expr $node
): ?bool
{
if (
$node instanceof FuncCall
&& count($node->args) > 0
) {
if ($node->name instanceof \PhpParser\Node\Name) {
$functionName = strtolower((string) $node->name);
if ($functionName === 'is_numeric') {
$argType = $scope->getType($node->args[0]->value);
if (count(TypeUtils::getConstantScalars($argType)) > 0) {
return !$argType->toNumber() instanceof ErrorType;
}
if (!(new StringType())->isSuperTypeOf($argType)->no()) {
return null;
}
} elseif ($functionName === 'defined') {
return null;
} elseif (
$functionName === 'in_array'
&& count($node->args) >= 3
) {
$needleType = $scope->getType($node->args[0]->value);
$valueType = $scope->getType($node->args[1]->value)->getIterableValueType();
$hasConstantNeedleTypes = count(TypeUtils::getConstantScalars($needleType)) > 0;
$hasConstantHaystackTypes = count(TypeUtils::getConstantScalars($valueType)) > 0;
if (
$valueType->isSuperTypeOf($needleType)->yes()
&& (
(
!$hasConstantNeedleTypes
&& !$hasConstantHaystackTypes
)
|| $hasConstantNeedleTypes !== $hasConstantHaystackTypes
)
) {
return null;
}
} elseif (
$functionName === 'property_exists'
&& count($node->args) >= 2
) {
$classNames = TypeUtils::getDirectClassNames(
$scope->getType($node->args[0]->value)
);
foreach ($classNames as $className) {
if (!$this->broker->hasClass($className)) {
continue;
}
if (UniversalObjectCratesClassReflectionExtension::isUniversalObjectCrate(
$this->broker,
$this->broker->getUniversalObjectCratesClasses(),
$this->broker->getClass($className)
)) {
return null;
}
}
}
}
}
$specifiedTypes = $this->typeSpecifier->specifyTypesInCondition($scope, $node, TypeSpecifierContext::createTruthy());
$sureTypes = $specifiedTypes->getSureTypes();
$sureNotTypes = $specifiedTypes->getSureNotTypes();
$isSpecified = static function (Expr $expr) use ($scope, $node): bool {
return (
$node instanceof FuncCall
|| $node instanceof MethodCall
|| $node instanceof Expr\StaticCall
) && $scope->isSpecified($expr);
};
if (count($sureTypes) === 1) {
$sureType = reset($sureTypes);
if ($isSpecified($sureType[0])) {
return null;
}
$argumentType = $scope->getType($sureType[0]);
/** @var \PHPStan\Type\Type $resultType */
$resultType = $sureType[1];
$isSuperType = $resultType->isSuperTypeOf($argumentType);
if ($isSuperType->yes()) {
return true;
} elseif ($isSuperType->no()) {
return false;
}
return null;
} elseif (count($sureNotTypes) === 1) {
$sureNotType = reset($sureNotTypes);
if ($isSpecified($sureNotType[0])) {
return null;
}
$argumentType = $scope->getType($sureNotType[0]);
/** @var \PHPStan\Type\Type $resultType */
$resultType = $sureNotType[1];
$isSuperType = $resultType->isSuperTypeOf($argumentType);
if ($isSuperType->yes()) {
return false;
} elseif ($isSuperType->no()) {
return true;
}
return null;
} elseif (count($sureTypes) > 0) {
foreach ($sureTypes as $sureType) {
if ($isSpecified($sureType[0])) {
return null;
}
}
$types = TypeCombinator::union(...array_map(static function ($sureType) {
return $sureType[1];
}, array_values($sureTypes)));
if ($types instanceof NeverType) {
return false;
}
} elseif (count($sureNotTypes) > 0) {
foreach ($sureNotTypes as $sureNotType) {
if ($isSpecified($sureNotType[0])) {
return null;
}
}
$types = TypeCombinator::union(...array_map(static function ($sureNotType) {
return $sureNotType[1];
}, array_values($sureNotTypes)));
if ($types instanceof NeverType) {
return true;
}
}
return null;
}
/**
* @param Scope $scope
* @param \PhpParser\Node\Arg[] $args
* @return string
*/
public function getArgumentsDescription(
Scope $scope,
array $args
): string
{
if (count($args) === 0) {
return '';
}
$descriptions = array_map(static function (Arg $arg) use ($scope): string {
return $scope->getType($arg->value)->describe(VerbosityLevel::value());
}, $args);
if (count($descriptions) < 3) {
return sprintf(' with %s', implode(' and ', $descriptions));
}
$lastDescription = array_pop($descriptions);
return sprintf(
' with arguments %s and %s',
implode(', ', $descriptions),
$lastDescription
);
}
}
src/Rules/Comparison/ImpossibleCheckTypeStaticMethodCallRule.php 0000666 00000005052 13436755504 0021135 0 ustar 00 impossibleCheckTypeHelper = $impossibleCheckTypeHelper;
$this->checkAlwaysTrueCheckTypeFunctionCall = $checkAlwaysTrueCheckTypeFunctionCall;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr\StaticCall::class;
}
/**
* @param \PhpParser\Node\Expr\StaticCall $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[] errors
*/
public function processNode(Node $node, Scope $scope): array
{
if (!$node->name instanceof Node\Identifier) {
return [];
}
$isAlways = $this->impossibleCheckTypeHelper->findSpecifiedType($scope, $node);
if ($isAlways === null) {
return [];
}
if (!$isAlways) {
$method = $this->getMethod($node->class, $node->name->name, $scope);
return [sprintf(
'Call to static method %s::%s()%s will always evaluate to false.',
$method->getDeclaringClass()->getDisplayName(),
$method->getName(),
$this->impossibleCheckTypeHelper->getArgumentsDescription($scope, $node->args)
)];
} elseif ($this->checkAlwaysTrueCheckTypeFunctionCall) {
$method = $this->getMethod($node->class, $node->name->name, $scope);
return [sprintf(
'Call to static method %s::%s()%s will always evaluate to true.',
$method->getDeclaringClass()->getDisplayName(),
$method->getName(),
$this->impossibleCheckTypeHelper->getArgumentsDescription($scope, $node->args)
)];
}
return [];
}
/**
* @param Node\Name|Expr $class
* @param string $methodName
* @param Scope $scope
* @return MethodReflection
* @throws \PHPStan\ShouldNotHappenException
*/
private function getMethod(
$class,
string $methodName,
Scope $scope
): MethodReflection
{
if ($class instanceof Node\Name) {
$calledOnType = new ObjectType($scope->resolveName($class));
} else {
$calledOnType = $scope->getType($class);
}
if (!$calledOnType->hasMethod($methodName)) {
throw new \PHPStan\ShouldNotHappenException();
}
return $calledOnType->getMethod($methodName, $scope);
}
}
src/Rules/Comparison/BooleanAndConstantConditionRule.php 0000666 00000002736 13436755504 0017513 0 ustar 00 helper = $helper;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr\BinaryOp\BooleanAnd::class;
}
/**
* @param \PhpParser\Node\Expr\BinaryOp\BooleanAnd $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(
\PhpParser\Node $node,
\PHPStan\Analyser\Scope $scope
): array
{
$messages = [];
$leftType = $this->helper->getBooleanType($scope, $node->left);
if ($leftType instanceof ConstantBooleanType) {
$messages[] = sprintf(
'Left side of && is always %s.',
$leftType->getValue() ? 'true' : 'false'
);
}
$rightType = $this->helper->getBooleanType(
$scope->filterByTruthyValue($node->left),
$node->right
);
if ($rightType instanceof ConstantBooleanType) {
$messages[] = sprintf(
'Right side of && is always %s.',
$rightType->getValue() ? 'true' : 'false'
);
}
if (count($messages) === 0) {
$nodeType = $scope->getType($node);
if ($nodeType instanceof ConstantBooleanType) {
$messages[] = sprintf(
'Result of && is always %s.',
$nodeType->getValue() ? 'true' : 'false'
);
}
}
return $messages;
}
}
src/Rules/Comparison/ElseIfConstantConditionRule.php 0000666 00000001637 13436755504 0016657 0 ustar 00 helper = $helper;
}
public function getNodeType(): string
{
return \PhpParser\Node\Stmt\ElseIf_::class;
}
/**
* @param \PhpParser\Node\Stmt\ElseIf_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(
\PhpParser\Node $node,
\PHPStan\Analyser\Scope $scope
): array
{
$exprType = $this->helper->getBooleanType($scope, $node->cond);
if ($exprType instanceof ConstantBooleanType) {
return [
sprintf(
'Elseif condition is always %s.',
$exprType->getValue() ? 'true' : 'false'
),
];
}
return [];
}
}
src/Rules/Comparison/IfConstantConditionRule.php 0000666 00000001617 13436755504 0016044 0 ustar 00 helper = $helper;
}
public function getNodeType(): string
{
return \PhpParser\Node\Stmt\If_::class;
}
/**
* @param \PhpParser\Node\Stmt\If_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(
\PhpParser\Node $node,
\PHPStan\Analyser\Scope $scope
): array
{
$exprType = $this->helper->getBooleanType($scope, $node->cond);
if ($exprType instanceof ConstantBooleanType) {
return [
sprintf(
'If condition is always %s.',
$exprType->getValue() ? 'true' : 'false'
),
];
}
return [];
}
}
src/Rules/Comparison/ConstantConditionRuleHelper.php 0000666 00000002442 13436755504 0016722 0 ustar 00 impossibleCheckTypeHelper = $impossibleCheckTypeHelper;
}
public function getBooleanType(Scope $scope, Expr $expr): BooleanType
{
if (
$expr instanceof Expr\Instanceof_
|| $expr instanceof Expr\BinaryOp\Identical
|| $expr instanceof Expr\BinaryOp\NotIdentical
|| $expr instanceof Expr\BooleanNot
|| $expr instanceof Expr\BinaryOp\BooleanOr
|| $expr instanceof Expr\BinaryOp\BooleanAnd
|| $expr instanceof Expr\Ternary
|| $expr instanceof Expr\Isset_
) {
// already checked by different rules
return new BooleanType();
}
if (
$expr instanceof FuncCall
|| $expr instanceof MethodCall
|| $expr instanceof Expr\StaticCall
) {
$isAlways = $this->impossibleCheckTypeHelper->findSpecifiedType($scope, $expr);
if ($isAlways !== null) {
return new BooleanType();
}
}
return $scope->getType($expr)->toBoolean();
}
}
src/Rules/Comparison/ImpossibleCheckTypeFunctionCallRule.php 0000666 00000003273 13436755504 0020335 0 ustar 00 impossibleCheckTypeHelper = $impossibleCheckTypeHelper;
$this->checkAlwaysTrueCheckTypeFunctionCall = $checkAlwaysTrueCheckTypeFunctionCall;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr\FuncCall::class;
}
/**
* @param \PhpParser\Node\Expr\FuncCall $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[] errors
*/
public function processNode(Node $node, Scope $scope): array
{
if (!$node->name instanceof Node\Name) {
return [];
}
$functionName = (string) $node->name;
if (strtolower($functionName) === 'is_a') {
return [];
}
$isAlways = $this->impossibleCheckTypeHelper->findSpecifiedType($scope, $node);
if ($isAlways === null) {
return [];
}
if (!$isAlways) {
return [sprintf(
'Call to function %s()%s will always evaluate to false.',
$functionName,
$this->impossibleCheckTypeHelper->getArgumentsDescription($scope, $node->args)
)];
} elseif ($this->checkAlwaysTrueCheckTypeFunctionCall) {
return [sprintf(
'Call to function %s()%s will always evaluate to true.',
$functionName,
$this->impossibleCheckTypeHelper->getArgumentsDescription($scope, $node->args)
)];
}
return [];
}
}
src/Rules/Comparison/ImpossibleCheckTypeMethodCallRule.php 0000666 00000004322 13436755504 0017764 0 ustar 00 impossibleCheckTypeHelper = $impossibleCheckTypeHelper;
$this->checkAlwaysTrueCheckTypeFunctionCall = $checkAlwaysTrueCheckTypeFunctionCall;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr\MethodCall::class;
}
/**
* @param \PhpParser\Node\Expr\MethodCall $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[] errors
*/
public function processNode(Node $node, Scope $scope): array
{
if (!$node->name instanceof Node\Identifier) {
return [];
}
$isAlways = $this->impossibleCheckTypeHelper->findSpecifiedType($scope, $node);
if ($isAlways === null) {
return [];
}
if (!$isAlways) {
$method = $this->getMethod($node->var, $node->name->name, $scope);
return [sprintf(
'Call to method %s::%s()%s will always evaluate to false.',
$method->getDeclaringClass()->getDisplayName(),
$method->getName(),
$this->impossibleCheckTypeHelper->getArgumentsDescription($scope, $node->args)
)];
} elseif ($this->checkAlwaysTrueCheckTypeFunctionCall) {
$method = $this->getMethod($node->var, $node->name->name, $scope);
return [sprintf(
'Call to method %s::%s()%s will always evaluate to true.',
$method->getDeclaringClass()->getDisplayName(),
$method->getName(),
$this->impossibleCheckTypeHelper->getArgumentsDescription($scope, $node->args)
)];
}
return [];
}
private function getMethod(
Expr $var,
string $methodName,
Scope $scope
): MethodReflection
{
$calledOnType = $scope->getType($var);
if (!$calledOnType->hasMethod($methodName)) {
throw new \PHPStan\ShouldNotHappenException();
}
return $calledOnType->getMethod($methodName, $scope);
}
}
src/Rules/Comparison/StrictComparisonOfDifferentTypesRule.php 0000666 00000004223 13436755504 0020565 0 ustar 00 checkAlwaysTrueStrictComparison = $checkAlwaysTrueStrictComparison;
}
public function getNodeType(): string
{
return Node\Expr\BinaryOp::class;
}
/**
* @param \PhpParser\Node\Expr\BinaryOp $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[] errors
*/
public function processNode(Node $node, Scope $scope): array
{
if (!$node instanceof Node\Expr\BinaryOp\Identical && !$node instanceof Node\Expr\BinaryOp\NotIdentical) {
return [];
}
if (
$this->isSpecifiedFunctionCall($scope, $node->left)
|| $this->isSpecifiedFunctionCall($scope, $node->right)
) {
return [];
}
$nodeType = $scope->getType($node);
if (!$nodeType instanceof ConstantBooleanType) {
return [];
}
$leftType = $scope->getType($node->left);
$rightType = $scope->getType($node->right);
if (!$nodeType->getValue()) {
return [
sprintf(
'Strict comparison using %s between %s and %s will always evaluate to false.',
$node instanceof Node\Expr\BinaryOp\Identical ? '===' : '!==',
$leftType->describe(VerbosityLevel::value()),
$rightType->describe(VerbosityLevel::value())
),
];
} elseif ($this->checkAlwaysTrueStrictComparison) {
return [
sprintf(
'Strict comparison using %s between %s and %s will always evaluate to true.',
$node instanceof Node\Expr\BinaryOp\Identical ? '===' : '!==',
$leftType->describe(VerbosityLevel::value()),
$rightType->describe(VerbosityLevel::value())
),
];
}
return [];
}
private function isSpecifiedFunctionCall(Scope $scope, Expr $node): bool
{
return (
$node instanceof Expr\FuncCall
|| $node instanceof Expr\MethodCall
|| $node instanceof Expr\StaticCall
) && $scope->isSpecified($node);
}
}
src/Rules/Comparison/BooleanOrConstantConditionRule.php 0000666 00000002733 13436755504 0017366 0 ustar 00 helper = $helper;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr\BinaryOp\BooleanOr::class;
}
/**
* @param \PhpParser\Node\Expr\BinaryOp\BooleanOr $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(
\PhpParser\Node $node,
\PHPStan\Analyser\Scope $scope
): array
{
$messages = [];
$leftType = $this->helper->getBooleanType($scope, $node->left);
if ($leftType instanceof ConstantBooleanType) {
$messages[] = sprintf(
'Left side of || is always %s.',
$leftType->getValue() ? 'true' : 'false'
);
}
$rightType = $this->helper->getBooleanType(
$scope->filterByFalseyValue($node->left),
$node->right
);
if ($rightType instanceof ConstantBooleanType) {
$messages[] = sprintf(
'Right side of || is always %s.',
$rightType->getValue() ? 'true' : 'false'
);
}
if (count($messages) === 0) {
$nodeType = $scope->getType($node);
if ($nodeType instanceof ConstantBooleanType) {
$messages[] = sprintf(
'Result of || is always %s.',
$nodeType->getValue() ? 'true' : 'false'
);
}
}
return $messages;
}
}
src/Rules/Comparison/BooleanNotConstantConditionRule.php 0000666 00000001650 13436755504 0017543 0 ustar 00 helper = $helper;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr\BooleanNot::class;
}
/**
* @param \PhpParser\Node\Expr\BooleanNot $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(
\PhpParser\Node $node,
\PHPStan\Analyser\Scope $scope
): array
{
$exprType = $this->helper->getBooleanType($scope, $node->expr);
if ($exprType instanceof ConstantBooleanType) {
return [
sprintf(
'Negated boolean is always %s.',
$exprType->getValue() ? 'false' : 'true'
),
];
}
return [];
}
}
src/Rules/ClassCaseSensitivityCheck.php 0000666 00000002322 13436755504 0014227 0 ustar 00 broker = $broker;
}
/**
* @param string[] $classNames
* @return string[]
*/
public function checkClassNames(array $classNames): array
{
$messages = [];
foreach ($classNames as $className) {
if (!$this->broker->hasClass($className)) {
continue;
}
$classReflection = $this->broker->getClass($className);
$realClassName = $classReflection->getName();
if (strtolower($realClassName) !== strtolower($className)) {
continue; // skip class alias
}
if ($realClassName === $className) {
continue;
}
$messages[] = sprintf(
'%s %s referenced with incorrect case: %s.',
$this->getTypeName($classReflection),
$realClassName,
$className
);
}
return $messages;
}
private function getTypeName(ClassReflection $classReflection): string
{
if ($classReflection->isInterface()) {
return 'Interface';
} elseif ($classReflection->isTrait()) {
return 'Trait';
}
return 'Class';
}
}
src/Rules/RuleLevelHelper.php 0000666 00000011353 13436755504 0012220 0 ustar 00 broker = $broker;
$this->checkNullables = $checkNullables;
$this->checkThisOnly = $checkThisOnly;
$this->checkUnionTypes = $checkUnionTypes;
}
public function isThis(Expr $expression): bool
{
return $expression instanceof Expr\Variable && $expression->name === 'this';
}
public function accepts(Type $acceptingType, Type $acceptedType, bool $strictTypes): bool
{
if (
!$this->checkNullables
&& !$acceptingType instanceof NullType
&& !$acceptedType instanceof NullType
&& !$acceptedType instanceof BenevolentUnionType
) {
$acceptedType = TypeCombinator::removeNull($acceptedType);
}
$acceptedArrays = TypeUtils::getArrays($acceptedType);
if ($acceptingType instanceof ArrayType && count($acceptedArrays) > 0) {
foreach ($acceptedArrays as $acceptedArray) {
if ($acceptedArray instanceof ConstantArrayType) {
foreach ($acceptedArray->getKeyTypes() as $i => $keyType) {
$valueType = $acceptedArray->getValueTypes()[$i];
if (
!self::accepts(
$acceptingType->getKeyType(),
$keyType,
$strictTypes
) || !self::accepts(
$acceptingType->getItemType(),
$valueType,
$strictTypes
)
) {
return false;
}
}
} else {
if (
!self::accepts(
$acceptingType->getKeyType(),
$acceptedArray->getKeyType(),
$strictTypes
) || !self::accepts(
$acceptingType->getItemType(),
$acceptedArray->getItemType(),
$strictTypes
)
) {
return false;
}
}
}
return true;
}
if ($acceptingType instanceof UnionType && !$acceptedType instanceof CompoundType) {
foreach ($acceptingType->getTypes() as $innerType) {
if (self::accepts($innerType, $acceptedType, $strictTypes)) {
return true;
}
}
return false;
}
if ($acceptedType instanceof ArrayType && $acceptingType instanceof ArrayType) {
return self::accepts(
$acceptingType->getKeyType(),
$acceptedType->getKeyType(),
$strictTypes
) && self::accepts(
$acceptingType->getItemType(),
$acceptedType->getItemType(),
$strictTypes
);
}
$accepts = $acceptingType->accepts($acceptedType, $strictTypes);
return $this->checkUnionTypes ? $accepts->yes() : !$accepts->no();
}
/**
* @param Scope $scope
* @param Expr $var
* @param string $unknownClassErrorPattern
* @param callable(Type $type): bool $unionTypeCriteriaCallback
* @return FoundTypeResult
*/
public function findTypeToCheck(
Scope $scope,
Expr $var,
string $unknownClassErrorPattern,
callable $unionTypeCriteriaCallback
): FoundTypeResult
{
if ($this->checkThisOnly && !$this->isThis($var)) {
return new FoundTypeResult(new ErrorType(), [], []);
}
$type = $scope->getType($var);
if (!$this->checkNullables && !$type instanceof NullType) {
$type = \PHPStan\Type\TypeCombinator::removeNull($type);
}
if ($type instanceof MixedType || $type instanceof NeverType) {
return new FoundTypeResult(new ErrorType(), [], []);
}
if ($type instanceof StaticType) {
$type = $type->resolveStatic($type->getBaseClass());
}
$errors = [];
$directClassNames = TypeUtils::getDirectClassNames($type);
foreach ($directClassNames as $referencedClass) {
if ($this->broker->hasClass($referencedClass)) {
continue;
}
$errors[] = sprintf($unknownClassErrorPattern, $referencedClass);
}
if (count($errors) > 0) {
return new FoundTypeResult(new ErrorType(), [], $errors);
}
if (!$this->checkUnionTypes && $type instanceof UnionType) {
$newTypes = [];
foreach ($type->getTypes() as $innerType) {
if (!$unionTypeCriteriaCallback($innerType)) {
continue;
}
$newTypes[] = $innerType;
}
if (count($newTypes) > 0) {
return new FoundTypeResult(TypeCombinator::union(...$newTypes), $directClassNames, []);
}
}
return new FoundTypeResult($type, $directClassNames, []);
}
}
src/Rules/Rule.php 0000666 00000000633 13436755504 0010067 0 ustar 00 ruleLevelHelper = $ruleLevelHelper;
$this->checkArgumentTypes = $checkArgumentTypes;
$this->checkArgumentsPassedByReference = $checkArgumentsPassedByReference;
}
/**
* @param \PHPStan\Reflection\ParametersAcceptor $parametersAcceptor
* @param \PHPStan\Analyser\Scope $scope
* @param \PhpParser\Node\Expr\FuncCall|\PhpParser\Node\Expr\MethodCall|\PhpParser\Node\Expr\StaticCall|\PhpParser\Node\Expr\New_ $funcCall
* @param string[] $messages Eight message templates
* @return string[]
*/
public function check(
ParametersAcceptor $parametersAcceptor,
Scope $scope,
$funcCall,
array $messages
): array
{
$functionParametersMinCount = 0;
$functionParametersMaxCount = 0;
foreach ($parametersAcceptor->getParameters() as $parameter) {
if (!$parameter->isOptional()) {
$functionParametersMinCount++;
}
$functionParametersMaxCount++;
}
if ($parametersAcceptor->isVariadic()) {
$functionParametersMaxCount = -1;
}
$errors = [];
$invokedParametersCount = count($funcCall->args);
foreach ($funcCall->args as $arg) {
if ($arg->unpack) {
$invokedParametersCount = max($functionParametersMinCount, $functionParametersMaxCount);
break;
}
}
if ($invokedParametersCount < $functionParametersMinCount || $invokedParametersCount > $functionParametersMaxCount) {
if ($functionParametersMinCount === $functionParametersMaxCount) {
$errors[] = sprintf(
$invokedParametersCount === 1 ? $messages[0] : $messages[1],
$invokedParametersCount,
$functionParametersMinCount
);
} elseif ($functionParametersMaxCount === -1 && $invokedParametersCount < $functionParametersMinCount) {
$errors[] = sprintf(
$invokedParametersCount === 1 ? $messages[2] : $messages[3],
$invokedParametersCount,
$functionParametersMinCount
);
} elseif ($functionParametersMaxCount !== -1) {
$errors[] = sprintf(
$invokedParametersCount === 1 ? $messages[4] : $messages[5],
$invokedParametersCount,
$functionParametersMinCount,
$functionParametersMaxCount
);
}
}
if (
$parametersAcceptor->getReturnType() instanceof VoidType
&& !$scope->isInFirstLevelStatement()
&& !$funcCall instanceof \PhpParser\Node\Expr\New_
) {
$errors[] = $messages[7];
}
if (!$this->checkArgumentTypes && !$this->checkArgumentsPassedByReference) {
return $errors;
}
$parameters = $parametersAcceptor->getParameters();
/** @var array $args */
$args = $funcCall->args;
foreach ($args as $i => $argument) {
if (!isset($parameters[$i])) {
if (!$parametersAcceptor->isVariadic() || count($parameters) === 0) {
break;
}
$parameter = $parameters[count($parameters) - 1];
$parameterType = $parameter->getType();
if (!($parameterType instanceof ArrayType)) {
break;
}
if (!$argument->unpack) {
$parameterType = $parameterType->getItemType();
}
} else {
$parameter = $parameters[$i];
$parameterType = $parameter->getType();
if ($parameter->isVariadic()) {
if ($parameterType instanceof ArrayType && !$argument->unpack) {
$parameterType = $parameterType->getItemType();
}
} elseif ($argument->unpack) {
continue;
}
}
$argumentValueType = $scope->getType($argument->value);
$secondAccepts = null;
if ($parameterType->isIterable()->yes() && $parameter->isVariadic()) {
$secondAccepts = $this->ruleLevelHelper->accepts(
new IterableType(
new MixedType(),
$parameterType->getIterableValueType()
),
$argumentValueType,
$scope->isDeclareStrictTypes()
);
}
if (
$this->checkArgumentTypes
&& !$parameter->passedByReference()->createsNewVariable()
&& !$this->ruleLevelHelper->accepts($parameterType, $argumentValueType, $scope->isDeclareStrictTypes())
&& ($secondAccepts === null || !$secondAccepts)
) {
$errors[] = sprintf(
$messages[6],
$i + 1,
sprintf('%s$%s', $parameter->isVariadic() ? '...' : '', $parameter->getName()),
$parameterType->describe(VerbosityLevel::typeOnly()),
$argumentValueType->describe($parameterType->isCallable()->yes() ? VerbosityLevel::value() : VerbosityLevel::typeOnly())
);
}
if (
!$this->checkArgumentsPassedByReference
|| !$parameter->passedByReference()->yes()
|| $argument->value instanceof \PhpParser\Node\Expr\Variable
|| $argument->value instanceof \PhpParser\Node\Expr\ArrayDimFetch
|| $argument->value instanceof \PhpParser\Node\Expr\PropertyFetch
|| $argument->value instanceof \PhpParser\Node\Expr\StaticPropertyFetch
) {
continue;
}
$errors[] = sprintf(
$messages[8],
$i + 1,
sprintf('%s$%s', $parameter->isVariadic() ? '...' : '', $parameter->getName())
);
}
return $errors;
}
}
src/Rules/Methods/ReturnTypeRule.php 0000666 00000003660 13436755504 0013537 0 ustar 00 returnTypeCheck = $returnTypeCheck;
}
public function getNodeType(): string
{
return Return_::class;
}
/**
* @param \PhpParser\Node\Stmt\Return_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if ($scope->getFunction() === null) {
return [];
}
if ($scope->isInAnonymousFunction()) {
return [];
}
$method = $scope->getFunction();
if (!($method instanceof MethodReflection)) {
return [];
}
$reflection = null;
if ($method->getDeclaringClass()->getNativeReflection()->hasMethod($method->getName())) {
$reflection = $method->getDeclaringClass()->getNativeReflection()->getMethod($method->getName());
}
return $this->returnTypeCheck->checkReturnType(
$scope,
ParametersAcceptorSelector::selectSingle($method->getVariants())->getReturnType(),
$node->expr,
sprintf(
'Method %s::%s() should return %%s but empty return statement found.',
$method->getDeclaringClass()->getDisplayName(),
$method->getName()
),
sprintf(
'Method %s::%s() with return type void returns %%s but should not return anything.',
$method->getDeclaringClass()->getDisplayName(),
$method->getName()
),
sprintf(
'Method %s::%s() should return %%s but returns %%s.',
$method->getDeclaringClass()->getDisplayName(),
$method->getName()
),
$reflection !== null && $reflection->isGenerator()
);
}
}
src/Rules/Methods/CallStaticMethodsRule.php 0000666 00000017451 13436755504 0014770 0 ustar 00 broker = $broker;
$this->check = $check;
$this->ruleLevelHelper = $ruleLevelHelper;
$this->classCaseSensitivityCheck = $classCaseSensitivityCheck;
$this->checkFunctionNameCase = $checkFunctionNameCase;
$this->reportMagicMethods = $reportMagicMethods;
}
public function getNodeType(): string
{
return StaticCall::class;
}
/**
* @param \PhpParser\Node\Expr\StaticCall $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (!$node->name instanceof Node\Identifier) {
return [];
}
$methodName = $node->name->name;
$class = $node->class;
$errors = [];
$isInterface = false;
if ($class instanceof Name) {
$className = (string) $class;
$lowercasedClassName = strtolower($className);
if (in_array($lowercasedClassName, ['self', 'static'], true)) {
if (!$scope->isInClass()) {
return [
sprintf(
'Calling %s::%s() outside of class scope.',
$className,
$methodName
),
];
}
$className = $scope->getClassReflection()->getName();
} elseif ($lowercasedClassName === 'parent') {
if (!$scope->isInClass()) {
return [
sprintf(
'Calling %s::%s() outside of class scope.',
$className,
$methodName
),
];
}
$currentClassReflection = $scope->getClassReflection();
if ($currentClassReflection->getParentClass() === false) {
return [
sprintf(
'%s::%s() calls parent::%s() but %s does not extend any class.',
$scope->getClassReflection()->getDisplayName(),
$scope->getFunctionName(),
$methodName,
$scope->getClassReflection()->getDisplayName()
),
];
}
if ($scope->getFunctionName() === null) {
throw new \PHPStan\ShouldNotHappenException();
}
$className = $currentClassReflection->getParentClass()->getName();
} else {
if (!$this->broker->hasClass($className)) {
return [
sprintf('Call to static method %s() on an unknown class %s.', $methodName, $className),
];
} else {
$errors = $this->classCaseSensitivityCheck->checkClassNames([$className]);
}
$classReflection = $this->broker->getClass($className);
$isInterface = $classReflection->isInterface();
$className = $classReflection->getName();
}
$classType = new ObjectType($className);
} else {
$classTypeResult = $this->ruleLevelHelper->findTypeToCheck(
$scope,
$class,
sprintf('Call to static method %s() on an unknown class %%s.', $methodName),
static function (Type $type) use ($methodName): bool {
return $type->canCallMethods()->yes() && $type->hasMethod($methodName);
}
);
$classType = $classTypeResult->getType();
if ($classType instanceof ErrorType) {
return $classTypeResult->getUnknownClassErrors();
}
}
if ((new StringType())->isSuperTypeOf($classType)->yes()) {
return [];
}
$typeForDescribe = $classType;
$classType = TypeCombinator::remove($classType, new StringType());
if (!$classType->canCallMethods()->yes()) {
return array_merge($errors, [
sprintf('Cannot call static method %s() on %s.', $methodName, $typeForDescribe->describe(VerbosityLevel::typeOnly())),
]);
}
if (!$classType->hasMethod($methodName)) {
if (!$this->reportMagicMethods) {
$directClassNames = TypeUtils::getDirectClassNames($classType);
foreach ($directClassNames as $className) {
if (!$this->broker->hasClass($className)) {
continue;
}
$classReflection = $this->broker->getClass($className);
if ($classReflection->hasNativeMethod('__callStatic')) {
return [];
}
}
}
return array_merge($errors, [
sprintf(
'Call to an undefined static method %s::%s().',
$typeForDescribe->describe(VerbosityLevel::typeOnly()),
$methodName
),
]);
}
$method = $classType->getMethod($methodName, $scope);
if (!$method->isStatic()) {
$function = $scope->getFunction();
if (
!$function instanceof MethodReflection
|| $function->isStatic()
|| !$scope->isInClass()
|| (
$classType instanceof TypeWithClassName
&& $scope->getClassReflection()->getName() !== $classType->getClassName()
&& !$scope->getClassReflection()->isSubclassOf($classType->getClassName())
)
) {
return array_merge($errors, [
sprintf(
'Static call to instance method %s::%s().',
$method->getDeclaringClass()->getDisplayName(),
$method->getName()
),
]);
}
}
if (!$scope->canCallMethod($method)) {
$errors = array_merge($errors, [
sprintf(
'Call to %s %s %s() of class %s.',
$method->isPrivate() ? 'private' : 'protected',
$method->isStatic() ? 'static method' : 'method',
$method->getName(),
$method->getDeclaringClass()->getDisplayName()
),
]);
}
if ($isInterface && $method->isStatic()) {
return [
sprintf(
'Cannot call static method %s() on interface %s.',
$method->getName(),
$classType->describe(VerbosityLevel::typeOnly())
),
];
}
$lowercasedMethodName = sprintf(
'%s %s',
$method->isStatic() ? 'static method' : 'method',
$method->getDeclaringClass()->getDisplayName() . '::' . $method->getName() . '()'
);
$displayMethodName = sprintf(
'%s %s',
$method->isStatic() ? 'Static method' : 'Method',
$method->getDeclaringClass()->getDisplayName() . '::' . $method->getName() . '()'
);
$errors = array_merge($errors, $this->check->check(
ParametersAcceptorSelector::selectFromArgs(
$scope,
$node->args,
$method->getVariants()
),
$scope,
$node,
[
$displayMethodName . ' invoked with %d parameter, %d required.',
$displayMethodName . ' invoked with %d parameters, %d required.',
$displayMethodName . ' invoked with %d parameter, at least %d required.',
$displayMethodName . ' invoked with %d parameters, at least %d required.',
$displayMethodName . ' invoked with %d parameter, %d-%d required.',
$displayMethodName . ' invoked with %d parameters, %d-%d required.',
'Parameter #%d %s of ' . $lowercasedMethodName . ' expects %s, %s given.',
'Result of ' . $lowercasedMethodName . ' (void) is used.',
'Parameter #%d %s of ' . $lowercasedMethodName . ' is passed by reference, so it expects variables only.',
]
));
if (
$this->checkFunctionNameCase
&& $method->getName() !== $methodName
) {
$errors[] = sprintf('Call to %s with incorrect case: %s', $lowercasedMethodName, $methodName);
}
return $errors;
}
}
src/Rules/Methods/ExistingClassesInTypehintsRule.php 0000666 00000002220 13436755504 0016714 0 ustar 00 check = $check;
}
public function getNodeType(): string
{
return ClassMethod::class;
}
/**
* @param \PhpParser\Node\Stmt\ClassMethod $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (!$scope->isInClass()) {
throw new \PHPStan\ShouldNotHappenException();
}
return $this->check->checkFunction(
$node,
$scope,
sprintf(
'Parameter $%%s of method %s::%s() has invalid typehint type %%s.',
$scope->getClassReflection()->getDisplayName(),
$node->name->name
),
sprintf(
'Return typehint of method %s::%s() has invalid type %%s.',
$scope->getClassReflection()->getDisplayName(),
$node->name->name
)
);
}
}
src/Rules/Methods/CallMethodsRule.php 0000666 00000011665 13436755504 0013621 0 ustar 00 broker = $broker;
$this->check = $check;
$this->ruleLevelHelper = $ruleLevelHelper;
$this->checkFunctionNameCase = $checkFunctionNameCase;
$this->reportMagicMethods = $reportMagicMethods;
}
public function getNodeType(): string
{
return MethodCall::class;
}
/**
* @param \PhpParser\Node\Expr\MethodCall $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (!$node->name instanceof Node\Identifier) {
return [];
}
$name = $node->name->name;
$typeResult = $this->ruleLevelHelper->findTypeToCheck(
$scope,
$node->var,
sprintf('Call to method %s() on an unknown class %%s.', $name),
static function (Type $type) use ($name): bool {
return $type->canCallMethods()->yes() && $type->hasMethod($name);
}
);
$type = $typeResult->getType();
if ($type instanceof ErrorType) {
return $typeResult->getUnknownClassErrors();
}
if (!$type->canCallMethods()->yes()) {
return [
sprintf('Cannot call method %s() on %s.', $name, $type->describe(VerbosityLevel::typeOnly())),
];
}
if (!$type->hasMethod($name)) {
$directClassNames = $typeResult->getReferencedClasses();
if (!$this->reportMagicMethods) {
foreach ($directClassNames as $className) {
if (!$this->broker->hasClass($className)) {
continue;
}
$classReflection = $this->broker->getClass($className);
if ($classReflection->hasNativeMethod('__call')) {
return [];
}
}
}
if (count($directClassNames) === 1) {
$referencedClass = $directClassNames[0];
$methodClassReflection = $this->broker->getClass($referencedClass);
$parentClassReflection = $methodClassReflection->getParentClass();
while ($parentClassReflection !== false) {
if ($parentClassReflection->hasMethod($name)) {
return [
sprintf(
'Call to private method %s() of parent class %s.',
$parentClassReflection->getMethod($name, $scope)->getName(),
$parentClassReflection->getDisplayName()
),
];
}
$parentClassReflection = $parentClassReflection->getParentClass();
}
}
return [
sprintf(
'Call to an undefined method %s::%s().',
$type->describe(VerbosityLevel::typeOnly()),
$name
),
];
}
$methodReflection = $type->getMethod($name, $scope);
$messagesMethodName = $methodReflection->getDeclaringClass()->getDisplayName() . '::' . $methodReflection->getName() . '()';
$errors = [];
if (!$scope->canCallMethod($methodReflection)) {
$errors[] = sprintf(
'Call to %s method %s() of class %s.',
$methodReflection->isPrivate() ? 'private' : 'protected',
$methodReflection->getName(),
$methodReflection->getDeclaringClass()->getDisplayName()
);
}
$errors = array_merge($errors, $this->check->check(
ParametersAcceptorSelector::selectFromArgs(
$scope,
$node->args,
$methodReflection->getVariants()
),
$scope,
$node,
[
'Method ' . $messagesMethodName . ' invoked with %d parameter, %d required.',
'Method ' . $messagesMethodName . ' invoked with %d parameters, %d required.',
'Method ' . $messagesMethodName . ' invoked with %d parameter, at least %d required.',
'Method ' . $messagesMethodName . ' invoked with %d parameters, at least %d required.',
'Method ' . $messagesMethodName . ' invoked with %d parameter, %d-%d required.',
'Method ' . $messagesMethodName . ' invoked with %d parameters, %d-%d required.',
'Parameter #%d %s of method ' . $messagesMethodName . ' expects %s, %s given.',
'Result of method ' . $messagesMethodName . ' (void) is used.',
'Parameter #%d %s of method ' . $messagesMethodName . ' is passed by reference, so it expects variables only.',
]
));
if (
$this->checkFunctionNameCase
&& strtolower($methodReflection->getName()) === strtolower($name)
&& $methodReflection->getName() !== $name
) {
$errors[] = sprintf('Call to method %s with incorrect case: %s', $messagesMethodName, $name);
}
return $errors;
}
}
src/Rules/Arrays/DuplicateKeysInLiteralArraysRule.php 0000666 00000003213 13436755504 0017002 0 ustar 00 printer = $printer;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr\Array_::class;
}
/**
* @param \PhpParser\Node\Expr\Array_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(\PhpParser\Node $node, Scope $scope): array
{
$values = [];
$duplicateKeys = [];
$printedValues = [];
foreach ($node->items as $item) {
if ($item === null) {
continue;
}
if ($item->key === null) {
continue;
}
$key = $item->key;
$keyType = $scope->getType($key);
if (
!$keyType instanceof ConstantScalarType
) {
continue;
}
$printedValue = $this->printer->prettyPrintExpr($key);
$value = $keyType->getValue();
$printedValues[$value][] = $printedValue;
$previousCount = count($values);
$values[$value] = $printedValue;
if ($previousCount !== count($values)) {
continue;
}
$duplicateKeys[$value] = true;
}
$messages = [];
foreach (array_keys($duplicateKeys) as $value) {
$messages[] = sprintf(
'Array has %d %s with value %s (%s).',
count($printedValues[$value]),
count($printedValues[$value]) === 1 ? 'duplicate key' : 'duplicate keys',
var_export($value, true),
implode(', ', $printedValues[$value])
);
}
return $messages;
}
}
src/Rules/Arrays/AppendedArrayKeyTypeRule.php 0000666 00000004366 13436755504 0015312 0 ustar 00 propertyReflectionFinder = $propertyReflectionFinder;
$this->checkUnionTypes = $checkUnionTypes;
}
public function getNodeType(): string
{
return Assign::class;
}
/**
* @param \PhpParser\Node\Expr\Assign $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(\PhpParser\Node $node, Scope $scope): array
{
if (!($node->var instanceof ArrayDimFetch)) {
return [];
}
if (
!$node->var->var instanceof \PhpParser\Node\Expr\PropertyFetch
&& !$node->var->var instanceof \PhpParser\Node\Expr\StaticPropertyFetch
) {
return [];
}
$propertyReflection = $this->propertyReflectionFinder->findPropertyReflectionFromNode($node->var->var, $scope);
if ($propertyReflection === null) {
return [];
}
$arrayType = $propertyReflection->getType();
if (!$arrayType instanceof ArrayType) {
return [];
}
if ($node->var->dim !== null) {
$dimensionType = $scope->getType($node->var->dim);
$isValidKey = AllowedArrayKeysTypes::getType()->isSuperTypeOf($dimensionType);
if (!$isValidKey->yes()) {
// already handled by InvalidKeyInArrayDimFetchRule
return [];
}
$keyType = ArrayType::castToArrayKeyType($dimensionType);
if (!$this->checkUnionTypes && $keyType instanceof UnionType) {
return [];
}
} else {
$keyType = new IntegerType();
}
if (!$arrayType->getIterableKeyType()->isSuperTypeOf($keyType)->yes()) {
return [
sprintf(
'Array (%s) does not accept key %s.',
$arrayType->describe(VerbosityLevel::typeOnly()),
$keyType->describe(VerbosityLevel::value())
),
];
}
return [];
}
}
src/Rules/Arrays/AppendedArrayItemTypeRule.php 0000666 00000004257 13436755504 0015457 0 ustar 00 propertyReflectionFinder = $propertyReflectionFinder;
$this->ruleLevelHelper = $ruleLevelHelper;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr::class;
}
/**
* @param \PhpParser\Node\Expr $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(\PhpParser\Node $node, Scope $scope): array
{
if (
!$node instanceof Assign
&& !$node instanceof AssignOp
) {
return [];
}
if (!($node->var instanceof ArrayDimFetch)) {
return [];
}
if (
!$node->var->var instanceof \PhpParser\Node\Expr\PropertyFetch
&& !$node->var->var instanceof \PhpParser\Node\Expr\StaticPropertyFetch
) {
return [];
}
$propertyReflection = $this->propertyReflectionFinder->findPropertyReflectionFromNode($node->var->var, $scope);
if ($propertyReflection === null) {
return [];
}
$assignedToType = $propertyReflection->getType();
if (!($assignedToType instanceof ArrayType)) {
return [];
}
if ($node instanceof Assign) {
$assignedValueType = $scope->getType($node->expr);
} else {
$assignedValueType = $scope->getType($node);
}
if (!$this->ruleLevelHelper->accepts($assignedToType->getItemType(), $assignedValueType, $scope->isDeclareStrictTypes())) {
return [
sprintf(
'Array (%s) does not accept %s.',
$assignedToType->describe(VerbosityLevel::typeOnly()),
$assignedValueType->describe(VerbosityLevel::typeOnly())
),
];
}
return [];
}
}
src/Rules/Arrays/IterableInForeachRule.php 0000666 00000002501 13436755504 0014553 0 ustar 00 ruleLevelHelper = $ruleLevelHelper;
}
public function getNodeType(): string
{
return \PhpParser\Node\Stmt\Foreach_::class;
}
/**
* @param \PhpParser\Node\Stmt\Foreach_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
$typeResult = $this->ruleLevelHelper->findTypeToCheck(
$scope,
$node->expr,
'Iterating over an object of an unknown class %s.',
static function (Type $type): bool {
return $type->isIterable()->yes();
}
);
$type = $typeResult->getType();
if ($type instanceof ErrorType) {
return $typeResult->getUnknownClassErrors();
}
if ($type->isIterable()->yes()) {
return [];
}
return [
sprintf(
'Argument of an invalid type %s supplied for foreach, only iterables are supported.',
$type->describe(VerbosityLevel::typeOnly())
),
];
}
}
src/Rules/Arrays/NonexistentOffsetInArrayDimFetchRule.php 0000666 00000005273 13436755504 0017635 0 ustar 00 ruleLevelHelper = $ruleLevelHelper;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr\ArrayDimFetch::class;
}
/**
* @param \PhpParser\Node\Expr\ArrayDimFetch $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(\PhpParser\Node $node, Scope $scope): array
{
if ($node->dim !== null) {
$dimType = $scope->getType($node->dim);
$unknownClassPattern = sprintf('Access to offset %s on an unknown class %%s.', $dimType->describe(VerbosityLevel::value()));
} else {
$dimType = null;
$unknownClassPattern = 'Access to an offset on an unknown class %s.';
}
$typeResult = $this->ruleLevelHelper->findTypeToCheck(
$scope,
$node->var,
$unknownClassPattern,
static function (Type $type) use ($dimType): bool {
if ($dimType === null) {
return $type->isOffsetAccessible()->yes();
}
return $type->isOffsetAccessible()->yes() && $type->hasOffsetValueType($dimType)->yes();
}
);
$type = $typeResult->getType();
if ($type instanceof ErrorType) {
return $typeResult->getUnknownClassErrors();
}
$isOffsetAccessible = $type->isOffsetAccessible();
if ($scope->isInExpressionAssign($node) && !$isOffsetAccessible->no()) {
return [];
}
if (!$isOffsetAccessible->yes()) {
if ($dimType !== null) {
return [
sprintf(
'Cannot access offset %s on %s.',
$dimType->describe(VerbosityLevel::value()),
$type->describe(VerbosityLevel::value())
),
];
}
return [
sprintf(
'Cannot access an offset on %s.',
$type->describe(VerbosityLevel::typeOnly())
),
];
}
if ($dimType === null) {
return [];
}
$hasOffsetValueType = $type->hasOffsetValueType($dimType);
$report = $hasOffsetValueType->no();
if ($hasOffsetValueType->maybe()) {
$constantArrays = TypeUtils::getConstantArrays($type);
if (count($constantArrays) > 0) {
foreach ($constantArrays as $constantArray) {
if ($constantArray->hasOffsetValueType($dimType)->no()) {
$report = true;
break;
}
}
}
}
if ($report) {
return [
sprintf('Offset %s does not exist on %s.', $dimType->describe(VerbosityLevel::value()), $type->describe(VerbosityLevel::value())),
];
}
return [];
}
}
src/Rules/Arrays/InvalidKeyInArrayDimFetchRule.php 0000666 00000002537 13436755504 0016207 0 ustar 00 reportMaybes = $reportMaybes;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr\ArrayDimFetch::class;
}
/**
* @param \PhpParser\Node\Expr\ArrayDimFetch $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(\PhpParser\Node $node, Scope $scope): array
{
if ($node->dim === null) {
return [];
}
$varType = $scope->getType($node->var);
if (count(TypeUtils::getArrays($varType)) === 0) {
return [];
}
$dimensionType = $scope->getType($node->dim);
$isSuperType = AllowedArrayKeysTypes::getType()->isSuperTypeOf($dimensionType);
if ($isSuperType->no()) {
return [
sprintf('Invalid array key type %s.', $dimensionType->describe(VerbosityLevel::typeOnly())),
];
} elseif ($this->reportMaybes && $isSuperType->maybe() && !$dimensionType instanceof MixedType) {
return [
sprintf('Possibly invalid array key type %s.', $dimensionType->describe(VerbosityLevel::typeOnly())),
];
}
return [];
}
}
src/Rules/Arrays/InvalidKeyInArrayItemRule.php 0000666 00000002305 13436755504 0015413 0 ustar 00 reportMaybes = $reportMaybes;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr\ArrayItem::class;
}
/**
* @param \PhpParser\Node\Expr\ArrayItem $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(\PhpParser\Node $node, Scope $scope): array
{
if ($node->key === null) {
return [];
}
$dimensionType = $scope->getType($node->key);
$isSuperType = AllowedArrayKeysTypes::getType()->isSuperTypeOf($dimensionType);
if ($isSuperType->no()) {
return [
sprintf('Invalid array key type %s.', $dimensionType->describe(VerbosityLevel::typeOnly())),
];
} elseif ($this->reportMaybes && $isSuperType->maybe() && !$dimensionType instanceof MixedType) {
return [
sprintf('Possibly invalid array key type %s.', $dimensionType->describe(VerbosityLevel::typeOnly())),
];
}
return [];
}
}
src/Rules/Arrays/AllowedArrayKeysTypes.php 0000666 00000000736 13436755504 0014674 0 ustar 00 broker = $broker;
$this->classCaseSensitivityCheck = $classCaseSensitivityCheck;
$this->checkClassCaseSensitivity = $checkClassCaseSensitivity;
$this->checkThisOnly = $checkThisOnly;
}
/**
* @param \PhpParser\Node\FunctionLike $function
* @param \PHPStan\Analyser\Scope $scope
* @param string $parameterMessage
* @param string $returnMessage
* @return string[]
*/
public function checkFunction(
FunctionLike $function,
Scope $scope,
string $parameterMessage,
string $returnMessage
): array
{
if ($function instanceof ClassMethod) {
if (!$scope->isInClass()) {
throw new \PHPStan\ShouldNotHappenException();
}
$nativeMethod = $scope->getClassReflection()->getNativeMethod($function->name->name);
if (!$nativeMethod instanceof PhpMethodReflection) {
return [];
}
/** @var \PHPStan\Reflection\ParametersAcceptorWithPhpDocs $parametersAcceptor */
$parametersAcceptor = ParametersAcceptorSelector::selectSingle($nativeMethod->getVariants());
return $this->checkParametersAcceptor(
$parametersAcceptor,
$parameterMessage,
$returnMessage
);
}
if ($function instanceof Function_) {
$functionName = $function->name->name;
if (isset($function->namespacedName)) {
$functionName = (string) $function->namespacedName;
}
$functionNameName = new Name($functionName);
if (!$this->broker->hasCustomFunction($functionNameName, null)) {
return [];
}
$functionReflection = $this->broker->getCustomFunction($functionNameName, null);
/** @var \PHPStan\Reflection\ParametersAcceptorWithPhpDocs $parametersAcceptor */
$parametersAcceptor = ParametersAcceptorSelector::selectSingle($functionReflection->getVariants());
return $this->checkParametersAcceptor(
$parametersAcceptor,
$parameterMessage,
$returnMessage
);
}
$errors = [];
foreach ($function->getParams() as $param) {
$class = $param->type instanceof NullableType
? (string) $param->type->type
: (string) $param->type;
$lowercasedClass = strtolower($class);
if ($lowercasedClass === '' || in_array($lowercasedClass, self::VALID_TYPEHINTS, true)) {
continue;
}
if (!$this->broker->hasClass($class)) {
if (!$param->var instanceof Variable || !is_string($param->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
$errors[] = sprintf($parameterMessage, $param->var->name, $class);
} elseif ($this->checkClassCaseSensitivity) {
$errors = array_merge(
$errors,
$this->classCaseSensitivityCheck->checkClassNames([$class])
);
}
}
$returnType = $function->getReturnType() instanceof NullableType
? (string) $function->getReturnType()->type
: (string) $function->getReturnType();
$lowercasedReturnType = strtolower($returnType);
if (
$lowercasedReturnType !== ''
&& !in_array($lowercasedReturnType, self::VALID_TYPEHINTS, true)
) {
if (!$this->broker->hasClass($returnType)) {
$errors[] = sprintf($returnMessage, $returnType);
} elseif ($this->checkClassCaseSensitivity) {
$errors = array_merge(
$errors,
$this->classCaseSensitivityCheck->checkClassNames([$returnType])
);
}
}
return $errors;
}
/**
* @param ParametersAcceptorWithPhpDocs $parametersAcceptor
* @param string $parameterMessage
* @param string $returnMessage
* @return string[]
*/
private function checkParametersAcceptor(
ParametersAcceptorWithPhpDocs $parametersAcceptor,
string $parameterMessage,
string $returnMessage
): array
{
$errors = [];
foreach ($parametersAcceptor->getParameters() as $parameter) {
if ($this->checkThisOnly) {
$referencedClasses = $parameter->getType()->getReferencedClasses();
} else {
$referencedClasses = array_merge(
$parameter->getNativeType()->getReferencedClasses(),
$parameter->getPhpDocType()->getReferencedClasses()
);
}
foreach ($referencedClasses as $class) {
if ($this->broker->hasClass($class) && !$this->broker->getClass($class)->isTrait()) {
continue;
}
$errors[] = sprintf($parameterMessage, $parameter->getName(), $class);
}
if ($this->checkClassCaseSensitivity) {
$errors = array_merge(
$errors,
$this->classCaseSensitivityCheck->checkClassNames($referencedClasses)
);
}
if (!($parameter->getType() instanceof NonexistentParentClassType)) {
continue;
}
$errors[] = sprintf($parameterMessage, $parameter->getName(), $parameter->getType()->describe(VerbosityLevel::typeOnly()));
}
if ($this->checkThisOnly) {
$returnTypeReferencedClasses = $parametersAcceptor->getReturnType()->getReferencedClasses();
} else {
$returnTypeReferencedClasses = array_merge(
$parametersAcceptor->getNativeReturnType()->getReferencedClasses(),
$parametersAcceptor->getPhpDocReturnType()->getReferencedClasses()
);
}
foreach ($returnTypeReferencedClasses as $class) {
if ($this->broker->hasClass($class) && !$this->broker->getClass($class)->isTrait()) {
continue;
}
$errors[] = sprintf($returnMessage, $class);
}
if ($this->checkClassCaseSensitivity) {
$errors = array_merge(
$errors,
$this->classCaseSensitivityCheck->checkClassNames($returnTypeReferencedClasses)
);
}
if ($parametersAcceptor->getReturnType() instanceof NonexistentParentClassType) {
$errors[] = sprintf($returnMessage, $parametersAcceptor->getReturnType()->describe(VerbosityLevel::typeOnly()));
}
return $errors;
}
}
src/Rules/Properties/PropertyReflectionFinder.php 0000666 00000003034 13436755504 0016301 0 ustar 00 name instanceof \PhpParser\Node\Identifier) {
return null;
}
$propertyHolderType = $scope->getType($propertyFetch->var);
return $this->findPropertyReflection($propertyHolderType, $propertyFetch->name->name, $scope);
}
if (!$propertyFetch->name instanceof \PhpParser\Node\Identifier) {
return null;
}
if ($propertyFetch->class instanceof \PhpParser\Node\Name) {
$propertyHolderType = new ObjectType($scope->resolveName($propertyFetch->class));
} else {
$propertyHolderType = $scope->getType($propertyFetch->class);
}
return $this->findPropertyReflection($propertyHolderType, $propertyFetch->name->name, $scope);
}
private function findPropertyReflection(Type $propertyHolderType, string $propertyName, Scope $scope): ?\PHPStan\Reflection\PropertyReflection
{
if (!$propertyHolderType->hasProperty($propertyName)) {
return null;
}
return $propertyHolderType->getProperty($propertyName, $scope);
}
}
src/Rules/Properties/ExistingClassesInPropertiesRule.php 0000666 00000004146 13436755504 0017623 0 ustar 00 broker = $broker;
$this->classCaseSensitivityCheck = $classCaseSensitivityCheck;
$this->checkClassCaseSensitivity = $checkClassCaseSensitivity;
}
public function getNodeType(): string
{
return PropertyProperty::class;
}
/**
* @param \PhpParser\Node\Stmt\PropertyProperty $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (!$scope->isInClass()) {
throw new \PHPStan\ShouldNotHappenException();
}
$propertyReflection = $scope->getClassReflection()->getNativeProperty($node->name->name);
$propertyType = $propertyReflection->getType();
$errors = [];
foreach ($propertyType->getReferencedClasses() as $referencedClass) {
if ($this->broker->hasClass($referencedClass)) {
if ($this->broker->getClass($referencedClass)->isTrait()) {
$errors[] = sprintf(
'Property %s::$%s has invalid type %s.',
$propertyReflection->getDeclaringClass()->getDisplayName(),
$node->name->name,
$referencedClass
);
}
continue;
}
$errors[] = sprintf(
'Property %s::$%s has unknown class %s as its type.',
$propertyReflection->getDeclaringClass()->getDisplayName(),
$node->name->name,
$referencedClass
);
}
if ($this->checkClassCaseSensitivity) {
$errors = array_merge(
$errors,
$this->classCaseSensitivityCheck->checkClassNames($propertyType->getReferencedClasses())
);
}
return $errors;
}
}
src/Rules/Properties/ReadingWriteOnlyPropertiesRule.php 0000666 00000003721 13436755504 0017450 0 ustar 00 propertyDescriptor = $propertyDescriptor;
$this->propertyReflectionFinder = $propertyReflectionFinder;
$this->ruleLevelHelper = $ruleLevelHelper;
$this->checkThisOnly = $checkThisOnly;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr::class;
}
/**
* @param \PhpParser\Node\Expr $node
* @param Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (
!($node instanceof Node\Expr\PropertyFetch)
&& !($node instanceof Node\Expr\StaticPropertyFetch)
) {
return [];
}
if (
$node instanceof Node\Expr\PropertyFetch
&& $this->checkThisOnly
&& !$this->ruleLevelHelper->isThis($node->var)
) {
return [];
}
if ($scope->isInExpressionAssign($node)) {
return [];
}
$propertyReflection = $this->propertyReflectionFinder->findPropertyReflectionFromNode($node, $scope);
if ($propertyReflection === null) {
return [];
}
if (!$scope->canAccessProperty($propertyReflection)) {
return [];
}
if (!$propertyReflection->isReadable()) {
$propertyDescription = $this->propertyDescriptor->describeProperty($propertyReflection, $node);
return [
sprintf(
'%s is not readable.',
$propertyDescription
),
];
}
return [];
}
}
src/Rules/Properties/AccessStaticPropertiesRule.php 0000666 00000012134 13436755504 0016571 0 ustar 00 broker = $broker;
$this->ruleLevelHelper = $ruleLevelHelper;
$this->classCaseSensitivityCheck = $classCaseSensitivityCheck;
}
public function getNodeType(): string
{
return StaticPropertyFetch::class;
}
/**
* @param \PhpParser\Node\Expr\StaticPropertyFetch $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (!$node->name instanceof Node\VarLikeIdentifier) {
return [];
}
$name = $node->name->name;
$messages = [];
if ($node->class instanceof Name) {
$class = (string) $node->class;
$lowercasedClass = strtolower($class);
if (in_array($lowercasedClass, ['self', 'static'], true)) {
if (!$scope->isInClass()) {
return [
sprintf(
'Accessing %s::$%s outside of class scope.',
$class,
$name
),
];
}
$className = $scope->getClassReflection()->getName();
} elseif ($lowercasedClass === 'parent') {
if (!$scope->isInClass()) {
return [
sprintf(
'Accessing %s::$%s outside of class scope.',
$class,
$name
),
];
}
if ($scope->getClassReflection()->getParentClass() === false) {
return [
sprintf(
'%s::%s() accesses parent::$%s but %s does not extend any class.',
$scope->getClassReflection()->getDisplayName(),
$scope->getFunctionName(),
$name,
$scope->getClassReflection()->getDisplayName()
),
];
}
if ($scope->getFunctionName() === null) {
throw new \PHPStan\ShouldNotHappenException();
}
$currentMethodReflection = $scope->getClassReflection()->getNativeMethod($scope->getFunctionName());
if (!$currentMethodReflection->isStatic()) {
// calling parent::method() from instance method
return [];
}
$className = $scope->getClassReflection()->getParentClass()->getName();
} else {
if (!$this->broker->hasClass($class)) {
return [
sprintf(
'Access to static property $%s on an unknown class %s.',
$name,
$class
),
];
} else {
$messages = $this->classCaseSensitivityCheck->checkClassNames([$class]);
}
$className = $this->broker->getClass($class)->getName();
}
$classType = new ObjectType($className);
} else {
$classTypeResult = $this->ruleLevelHelper->findTypeToCheck(
$scope,
$node->class,
sprintf('Access to static property $%s on an unknown class %%s.', $name),
static function (Type $type) use ($name): bool {
return $type->canAccessProperties()->yes() && $type->hasProperty($name);
}
);
$classType = $classTypeResult->getType();
if ($classType instanceof ErrorType) {
return $classTypeResult->getUnknownClassErrors();
}
}
if ((new StringType())->isSuperTypeOf($classType)->yes()) {
return [];
}
$typeForDescribe = $classType;
$classType = TypeCombinator::remove($classType, new StringType());
if (!$classType->canAccessProperties()->yes()) {
return array_merge($messages, [
sprintf('Cannot access static property $%s on %s.', $name, $typeForDescribe->describe(VerbosityLevel::typeOnly())),
]);
}
if (!$classType->hasProperty($name)) {
if ($scope->isSpecified($node)) {
return $messages;
}
return array_merge($messages, [
sprintf(
'Access to an undefined static property %s::$%s.',
$typeForDescribe->describe(VerbosityLevel::typeOnly()),
$name
),
]);
}
$property = $classType->getProperty($name, $scope);
if (!$property->isStatic()) {
$hasPropertyTypes = TypeUtils::getHasPropertyTypes($classType);
foreach ($hasPropertyTypes as $hasPropertyType) {
if ($hasPropertyType->getPropertyName() === $name) {
return [];
}
}
return array_merge($messages, [
sprintf(
'Static access to instance property %s::$%s.',
$property->getDeclaringClass()->getDisplayName(),
$name
),
]);
}
if (!$scope->canAccessProperty($property)) {
return array_merge($messages, [
sprintf(
'Access to %s property $%s of class %s.',
$property->isPrivate() ? 'private' : 'protected',
$name,
$property->getDeclaringClass()->getDisplayName()
),
]);
}
return $messages;
}
}
src/Rules/Properties/WritingToReadOnlyPropertiesRule.php 0000666 00000004323 13436755504 0017605 0 ustar 00 ruleLevelHelper = $ruleLevelHelper;
$this->propertyDescriptor = $propertyDescriptor;
$this->propertyReflectionFinder = $propertyReflectionFinder;
$this->checkThisOnly = $checkThisOnly;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr::class;
}
/**
* @param \PhpParser\Node\Expr $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (
!$node instanceof Node\Expr\Assign
&& !$node instanceof Node\Expr\AssignOp
) {
return [];
}
if (
!($node->var instanceof Node\Expr\PropertyFetch)
&& !($node->var instanceof Node\Expr\StaticPropertyFetch)
) {
return [];
}
if (
$node->var instanceof Node\Expr\PropertyFetch
&& $this->checkThisOnly
&& !$this->ruleLevelHelper->isThis($node->var->var)
) {
return [];
}
/** @var \PhpParser\Node\Expr\PropertyFetch|\PhpParser\Node\Expr\StaticPropertyFetch $propertyFetch */
$propertyFetch = $node->var;
$propertyReflection = $this->propertyReflectionFinder->findPropertyReflectionFromNode($propertyFetch, $scope);
if ($propertyReflection === null) {
return [];
}
if (!$scope->canAccessProperty($propertyReflection)) {
return [];
}
if (!$propertyReflection->isWritable()) {
$propertyDescription = $this->propertyDescriptor->describeProperty($propertyReflection, $propertyFetch);
return [
sprintf(
'%s is not writable.',
$propertyDescription
),
];
}
return [];
}
}
src/Rules/Properties/TypesAssignedToPropertiesRule.php 0000666 00000004454 13436755504 0017313 0 ustar 00 ruleLevelHelper = $ruleLevelHelper;
$this->propertyDescriptor = $propertyDescriptor;
$this->propertyReflectionFinder = $propertyReflectionFinder;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr::class;
}
/**
* @param \PhpParser\Node\Expr $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (
!$node instanceof Node\Expr\Assign
&& !$node instanceof Node\Expr\AssignOp
) {
return [];
}
if (
!($node->var instanceof Node\Expr\PropertyFetch)
&& !($node->var instanceof Node\Expr\StaticPropertyFetch)
) {
return [];
}
/** @var \PhpParser\Node\Expr\PropertyFetch|\PhpParser\Node\Expr\StaticPropertyFetch $propertyFetch */
$propertyFetch = $node->var;
$propertyReflection = $this->propertyReflectionFinder->findPropertyReflectionFromNode($propertyFetch, $scope);
if ($propertyReflection === null) {
return [];
}
$propertyType = $propertyReflection->getType();
if ($node instanceof Node\Expr\Assign) {
$assignedValueType = $scope->getType($node->expr);
} else {
$assignedValueType = $scope->getType($node);
}
if (!$this->ruleLevelHelper->accepts($propertyType, $assignedValueType, $scope->isDeclareStrictTypes())) {
$propertyDescription = $this->propertyDescriptor->describeProperty($propertyReflection, $propertyFetch);
return [
sprintf(
'%s (%s) does not accept %s.',
$propertyDescription,
$propertyType->describe(VerbosityLevel::typeOnly()),
$assignedValueType->describe(VerbosityLevel::typeOnly())
),
];
}
return [];
}
}
src/Rules/Properties/PropertyDescriptor.php 0000666 00000001433 13436755504 0015176 0 ustar 00 name;
if ($propertyFetch instanceof \PhpParser\Node\Expr\PropertyFetch) {
return sprintf('Property %s::$%s', $property->getDeclaringClass()->getDisplayName(), $name->name);
}
return sprintf('Static property %s::$%s', $property->getDeclaringClass()->getDisplayName(), $name->name);
}
}
src/Rules/Properties/DefaultValueTypesAssignedToPropertiesRule.php 0000666 00000003430 13436755504 0021606 0 ustar 00 ruleLevelHelper = $ruleLevelHelper;
}
public function getNodeType(): string
{
return Property::class;
}
/**
* @param \PhpParser\Node\Stmt\Property $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (!$scope->isInClass()) {
throw new \PHPStan\ShouldNotHappenException();
}
$classReflection = $scope->getClassReflection();
$errors = [];
foreach ($node->props as $property) {
if ($property->default === null) {
continue;
}
if ($property->default instanceof Node\Expr\ConstFetch && (string) $property->default->name === 'null') {
continue;
}
$propertyReflection = $classReflection->getNativeProperty($property->name->name);
$propertyType = $propertyReflection->getType();
$defaultValueType = $scope->getType($property->default);
if ($this->ruleLevelHelper->accepts($propertyType, $defaultValueType, $scope->isDeclareStrictTypes())) {
continue;
}
$errors[] = sprintf(
'%s %s::$%s (%s) does not accept default value of type %s.',
$node->isStatic() ? 'Static property' : 'Property',
$classReflection->getDisplayName(),
$property->name->name,
$propertyType->describe(VerbosityLevel::typeOnly()),
$defaultValueType->describe(VerbosityLevel::typeOnly())
);
}
return $errors;
}
}
src/Rules/Properties/AccessPropertiesRule.php 0000666 00000006465 13436755504 0015433 0 ustar 00 broker = $broker;
$this->ruleLevelHelper = $ruleLevelHelper;
$this->reportMagicProperties = $reportMagicProperties;
}
public function getNodeType(): string
{
return PropertyFetch::class;
}
/**
* @param \PhpParser\Node\Expr\PropertyFetch $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(\PhpParser\Node $node, Scope $scope): array
{
if (!$node->name instanceof \PhpParser\Node\Identifier) {
return [];
}
$name = $node->name->name;
$typeResult = $this->ruleLevelHelper->findTypeToCheck(
$scope,
$node->var,
sprintf('Access to property $%s on an unknown class %%s.', $name),
static function (Type $type) use ($name): bool {
return $type->canAccessProperties()->yes() && $type->hasProperty($name);
}
);
$type = $typeResult->getType();
if ($type instanceof ErrorType) {
return $typeResult->getUnknownClassErrors();
}
if (!$type->canAccessProperties()->yes()) {
return [
sprintf('Cannot access property $%s on %s.', $name, $type->describe(VerbosityLevel::typeOnly())),
];
}
if (!$type->hasProperty($name)) {
if ($scope->isSpecified($node)) {
return [];
}
$classNames = $typeResult->getReferencedClasses();
if (!$this->reportMagicProperties) {
foreach ($classNames as $className) {
if (!$this->broker->hasClass($className)) {
continue;
}
$classReflection = $this->broker->getClass($className);
if (
$classReflection->hasNativeMethod('__get')
|| $classReflection->hasNativeMethod('__set')
) {
return [];
}
}
}
if (count($classNames) === 1) {
$referencedClass = $typeResult->getReferencedClasses()[0];
$propertyClassReflection = $this->broker->getClass($referencedClass);
$parentClassReflection = $propertyClassReflection->getParentClass();
while ($parentClassReflection !== false) {
if ($parentClassReflection->hasProperty($name)) {
return [
sprintf(
'Access to private property $%s of parent class %s.',
$name,
$parentClassReflection->getDisplayName()
),
];
}
$parentClassReflection = $parentClassReflection->getParentClass();
}
}
return [
sprintf(
'Access to an undefined property %s::$%s.',
$type->describe(VerbosityLevel::typeOnly()),
$name
),
];
}
$propertyReflection = $type->getProperty($name, $scope);
if (!$scope->canAccessProperty($propertyReflection)) {
return [
sprintf(
'Access to %s property %s::$%s.',
$propertyReflection->isPrivate() ? 'private' : 'protected',
$type->describe(VerbosityLevel::typeOnly()),
$name
),
];
}
return [];
}
}
src/Rules/Functions/CallToNonExistentFunctionRule.php 0000666 00000002760 13436755504 0017046 0 ustar 00 broker = $broker;
$this->checkFunctionNameCase = $checkFunctionNameCase;
}
public function getNodeType(): string
{
return FuncCall::class;
}
/**
* @param \PhpParser\Node\Expr\FuncCall $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (!($node->name instanceof \PhpParser\Node\Name)) {
return [];
}
if (!$this->broker->hasFunction($node->name, $scope)) {
return [sprintf('Function %s not found.', (string) $node->name)];
}
$function = $this->broker->getFunction($node->name, $scope);
$name = (string) $node->name;
if ($this->checkFunctionNameCase) {
/** @var string $calledFunctionName */
$calledFunctionName = $this->broker->resolveFunctionName($node->name, $scope);
if (
strtolower($function->getName()) === strtolower($calledFunctionName)
&& $function->getName() !== $calledFunctionName
) {
return [sprintf('Call to function %s() with incorrect case: %s', $function->getName(), $name)];
}
}
return [];
}
}
src/Rules/Functions/ReturnTypeRule.php 0000666 00000003566 13436755504 0014111 0 ustar 00 returnTypeCheck = $returnTypeCheck;
}
public function getNodeType(): string
{
return Return_::class;
}
/**
* @param \PhpParser\Node\Stmt\Return_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if ($scope->getFunction() === null) {
return [];
}
if ($scope->isInAnonymousFunction()) {
return [];
}
$function = $scope->getFunction();
if (
!($function instanceof PhpFunctionFromParserNodeReflection)
|| $function instanceof PhpMethodFromParserNodeReflection
) {
return [];
}
$reflection = null;
if (function_exists($function->getName())) {
$reflection = new \ReflectionFunction($function->getName());
}
return $this->returnTypeCheck->checkReturnType(
$scope,
ParametersAcceptorSelector::selectSingle($function->getVariants())->getReturnType(),
$node->expr,
sprintf(
'Function %s() should return %%s but empty return statement found.',
$function->getName()
),
sprintf(
'Function %s() with return type void returns %%s but should not return anything.',
$function->getName()
),
sprintf(
'Function %s() should return %%s but returns %%s.',
$function->getName()
),
$reflection !== null && $reflection->isGenerator()
);
}
}
src/Rules/Functions/CallCallablesRule.php 0000666 00000007066 13436755504 0014445 0 ustar 00 check = $check;
$this->ruleLevelHelper = $ruleLevelHelper;
$this->reportMaybes = $reportMaybes;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr\FuncCall::class;
}
/**
* @param \PhpParser\Node\Expr\FuncCall $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(
\PhpParser\Node $node,
Scope $scope
): array
{
if (!$node->name instanceof \PhpParser\Node\Expr) {
return [];
}
$typeResult = $this->ruleLevelHelper->findTypeToCheck(
$scope,
$node->name,
'Invoking callable on an unknown class %s.',
static function (Type $type): bool {
return $type->isCallable()->yes();
}
);
$type = $typeResult->getType();
if ($type instanceof ErrorType) {
return $typeResult->getUnknownClassErrors();
}
$isCallable = $type->isCallable();
if ($isCallable->no()) {
return [
sprintf('Trying to invoke %s but it\'s not a callable.', $type->describe(VerbosityLevel::value())),
];
}
if ($this->reportMaybes && $isCallable->maybe()) {
return [
sprintf('Trying to invoke %s but it might not be a callable.', $type->describe(VerbosityLevel::value())),
];
}
$parametersAcceptors = $type->getCallableParametersAcceptors($scope);
$messages = [];
if (
count($parametersAcceptors) === 1
&& $parametersAcceptors[0] instanceof InaccessibleMethod
) {
$method = $parametersAcceptors[0]->getMethod();
$messages[] = sprintf(
'Call to %s method %s() of class %s.',
$method->isPrivate() ? 'private' : 'protected',
$method->getName(),
$method->getDeclaringClass()->getDisplayName()
);
}
$parametersAcceptor = ParametersAcceptorSelector::selectFromArgs(
$scope,
$node->args,
$parametersAcceptors
);
if ($type instanceof ClosureType) {
$callableDescription = 'closure';
} else {
$callableDescription = sprintf('callable %s', $type->describe(VerbosityLevel::value()));
}
return array_merge(
$messages,
$this->check->check(
$parametersAcceptor,
$scope,
$node,
[
ucfirst($callableDescription) . ' invoked with %d parameter, %d required.',
ucfirst($callableDescription) . ' invoked with %d parameters, %d required.',
ucfirst($callableDescription) . ' invoked with %d parameter, at least %d required.',
ucfirst($callableDescription) . ' invoked with %d parameters, at least %d required.',
ucfirst($callableDescription) . ' invoked with %d parameter, %d-%d required.',
ucfirst($callableDescription) . ' invoked with %d parameters, %d-%d required.',
'Parameter #%d %s of ' . $callableDescription . ' expects %s, %s given.',
'Result of ' . $callableDescription . ' (void) is used.',
'Parameter #%d %s of ' . $callableDescription . ' is passed by reference, so it expects variables only.',
]
)
);
}
}
src/Rules/Functions/CallToFunctionParametersRule.php 0000666 00000004046 13436755504 0016672 0 ustar 00 broker = $broker;
$this->check = $check;
}
public function getNodeType(): string
{
return FuncCall::class;
}
/**
* @param \PhpParser\Node\Expr\FuncCall $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (!($node->name instanceof \PhpParser\Node\Name)) {
return [];
}
if (!$this->broker->hasFunction($node->name, $scope)) {
return [];
}
$function = $this->broker->getFunction($node->name, $scope);
return $this->check->check(
ParametersAcceptorSelector::selectFromArgs(
$scope,
$node->args,
$function->getVariants()
),
$scope,
$node,
[
'Function ' . $function->getName() . ' invoked with %d parameter, %d required.',
'Function ' . $function->getName() . ' invoked with %d parameters, %d required.',
'Function ' . $function->getName() . ' invoked with %d parameter, at least %d required.',
'Function ' . $function->getName() . ' invoked with %d parameters, at least %d required.',
'Function ' . $function->getName() . ' invoked with %d parameter, %d-%d required.',
'Function ' . $function->getName() . ' invoked with %d parameters, %d-%d required.',
'Parameter #%d %s of function ' . $function->getName() . ' expects %s, %s given.',
'Result of function ' . $function->getName() . ' (void) is used.',
'Parameter #%d %s of function ' . $function->getName() . ' is passed by reference, so it expects variables only.',
]
);
}
}
src/Rules/Functions/ClosureReturnTypeRule.php 0000666 00000002500 13436755504 0015431 0 ustar 00 returnTypeCheck = $returnTypeCheck;
}
public function getNodeType(): string
{
return Return_::class;
}
/**
* @param \PhpParser\Node\Stmt\Return_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (!$scope->isInAnonymousFunction()) {
return [];
}
/** @var \PHPStan\Type\Type $returnType */
$returnType = $scope->getAnonymousFunctionReturnType();
$generatorType = new ObjectType(\Generator::class);
return $this->returnTypeCheck->checkReturnType(
$scope,
$returnType,
$node->expr,
'Anonymous function should return %s but empty return statement found.',
'Anonymous function with return type void returns %s but should not return anything.',
'Anonymous function should return %s but returns %s.',
$generatorType->isSuperTypeOf($returnType)->yes()
);
}
}
src/Rules/Functions/PrintfParametersRule.php 0000666 00000005643 13436755504 0015254 0 ustar 00 name instanceof \PhpParser\Node\Name)) {
return [];
}
$functionsArgumentPositions = [
'printf' => 0,
'sprintf' => 0,
'sscanf' => 1,
'fscanf' => 1,
];
$minimumNumberOfArguments = [
'printf' => 1,
'sprintf' => 1,
'sscanf' => 3,
'fscanf' => 3,
];
$name = strtolower((string) $node->name);
if (!isset($functionsArgumentPositions[$name])) {
return [];
}
$formatArgumentPosition = $functionsArgumentPositions[$name];
$args = $node->args;
$argsCount = count($args);
if ($argsCount < $minimumNumberOfArguments[$name]) {
return []; // caught by CallToFunctionParametersRule
}
$formatArgType = $scope->getType($args[$formatArgumentPosition]->value);
if (!($formatArgType instanceof ConstantStringType)) {
return []; // inspect only literal string format
}
foreach ($node->args as $arg) {
if ($arg->unpack) {
return [];
}
}
$format = $formatArgType->getValue();
$placeHoldersCount = $this->getPlaceholdersCount($name, $format);
$argsCount -= $formatArgumentPosition;
if ($argsCount !== $placeHoldersCount + 1) {
return [
sprintf(
sprintf(
'%s, %s.',
$placeHoldersCount === 1 ? 'Call to %s contains %d placeholder' : 'Call to %s contains %d placeholders',
$argsCount - 1 === 1 ? '%d value given' : '%d values given'
),
$name,
$placeHoldersCount,
$argsCount - 1
),
];
}
return [];
}
private function getPlaceholdersCount(string $functionName, string $format): int
{
$specifiers = in_array($functionName, ['sprintf', 'printf'], true) ? '[bcdeEfFgGosuxX]' : '(?:[cdDeEfinosuxX]|\[[^\]]+\])';
$pattern = '~(?%*)%(?:(?\d+)\$)?[-+]?(?:[ 0]|(?:\'[^%]))?-?\d*(?:\.\d*)?' . $specifiers . '~';
$matches = \Nette\Utils\Strings::matchAll($format, $pattern, PREG_SET_ORDER);
if (count($matches) === 0) {
return 0;
}
$placeholders = array_filter($matches, static function (array $match): bool {
return strlen($match['before']) % 2 === 0;
});
if (count($placeholders) === 0) {
return 0;
}
$maxPositionedNumber = 0;
$maxOrdinaryNumber = 0;
foreach ($placeholders as $placeholder) {
if (isset($placeholder['position']) && $placeholder['position'] !== '') {
$maxPositionedNumber = max((int) $placeholder['position'], $maxPositionedNumber);
} else {
$maxOrdinaryNumber++;
}
}
return max($maxPositionedNumber, $maxOrdinaryNumber);
}
}
src/Rules/Functions/InnerFunctionRule.php 0000666 00000001421 13436755504 0014535 0 ustar 00 getFunction() === null) {
return [];
}
return [
'Inner named functions are not supported by PHPStan. Consider refactoring to an anonymous function, class method, or a top-level-defined function. See issue #165 (https://github.com/phpstan/phpstan/issues/165) for more details.',
];
}
}
src/Rules/Functions/ExistingClassesInTypehintsRule.php 0000666 00000001745 13436755504 0017274 0 ustar 00 check = $check;
}
public function getNodeType(): string
{
return Function_::class;
}
/**
* @param \PhpParser\Node\Stmt\Function_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
return $this->check->checkFunction(
$node,
$scope,
sprintf(
'Parameter $%%s of function %s() has invalid typehint type %%s.',
(string) $node->namespacedName
),
sprintf(
'Return typehint of function %s() has invalid type %%s.',
(string) $node->namespacedName
)
);
}
}
src/Rules/Functions/UnusedClosureUsesRule.php 0000666 00000002051 13436755504 0015414 0 ustar 00 check = $check;
}
public function getNodeType(): string
{
return Node\Expr\Closure::class;
}
/**
* @param \PhpParser\Node\Expr\Closure $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (count($node->uses) === 0) {
return [];
}
return $this->check->getUnusedParameters(
$scope,
array_map(static function (Node\Expr\ClosureUse $use): string {
if (!is_string($use->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
return $use->var->name;
}, $node->uses),
$node->stmts,
'Anonymous function has an unused use $%s.'
);
}
}
src/Rules/Functions/NonExistentDefinedFunctionRule.php 0000666 00000002104 13436755504 0017216 0 ustar 00 broker = $broker;
}
public function getNodeType(): string
{
return Function_::class;
}
/**
* @param \PhpParser\Node\Stmt\Function_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
$functionName = $node->name->name;
if (isset($node->namespacedName)) {
$functionName = (string) $node->namespacedName;
}
$functionNameName = new Name($functionName);
if ($this->broker->hasFunction($functionNameName, null)) {
return [];
}
return [
sprintf(
'Function %s not found while trying to analyse it - autoloading is probably not configured properly.',
$functionName
),
];
}
}
src/Rules/Functions/ExistingClassesInClosureTypehintsRule.php 0000666 00000001601 13436755504 0020620 0 ustar 00 check = $check;
}
public function getNodeType(): string
{
return Closure::class;
}
/**
* @param \PhpParser\Node\Expr\Closure $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
return $this->check->checkFunction(
$node,
$scope,
'Parameter $%s of anonymous function has invalid typehint type %s.',
'Return typehint of anonymous function has invalid type %s.'
);
}
}
src/Rules/Constants/ConstantRule.php 0000666 00000001135 13436755504 0013553 0 ustar 00 hasConstant($node->name)) {
return [
sprintf(
'Constant %s not found.',
(string) $node->name
),
];
}
return [];
}
}
src/Rules/RegistryFactory.php 0000666 00000001137 13436755504 0012320 0 ustar 00 container = $container;
}
public function create(): Registry
{
$tagToService = function (array $tags) {
return array_map(function (string $serviceName) {
return $this->container->getService($serviceName);
}, array_keys($tags));
};
return new Registry(
$tagToService($this->container->findByTag(self::RULE_TAG))
);
}
}
src/Rules/FoundTypeResult.php 0000666 00000001637 13436755504 0012301 0 ustar 00 type = $type;
$this->referencedClasses = $referencedClasses;
$this->unknownClassErrors = $unknownClassErrors;
}
public function getType(): Type
{
return $this->type;
}
/**
* @return string[]
*/
public function getReferencedClasses(): array
{
return $this->referencedClasses;
}
/**
* @return string[]
*/
public function getUnknownClassErrors(): array
{
return $this->unknownClassErrors;
}
}
src/Rules/Registry.php 0000666 00000001566 13436755504 0010776 0 ustar 00 rules[$rule->getNodeType()][] = $rule;
}
}
/**
* @param string $nodeType
* @return \PHPStan\Rules\Rule[]
*/
public function getRules(string $nodeType): array
{
if (!isset($this->cache[$nodeType])) {
$parentNodeTypes = [$nodeType] + class_parents($nodeType) + class_implements($nodeType);
$rules = [];
foreach ($parentNodeTypes as $parentNodeType) {
foreach ($this->rules[$parentNodeType] ?? [] as $rule) {
$rules[] = $rule;
}
}
$this->cache[$nodeType] = $rules;
}
return $this->cache[$nodeType];
}
}
src/Rules/Variables/DefinedVariableRule.php 0000666 00000003043 13436755504 0014722 0 ustar 00 cliArgumentsVariablesRegistered = $cliArgumentsVariablesRegistered;
$this->checkMaybeUndefinedVariables = $checkMaybeUndefinedVariables;
}
public function getNodeType(): string
{
return Variable::class;
}
/**
* @param \PhpParser\Node\Expr\Variable $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (!is_string($node->name)) {
return [];
}
if ($this->cliArgumentsVariablesRegistered && in_array($node->name, [
'argc',
'argv',
], true)) {
$isInMain = !$scope->isInClass() && !$scope->isInAnonymousFunction() && $scope->getFunction() === null;
if ($isInMain) {
return [];
}
}
if ($scope->isInExpressionAssign($node)) {
return [];
}
if ($scope->hasVariableType($node->name)->no()) {
return [
sprintf('Undefined variable: $%s', $node->name),
];
} elseif (
$this->checkMaybeUndefinedVariables
&& !$scope->hasVariableType($node->name)->yes()
) {
return [
sprintf('Variable $%s might not be defined.', $node->name),
];
}
return [];
}
}
src/Rules/Variables/ThrowTypeRule.php 0000666 00000002655 13436755504 0013673 0 ustar 00 ruleLevelHelper = $ruleLevelHelper;
}
public function getNodeType(): string
{
return \PhpParser\Node\Stmt\Throw_::class;
}
/**
* @param \PhpParser\Node\Stmt\Throw_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
$throwableType = new ObjectType(\Throwable::class);
$typeResult = $this->ruleLevelHelper->findTypeToCheck(
$scope,
$node->expr,
'Throwing object of an unknown class %s.',
static function (Type $type) use ($throwableType): bool {
return $throwableType->isSuperTypeOf($type)->yes();
}
);
$foundType = $typeResult->getType();
if ($foundType instanceof ErrorType) {
return $typeResult->getUnknownClassErrors();
}
$isSuperType = $throwableType->isSuperTypeOf($foundType);
if ($isSuperType->yes()) {
return [];
}
return [
sprintf('Invalid type %s to throw.', $foundType->describe(VerbosityLevel::typeOnly())),
];
}
}
src/Rules/Variables/ThisVariableRule.php 0000666 00000002100 13436755504 0014264 0 ustar 00 name) || $node->name !== 'this') {
return [];
}
if ($scope->isInClosureBind()) {
return [];
}
if (!$scope->isInClass()) {
return [
'Using $this outside a class.',
];
}
$function = $scope->getFunction();
if (!$function instanceof MethodReflection) {
throw new \PHPStan\ShouldNotHappenException();
}
if ($function->isStatic()) {
return [
sprintf(
'Using $this in static method %s::%s().',
$scope->getClassReflection()->getDisplayName(),
$function->getName()
),
];
}
return [];
}
}
src/Rules/Variables/DefinedVariableInAnonymousFunctionUseRule.php 0000666 00000002160 13436755504 0021304 0 ustar 00 checkMaybeUndefinedVariables = $checkMaybeUndefinedVariables;
}
public function getNodeType(): string
{
return ClosureUse::class;
}
/**
* @param \PhpParser\Node\Expr\ClosureUse $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if ($node->byRef || !is_string($node->var->name)) {
return [];
}
if ($scope->hasVariableType($node->var->name)->no()) {
return [
sprintf('Undefined variable: $%s', $node->var->name),
];
} elseif (
$this->checkMaybeUndefinedVariables
&& !$scope->hasVariableType($node->var->name)->yes()
) {
return [
sprintf('Variable $%s might not be defined.', $node->var->name),
];
}
return [];
}
}
src/Rules/Variables/VariableCloningRule.php 0000666 00000003012 13436755504 0014751 0 ustar 00 ruleLevelHelper = $ruleLevelHelper;
}
public function getNodeType(): string
{
return Clone_::class;
}
/**
* @param \PhpParser\Node\Expr\Clone_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
$typeResult = $this->ruleLevelHelper->findTypeToCheck(
$scope,
$node->expr,
'Cloning object of an unknown class %s.',
static function (Type $type): bool {
return $type->isCloneable()->yes();
}
);
$type = $typeResult->getType();
if ($type instanceof ErrorType) {
return $typeResult->getUnknownClassErrors();
}
if ($type->isCloneable()->yes()) {
return [];
}
if ($node->expr instanceof Variable && is_string($node->expr->name)) {
return [
sprintf(
'Cannot clone non-object variable $%s of type %s.',
$node->expr->name,
$type->describe(VerbosityLevel::typeOnly())
),
];
}
return [
sprintf('Cannot clone %s.', $type->describe(VerbosityLevel::typeOnly())),
];
}
}
src/Rules/Variables/VariableCertaintyInIssetRule.php 0000666 00000003066 13436755504 0016632 0 ustar 00 vars as $var) {
$isSubNode = false;
while (
$var instanceof Node\Expr\ArrayDimFetch
|| $var instanceof Node\Expr\PropertyFetch
|| (
$var instanceof Node\Expr\StaticPropertyFetch
&& $var->class instanceof Node\Expr
)
) {
if ($var instanceof Node\Expr\StaticPropertyFetch) {
$var = $var->class;
} else {
$var = $var->var;
}
$isSubNode = true;
}
if (!$var instanceof Node\Expr\Variable || !is_string($var->name)) {
continue;
}
$certainty = $scope->hasVariableType($var->name);
if ($certainty->no()) {
if (
$scope->getFunction() !== null
|| $scope->isInAnonymousFunction()
) {
$messages[] = sprintf('Variable $%s in isset() is never defined.', $var->name);
}
} elseif ($certainty->yes() && !$isSubNode) {
$variableType = $scope->getVariableType($var->name);
if ($variableType->isSuperTypeOf(new NullType())->no()) {
$messages[] = sprintf('Variable $%s in isset() always exists and is not nullable.', $var->name);
}
}
}
return $messages;
}
}
src/Rules/PhpDoc/InvalidThrowsPhpDocValueRule.php 0000666 00000002751 13436755504 0016060 0 ustar 00 fileTypeMapper = $fileTypeMapper;
}
public function getNodeType(): string
{
return \PhpParser\Node\FunctionLike::class;
}
/**
* @param \PhpParser\Node\FunctionLike $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
$docComment = $node->getDocComment();
if ($docComment === null) {
return [];
}
$resolvedPhpDoc = $this->fileTypeMapper->getResolvedPhpDoc(
$scope->getFile(),
$scope->isInClass() ? $scope->getClassReflection()->getName() : null,
$scope->isInTrait() ? $scope->getTraitReflection()->getName() : null,
$docComment->getText()
);
if ($resolvedPhpDoc->getThrowsTag() === null) {
return [];
}
$phpDocThrowsType = $resolvedPhpDoc->getThrowsTag()->getType();
$isThrowsSuperType = (new ObjectType(\Throwable::class))->isSuperTypeOf($phpDocThrowsType);
if ($isThrowsSuperType->yes()) {
return [];
}
return [sprintf(
'PHPDoc tag @throws with type %s is not subtype of Throwable',
$phpDocThrowsType->describe(VerbosityLevel::typeOnly())
)];
}
}
src/Rules/PhpDoc/IncompatiblePhpDocTypeRule.php 0000666 00000010626 13436755504 0015536 0 ustar 00 fileTypeMapper = $fileTypeMapper;
}
public function getNodeType(): string
{
return \PhpParser\Node\FunctionLike::class;
}
/**
* @param \PhpParser\Node\FunctionLike $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
$docComment = $node->getDocComment();
if ($docComment === null) {
return [];
}
$resolvedPhpDoc = $this->fileTypeMapper->getResolvedPhpDoc(
$scope->getFile(),
$scope->isInClass() ? $scope->getClassReflection()->getName() : null,
$scope->isInTrait() ? $scope->getTraitReflection()->getName() : null,
$docComment->getText()
);
$nativeParameterTypes = $this->getNativeParameterTypes($node, $scope);
$nativeReturnType = $this->getNativeReturnType($node, $scope);
$errors = [];
foreach ($resolvedPhpDoc->getParamTags() as $parameterName => $phpDocParamTag) {
$phpDocParamType = $phpDocParamTag->getType();
if (!isset($nativeParameterTypes[$parameterName])) {
$errors[] = sprintf(
'PHPDoc tag @param references unknown parameter $%s',
$parameterName
);
} elseif ($phpDocParamType instanceof ErrorType) {
$errors[] = sprintf(
'PHPDoc tag @param for parameter $%s contains unresolvable type',
$parameterName
);
} else {
$nativeParamType = $nativeParameterTypes[$parameterName];
$isParamSuperType = $nativeParamType->isSuperTypeOf($phpDocParamType);
if (
$phpDocParamTag->isVariadic()
&& $nativeParamType instanceof ArrayType
&& $nativeParamType->getItemType() instanceof ArrayType
) {
continue;
}
if ($isParamSuperType->no()) {
$errors[] = sprintf(
'PHPDoc tag @param for parameter $%s with type %s is incompatible with native type %s',
$parameterName,
$phpDocParamType->describe(VerbosityLevel::typeOnly()),
$nativeParamType->describe(VerbosityLevel::typeOnly())
);
} elseif ($isParamSuperType->maybe()) {
$errors[] = sprintf(
'PHPDoc tag @param for parameter $%s with type %s is not subtype of native type %s',
$parameterName,
$phpDocParamType->describe(VerbosityLevel::typeOnly()),
$nativeParamType->describe(VerbosityLevel::typeOnly())
);
}
}
}
if ($resolvedPhpDoc->getReturnTag() !== null) {
$phpDocReturnType = $resolvedPhpDoc->getReturnTag()->getType();
if ($phpDocReturnType instanceof ErrorType) {
$errors[] = 'PHPDoc tag @return contains unresolvable type';
} else {
$isReturnSuperType = $nativeReturnType->isSuperTypeOf($phpDocReturnType);
if ($isReturnSuperType->no()) {
$errors[] = sprintf(
'PHPDoc tag @return with type %s is incompatible with native type %s',
$phpDocReturnType->describe(VerbosityLevel::typeOnly()),
$nativeReturnType->describe(VerbosityLevel::typeOnly())
);
} elseif ($isReturnSuperType->maybe()) {
$errors[] = sprintf(
'PHPDoc tag @return with type %s is not subtype of native type %s',
$phpDocReturnType->describe(VerbosityLevel::typeOnly()),
$nativeReturnType->describe(VerbosityLevel::typeOnly())
);
}
}
}
return $errors;
}
/**
* @param Node\FunctionLike $node
* @param Scope $scope
* @return Type[]
*/
private function getNativeParameterTypes(\PhpParser\Node\FunctionLike $node, Scope $scope): array
{
$nativeParameterTypes = [];
foreach ($node->getParams() as $parameter) {
$isNullable = $scope->isParameterValueNullable($parameter);
if (!$parameter->var instanceof Variable || !is_string($parameter->var->name)) {
throw new \PHPStan\ShouldNotHappenException();
}
$nativeParameterTypes[$parameter->var->name] = $scope->getFunctionType(
$parameter->type,
$isNullable,
$parameter->variadic
);
}
return $nativeParameterTypes;
}
private function getNativeReturnType(\PhpParser\Node\FunctionLike $node, Scope $scope): Type
{
return $scope->getFunctionType($node->getReturnType(), false, false);
}
}
src/Rules/PhpDoc/InvalidPhpDocTagValueRule.php 0000666 00000003360 13436755504 0015302 0 ustar 00 phpDocLexer = $phpDocLexer;
$this->phpDocParser = $phpDocParser;
}
public function getNodeType(): string
{
return \PhpParser\Node::class;
}
/**
* @param \PhpParser\Node $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if (
!$node instanceof Node\Stmt\ClassLike
&& !$node instanceof Node\FunctionLike
&& !$node instanceof Node\Stmt\Foreach_
&& !$node instanceof Node\Stmt\Property
&& !$node instanceof Node\Expr\Assign
&& !$node instanceof Node\Expr\AssignRef
) {
return [];
}
$docComment = $node->getDocComment();
if ($docComment === null) {
return [];
}
$phpDocString = $docComment->getText();
$tokens = new TokenIterator($this->phpDocLexer->tokenize($phpDocString));
$phpDocNode = $this->phpDocParser->parse($tokens);
$errors = [];
foreach ($phpDocNode->getTags() as $phpDocTag) {
if (!($phpDocTag->value instanceof InvalidTagValueNode)) {
continue;
}
$errors[] = sprintf(
'PHPDoc tag %s has invalid value (%s): %s',
$phpDocTag->name,
$phpDocTag->value->value,
$phpDocTag->value->exception->getMessage()
);
}
return $errors;
}
}
src/Rules/Namespaces/ExistingNamesInGroupUseRule.php 0000666 00000005503 13436755504 0016627 0 ustar 00 broker = $broker;
$this->classCaseSensitivityCheck = $classCaseSensitivityCheck;
$this->checkFunctionNameCase = $checkFunctionNameCase;
}
public function getNodeType(): string
{
return \PhpParser\Node\Stmt\GroupUse::class;
}
/**
* @param \PhpParser\Node\Stmt\GroupUse $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
$messages = [];
foreach ($node->uses as $use) {
$message = null;
/** @var Node\Name $name */
$name = Node\Name::concat($node->prefix, $use->name);
if (
$node->type === Use_::TYPE_CONSTANT
|| $use->type === Use_::TYPE_CONSTANT
) {
$message = $this->checkConstant($name);
} elseif (
$node->type === Use_::TYPE_FUNCTION
|| $use->type === Use_::TYPE_FUNCTION
) {
$message = $this->checkFunction($name);
} elseif ($use->type === Use_::TYPE_NORMAL) {
$message = $this->checkClass($name);
} else {
throw new \PHPStan\ShouldNotHappenException();
}
if ($message === null) {
continue;
}
$messages[] = $message;
}
return $messages;
}
private function checkConstant(Node\Name $name): ?string
{
if (!$this->broker->hasConstant($name, null)) {
return sprintf('Used constant %s not found.', (string) $name);
}
return null;
}
private function checkFunction(Node\Name $name): ?string
{
if (!$this->broker->hasFunction($name, null)) {
return sprintf('Used function %s not found.', (string) $name);
}
if ($this->checkFunctionNameCase) {
$functionReflection = $this->broker->getFunction($name, null);
$realName = $functionReflection->getName();
$usedName = (string) $name;
if (
strtolower($realName) === strtolower($usedName)
&& $realName !== $usedName
) {
return sprintf(
'Function %s used with incorrect case: %s.',
$realName,
$usedName
);
}
}
return null;
}
private function checkClass(Node\Name $name): ?string
{
$messages = $this->classCaseSensitivityCheck->checkClassNames([(string) $name]);
if (count($messages) === 0) {
return null;
} elseif (count($messages) === 1) {
return $messages[0];
}
throw new \PHPStan\ShouldNotHappenException();
}
}
src/Rules/Namespaces/ExistingNamesInUseRule.php 0000666 00000005665 13436755504 0015623 0 ustar 00 broker = $broker;
$this->classCaseSensitivityCheck = $classCaseSensitivityCheck;
$this->checkFunctionNameCase = $checkFunctionNameCase;
}
public function getNodeType(): string
{
return \PhpParser\Node\Stmt\Use_::class;
}
/**
* @param \PhpParser\Node\Stmt\Use_ $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(Node $node, Scope $scope): array
{
if ($node->type === Node\Stmt\Use_::TYPE_UNKNOWN) {
throw new \PHPStan\ShouldNotHappenException();
}
foreach ($node->uses as $use) {
if ($use->type !== Node\Stmt\Use_::TYPE_UNKNOWN) {
throw new \PHPStan\ShouldNotHappenException();
}
}
if ($node->type === Node\Stmt\Use_::TYPE_CONSTANT) {
return $this->checkConstants($node->uses);
}
if ($node->type === Node\Stmt\Use_::TYPE_FUNCTION) {
return $this->checkFunctions($node->uses);
}
return $this->checkClasses($node->uses);
}
/**
* @param \PhpParser\Node\Stmt\UseUse[] $uses
* @return string[]
*/
private function checkConstants(array $uses): array
{
$messages = [];
foreach ($uses as $use) {
if ($this->broker->hasConstant($use->name, null)) {
continue;
}
$messages[] = sprintf('Used constant %s not found.', (string) $use->name);
}
return $messages;
}
/**
* @param \PhpParser\Node\Stmt\UseUse[] $uses
* @return string[]
*/
private function checkFunctions(array $uses): array
{
$messages = [];
foreach ($uses as $use) {
if (!$this->broker->hasFunction($use->name, null)) {
$messages[] = sprintf('Used function %s not found.', (string) $use->name);
} elseif ($this->checkFunctionNameCase) {
$functionReflection = $this->broker->getFunction($use->name, null);
$realName = $functionReflection->getName();
$usedName = (string) $use->name;
if (
strtolower($realName) === strtolower($usedName)
&& $realName !== $usedName
) {
$messages[] = sprintf(
'Function %s used with incorrect case: %s.',
$realName,
$usedName
);
}
}
}
return $messages;
}
/**
* @param \PhpParser\Node\Stmt\UseUse[] $uses
* @return string[]
*/
private function checkClasses(array $uses): array
{
return $this->classCaseSensitivityCheck->checkClassNames(
array_map(static function (\PhpParser\Node\Stmt\UseUse $use): string {
return (string) $use->name;
}, $uses)
);
}
}
src/Rules/Operators/InvalidUnaryOperationRule.php 0000666 00000001657 13436755504 0016263 0 ustar 00 getType($node) instanceof ErrorType) {
return [
sprintf(
'Unary operation "%s" on %s results in an error.',
$node instanceof \PhpParser\Node\Expr\UnaryPlus ? '+' : '-',
$scope->getType($node->expr)->describe(VerbosityLevel::value())
),
];
}
return [];
}
}
src/Rules/Operators/InvalidIncDecOperationRule.php 0000666 00000003332 13436755504 0016302 0 ustar 00 checkThisOnly = $checkThisOnly;
}
public function getNodeType(): string
{
return \PhpParser\Node\Expr::class;
}
/**
* @param \PhpParser\Node\Expr $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(\PhpParser\Node $node, \PHPStan\Analyser\Scope $scope): array
{
if (
!$node instanceof \PhpParser\Node\Expr\PreInc
&& !$node instanceof \PhpParser\Node\Expr\PostInc
&& !$node instanceof \PhpParser\Node\Expr\PreDec
&& !$node instanceof \PhpParser\Node\Expr\PostDec
) {
return [];
}
$operatorString = $node instanceof \PhpParser\Node\Expr\PreInc || $node instanceof \PhpParser\Node\Expr\PostInc ? '++' : '--';
if (
!$node->var instanceof \PhpParser\Node\Expr\Variable
&& !$node->var instanceof \PhpParser\Node\Expr\ArrayDimFetch
&& !$node->var instanceof \PhpParser\Node\Expr\PropertyFetch
&& !$node->var instanceof \PhpParser\Node\Expr\StaticPropertyFetch
) {
return [
sprintf(
'Cannot use %s on a non-variable.',
$operatorString
),
];
}
if (!$this->checkThisOnly) {
$varType = $scope->getType($node->var);
if (!$varType->toString() instanceof ErrorType) {
return [];
}
if (!$varType->toNumber() instanceof ErrorType) {
return [];
}
return [
sprintf(
'Cannot use %s on %s.',
$operatorString,
$varType->describe(VerbosityLevel::value())
),
];
}
return [];
}
}
src/Rules/Operators/InvalidBinaryOperationRule.php 0000666 00000005621 13436755504 0016404 0 ustar 00 printer = $printer;
$this->ruleLevelHelper = $ruleLevelHelper;
}
public function getNodeType(): string
{
return Node\Expr::class;
}
/**
* @param \PhpParser\Node\Expr $node
* @param \PHPStan\Analyser\Scope $scope
* @return string[]
*/
public function processNode(\PhpParser\Node $node, Scope $scope): array
{
if (
!$node instanceof Node\Expr\BinaryOp
&& !$node instanceof Node\Expr\AssignOp
) {
return [];
}
if ($scope->getType($node) instanceof ErrorType) {
$leftName = '__PHPSTAN__LEFT__';
$rightName = '__PHPSTAN__RIGHT__';
$leftVariable = new Node\Expr\Variable($leftName);
$rightVariable = new Node\Expr\Variable($rightName);
if ($node instanceof Node\Expr\AssignOp) {
$newNode = clone $node;
$left = $node->var;
$right = $node->expr;
$newNode->var = $leftVariable;
$newNode->expr = $rightVariable;
} else {
$newNode = clone $node;
$left = $node->left;
$right = $node->right;
$newNode->left = $leftVariable;
$newNode->right = $rightVariable;
}
if ($node instanceof Node\Expr\AssignOp\Concat || $node instanceof Node\Expr\BinaryOp\Concat) {
$callback = static function (Type $type): bool {
return !$type->toString() instanceof ErrorType;
};
} else {
$callback = static function (Type $type): bool {
return !$type->toNumber() instanceof ErrorType;
};
}
$leftType = $this->ruleLevelHelper->findTypeToCheck(
$scope,
$left,
'',
$callback
)->getType();
if ($leftType instanceof ErrorType) {
return [];
}
$rightType = $this->ruleLevelHelper->findTypeToCheck(
$scope,
$right,
'',
$callback
)->getType();
if ($rightType instanceof ErrorType) {
return [];
}
$scope = $scope
->assignVariable($leftName, $leftType, \PHPStan\TrinaryLogic::createYes())
->assignVariable($rightName, $rightType, \PHPStan\TrinaryLogic::createYes());
if (!$scope->getType($newNode) instanceof ErrorType) {
return [];
}
return [
sprintf(
'Binary operation "%s" between %s and %s results in an error.',
substr(substr($this->printer->prettyPrintExpr($newNode), strlen($leftName) + 2), 0, -(strlen($rightName) + 2)),
$scope->getType($left)->describe(VerbosityLevel::value()),
$scope->getType($right)->describe(VerbosityLevel::value())
),
];
}
return [];
}
}
src/PhpDoc/TypeNodeResolver.php 0000666 00000024105 13436755504 0012514 0 ustar 00 setTypeNodeResolver($this);
}
$this->extensions = $extensions;
}
public function getCacheKey(): string
{
$key = 'v50';
foreach ($this->extensions as $extension) {
$key .= sprintf('-%s', $extension->getCacheKey());
}
return $key;
}
public function resolve(TypeNode $typeNode, NameScope $nameScope): Type
{
foreach ($this->extensions as $extension) {
$type = $extension->resolve($typeNode, $nameScope);
if ($type !== null) {
return $type;
}
}
if ($typeNode instanceof IdentifierTypeNode) {
return $this->resolveIdentifierTypeNode($typeNode, $nameScope);
} elseif ($typeNode instanceof ThisTypeNode) {
return $this->resolveThisTypeNode($typeNode, $nameScope);
} elseif ($typeNode instanceof NullableTypeNode) {
return $this->resolveNullableTypeNode($typeNode, $nameScope);
} elseif ($typeNode instanceof UnionTypeNode) {
return $this->resolveUnionTypeNode($typeNode, $nameScope);
} elseif ($typeNode instanceof IntersectionTypeNode) {
return $this->resolveIntersectionTypeNode($typeNode, $nameScope);
} elseif ($typeNode instanceof ArrayTypeNode) {
return $this->resolveArrayTypeNode($typeNode, $nameScope);
} elseif ($typeNode instanceof GenericTypeNode) {
return $this->resolveGenericTypeNode($typeNode, $nameScope);
} elseif ($typeNode instanceof CallableTypeNode) {
return $this->resolveCallableTypeNode($typeNode, $nameScope);
}
return new ErrorType();
}
private function resolveIdentifierTypeNode(IdentifierTypeNode $typeNode, NameScope $nameScope): Type
{
switch (strtolower($typeNode->name)) {
case 'int':
case 'integer':
return new IntegerType();
case 'string':
return new StringType();
case 'bool':
case 'boolean':
return new BooleanType();
case 'true':
return new ConstantBooleanType(true);
case 'false':
return new ConstantBooleanType(false);
case 'null':
return new NullType();
case 'float':
case 'double':
return new FloatType();
case 'array':
return new ArrayType(new MixedType(true), new MixedType(true));
case 'scalar':
return new UnionType([
new IntegerType(),
new FloatType(),
new StringType(),
new BooleanType(),
]);
case 'number':
return new UnionType([
new IntegerType(),
new FloatType(),
]);
case 'iterable':
return new IterableType(new MixedType(true), new MixedType(true));
case 'callable':
return new CallableType();
case 'resource':
return new ResourceType();
case 'mixed':
return new MixedType(true);
case 'void':
return new VoidType();
case 'object':
return new ObjectWithoutClassType();
case 'never':
return new NeverType();
}
if ($nameScope->getClassName() !== null) {
switch (strtolower($typeNode->name)) {
case 'self':
return new ObjectType($nameScope->getClassName());
case 'static':
return new StaticType($nameScope->getClassName());
case 'parent':
$broker = Broker::getInstance();
if ($broker->hasClass($nameScope->getClassName())) {
$classReflection = $broker->getClass($nameScope->getClassName());
if ($classReflection->getParentClass() !== false) {
return new ObjectType($classReflection->getParentClass()->getName());
}
}
return new NonexistentParentClassType();
}
}
return new ObjectType($nameScope->resolveStringName($typeNode->name));
}
private function resolveThisTypeNode(ThisTypeNode $typeNode, NameScope $nameScope): Type
{
if ($nameScope->getClassName() !== null) {
return new ThisType($nameScope->getClassName());
}
return new ErrorType();
}
private function resolveNullableTypeNode(NullableTypeNode $typeNode, NameScope $nameScope): Type
{
return TypeCombinator::addNull($this->resolve($typeNode->type, $nameScope));
}
private function resolveUnionTypeNode(UnionTypeNode $typeNode, NameScope $nameScope): Type
{
$iterableTypeNodes = [];
$otherTypeNodes = [];
foreach ($typeNode->types as $innerTypeNode) {
if ($innerTypeNode instanceof ArrayTypeNode) {
$iterableTypeNodes[] = $innerTypeNode->type;
} else {
$otherTypeNodes[] = $innerTypeNode;
}
}
$otherTypeTypes = $this->resolveMultiple($otherTypeNodes, $nameScope);
if (count($iterableTypeNodes) > 0) {
$arrayTypeTypes = $this->resolveMultiple($iterableTypeNodes, $nameScope);
$arrayTypeType = TypeCombinator::union(...$arrayTypeTypes);
$addArray = true;
foreach ($otherTypeTypes as &$type) {
if (!$type->isIterable()->yes() || !$type->getIterableValueType()->isSuperTypeOf($arrayTypeType)->yes()) {
continue;
}
if ($type instanceof ObjectType) {
$type = new IntersectionType([$type, new IterableType(new MixedType(), $arrayTypeType)]);
} elseif ($type instanceof ArrayType) {
$type = new ArrayType(new MixedType(), $arrayTypeType);
} elseif ($type instanceof IterableType) {
$type = new IterableType(new MixedType(), $arrayTypeType);
} else {
continue;
}
$addArray = false;
}
if ($addArray) {
$otherTypeTypes[] = new ArrayType(new MixedType(), $arrayTypeType);
}
}
return TypeCombinator::union(...$otherTypeTypes);
}
private function resolveIntersectionTypeNode(IntersectionTypeNode $typeNode, NameScope $nameScope): Type
{
$types = $this->resolveMultiple($typeNode->types, $nameScope);
return TypeCombinator::intersect(...$types);
}
private function resolveArrayTypeNode(ArrayTypeNode $typeNode, NameScope $nameScope): Type
{
$itemType = $this->resolve($typeNode->type, $nameScope);
return new ArrayType(new MixedType(), $itemType);
}
private function resolveGenericTypeNode(GenericTypeNode $typeNode, NameScope $nameScope): Type
{
$mainTypeName = strtolower($typeNode->type->name);
$genericTypes = $this->resolveMultiple($typeNode->genericTypes, $nameScope);
if ($mainTypeName === 'array') {
if (count($genericTypes) === 1) { // array
return new ArrayType(new MixedType(true), $genericTypes[0]);
}
if (count($genericTypes) === 2) { // array
return new ArrayType($genericTypes[0], $genericTypes[1]);
}
} elseif ($mainTypeName === 'iterable') {
if (count($genericTypes) === 1) { // iterable
return new IterableType(new MixedType(true), $genericTypes[0]);
}
if (count($genericTypes) === 2) { // iterable
return new IterableType($genericTypes[0], $genericTypes[1]);
}
}
$mainType = $this->resolveIdentifierTypeNode($typeNode->type, $nameScope);
if ($mainType->isIterable()->yes()) {
if (count($genericTypes) === 1) { // Foo
return TypeCombinator::intersect(
$mainType,
new IterableType(new MixedType(true), $genericTypes[0])
);
}
if (count($genericTypes) === 2) { // Foo
return TypeCombinator::intersect(
$mainType,
new IterableType($genericTypes[0], $genericTypes[1])
);
}
}
return new ErrorType();
}
private function resolveCallableTypeNode(CallableTypeNode $typeNode, NameScope $nameScope): Type
{
$mainType = $this->resolve($typeNode->identifier, $nameScope);
$isVariadic = false;
$parameters = array_map(
function (CallableTypeParameterNode $parameterNode) use ($nameScope, &$isVariadic): NativeParameterReflection {
$isVariadic = $isVariadic || $parameterNode->isVariadic;
return new NativeParameterReflection(
$parameterNode->parameterName,
$parameterNode->isOptional,
$this->resolve($parameterNode->type, $nameScope),
$parameterNode->isReference ? PassedByReference::createCreatesNewVariable() : PassedByReference::createNo(),
$parameterNode->isVariadic
);
},
$typeNode->parameters
);
$returnType = $this->resolve($typeNode->returnType, $nameScope);
if ($mainType instanceof CallableType) {
return new CallableType($parameters, $returnType, $isVariadic);
} elseif (
$mainType instanceof ObjectType
&& $mainType->getClassName() === \Closure::class
) {
return new ClosureType($parameters, $returnType, $isVariadic);
}
return new ErrorType();
}
/**
* @param TypeNode[] $typeNodes
* @param NameScope $nameScope
* @return Type[]
*/
public function resolveMultiple(array $typeNodes, NameScope $nameScope): array
{
$types = [];
foreach ($typeNodes as $typeNode) {
$types[] = $this->resolve($typeNode, $nameScope);
}
return $types;
}
}
src/PhpDoc/PhpDocBlock.php 0000666 00000006621 13436755504 0011376 0 ustar 00 docComment = $docComment;
$this->file = $file;
$this->class = $class;
}
public function getDocComment(): string
{
return $this->docComment;
}
public function getFile(): string
{
return $this->file;
}
public function getClass(): string
{
return $this->class;
}
public static function resolvePhpDocBlockForProperty(
Broker $broker,
string $docComment,
string $class,
string $propertyName,
string $file
): self
{
return self::resolvePhpDocBlock(
$broker,
$docComment,
$class,
$propertyName,
$file,
'hasNativeProperty',
'getNativeProperty',
__FUNCTION__
);
}
public static function resolvePhpDocBlockForMethod(
Broker $broker,
string $docComment,
string $class,
string $methodName,
string $file
): self
{
return self::resolvePhpDocBlock(
$broker,
$docComment,
$class,
$methodName,
$file,
'hasNativeMethod',
'getNativeMethod',
__FUNCTION__
);
}
private static function resolvePhpDocBlock(
Broker $broker,
string $docComment,
string $class,
string $name,
string $file,
string $hasMethodName,
string $getMethodName,
string $resolveMethodName
): self
{
if (
preg_match('#\{@inheritdoc\}#i', $docComment) > 0
&& $broker->hasClass($class)
) {
$classReflection = $broker->getClass($class);
if ($classReflection->getParentClass() !== false) {
$parentClassReflection = $classReflection->getParentClass();
$phpDocBlockFromClass = self::resolvePhpDocBlockFromClass(
$broker,
$parentClassReflection,
$name,
$hasMethodName,
$getMethodName,
$resolveMethodName
);
if ($phpDocBlockFromClass !== null) {
return $phpDocBlockFromClass;
}
}
foreach ($classReflection->getInterfaces() as $interface) {
$phpDocBlockFromClass = self::resolvePhpDocBlockFromClass(
$broker,
$interface,
$name,
$hasMethodName,
$getMethodName,
$resolveMethodName
);
if ($phpDocBlockFromClass !== null) {
return $phpDocBlockFromClass;
}
}
}
return new self($docComment, $file, $class);
}
private static function resolvePhpDocBlockFromClass(
Broker $broker,
ClassReflection $classReflection,
string $name,
string $hasMethodName,
string $getMethodName,
string $resolveMethodName
): ?self
{
if ($classReflection->getFileName() !== false && $classReflection->$hasMethodName($name)) {
/** @var \PHPStan\Reflection\PropertyReflection|\PHPStan\Reflection\MethodReflection $parentReflection */
$parentReflection = $classReflection->$getMethodName($name);
if (
!$parentReflection instanceof PhpPropertyReflection
&& !$parentReflection instanceof PhpMethodReflection
) {
return null;
}
if ($parentReflection->getDocComment() !== false) {
return self::$resolveMethodName(
$broker,
$parentReflection->getDocComment(),
$classReflection->getName(),
$name,
$classReflection->getFileName()
);
}
}
return null;
}
}
src/PhpDoc/TypeNodeResolverFactory.php 0000666 00000001247 13436755504 0014046 0 ustar 00 container = $container;
}
public function create(): TypeNodeResolver
{
$tagToService = function (array $tags) {
return array_map(function (string $serviceName) {
return $this->container->getService($serviceName);
}, array_keys($tags));
};
return new TypeNodeResolver(
$tagToService($this->container->findByTag(self::EXTENSION_TAG))
);
}
}
src/PhpDoc/PhpDocNodeResolver.php 0000666 00000015533 13436755504 0012755 0 ustar 00 typeNodeResolver = $typeNodeResolver;
}
public function resolve(PhpDocNode $phpDocNode, NameScope $nameScope): ResolvedPhpDocBlock
{
return ResolvedPhpDocBlock::create(
$this->resolveVarTags($phpDocNode, $nameScope),
$this->resolveMethodTags($phpDocNode, $nameScope),
$this->resolvePropertyTags($phpDocNode, $nameScope),
$this->resolveParamTags($phpDocNode, $nameScope),
$this->resolveReturnTag($phpDocNode, $nameScope),
$this->resolveThrowsTags($phpDocNode, $nameScope),
$this->resolveIsDeprecated($phpDocNode),
$this->resolveIsInternal($phpDocNode),
$this->resolveIsFinal($phpDocNode)
);
}
/**
* @param PhpDocNode $phpDocNode
* @param NameScope $nameScope
* @return array
*/
private function resolveVarTags(PhpDocNode $phpDocNode, NameScope $nameScope): array
{
$resolved = [];
foreach ($phpDocNode->getVarTagValues() as $tagValue) {
if ($tagValue->variableName !== '') {
$variableName = substr($tagValue->variableName, 1);
$type = !isset($resolved[$variableName])
? $this->typeNodeResolver->resolve($tagValue->type, $nameScope)
: new MixedType();
$resolved[$variableName] = new VarTag($type);
} else {
$resolved[] = new VarTag($this->typeNodeResolver->resolve($tagValue->type, $nameScope));
}
}
return $resolved;
}
/**
* @param PhpDocNode $phpDocNode
* @param NameScope $nameScope
* @return array
*/
private function resolvePropertyTags(PhpDocNode $phpDocNode, NameScope $nameScope): array
{
$resolved = [];
foreach ($phpDocNode->getPropertyTagValues() as $tagValue) {
$propertyName = substr($tagValue->propertyName, 1);
$propertyType = !isset($resolved[$propertyName])
? $this->typeNodeResolver->resolve($tagValue->type, $nameScope)
: new MixedType();
$resolved[$propertyName] = new PropertyTag(
$propertyType,
true,
true
);
}
foreach ($phpDocNode->getPropertyReadTagValues() as $tagValue) {
$propertyName = substr($tagValue->propertyName, 1);
$propertyType = !isset($resolved[$propertyName])
? $this->typeNodeResolver->resolve($tagValue->type, $nameScope)
: new MixedType();
$resolved[$propertyName] = new PropertyTag(
$propertyType,
true,
false
);
}
foreach ($phpDocNode->getPropertyWriteTagValues() as $tagValue) {
$propertyName = substr($tagValue->propertyName, 1);
$propertyType = !isset($resolved[$propertyName])
? $this->typeNodeResolver->resolve($tagValue->type, $nameScope)
: new MixedType();
$resolved[$propertyName] = new PropertyTag(
$propertyType,
false,
true
);
}
return $resolved;
}
/**
* @param PhpDocNode $phpDocNode
* @param NameScope $nameScope
* @return array
*/
private function resolveMethodTags(PhpDocNode $phpDocNode, NameScope $nameScope): array
{
$resolved = [];
foreach ($phpDocNode->getMethodTagValues() as $tagValue) {
$parameters = [];
foreach ($tagValue->parameters as $parameterNode) {
$parameterName = substr($parameterNode->parameterName, 1);
$type = $parameterNode->type !== null ? $this->typeNodeResolver->resolve($parameterNode->type, $nameScope) : new MixedType();
if ($parameterNode->defaultValue instanceof ConstExprNullNode) {
$type = TypeCombinator::addNull($type);
}
$parameters[$parameterName] = new MethodTagParameter(
$type,
$parameterNode->isReference
? PassedByReference::createCreatesNewVariable()
: PassedByReference::createNo(),
$parameterNode->isVariadic || $parameterNode->defaultValue !== null,
$parameterNode->isVariadic
);
}
$resolved[$tagValue->methodName] = new MethodTag(
$tagValue->returnType !== null ? $this->typeNodeResolver->resolve($tagValue->returnType, $nameScope) : new MixedType(),
$tagValue->isStatic,
$parameters
);
}
return $resolved;
}
/**
* @param PhpDocNode $phpDocNode
* @param NameScope $nameScope
* @return array
*/
private function resolveParamTags(PhpDocNode $phpDocNode, NameScope $nameScope): array
{
$resolved = [];
foreach ($phpDocNode->getParamTagValues() as $tagValue) {
$parameterName = substr($tagValue->parameterName, 1);
$parameterType = !isset($resolved[$parameterName])
? $this->typeNodeResolver->resolve($tagValue->type, $nameScope)
: new MixedType();
if ($tagValue->isVariadic) {
if (!$parameterType instanceof ArrayType) {
$parameterType = new ArrayType(new IntegerType(), $parameterType);
} elseif ($parameterType->getKeyType() instanceof MixedType) {
$parameterType = new ArrayType(new IntegerType(), $parameterType->getItemType());
}
}
$resolved[$parameterName] = new ParamTag(
$parameterType,
$tagValue->isVariadic
);
}
return $resolved;
}
private function resolveReturnTag(PhpDocNode $phpDocNode, NameScope $nameScope): ?\PHPStan\PhpDoc\Tag\ReturnTag
{
foreach ($phpDocNode->getReturnTagValues() as $tagValue) {
return new ReturnTag($this->typeNodeResolver->resolve($tagValue->type, $nameScope));
}
return null;
}
private function resolveThrowsTags(PhpDocNode $phpDocNode, NameScope $nameScope): ?\PHPStan\PhpDoc\Tag\ThrowsTag
{
$types = array_map(function (ThrowsTagValueNode $throwsTagValue) use ($nameScope): Type {
return $this->typeNodeResolver->resolve($throwsTagValue->type, $nameScope);
}, $phpDocNode->getThrowsTagValues());
if (count($types) === 0) {
return null;
}
return new ThrowsTag(TypeCombinator::union(...$types));
}
private function resolveIsDeprecated(PhpDocNode $phpDocNode): bool
{
$deprecatedTags = $phpDocNode->getTagsByName('@deprecated');
return count($deprecatedTags) > 0;
}
private function resolveIsInternal(PhpDocNode $phpDocNode): bool
{
$internalTags = $phpDocNode->getTagsByName('@internal');
return count($internalTags) > 0;
}
private function resolveIsFinal(PhpDocNode $phpDocNode): bool
{
$finalTags = $phpDocNode->getTagsByName('@final');
return count($finalTags) > 0;
}
}
src/PhpDoc/TypeNodeResolverExtension.php 0000666 00000000477 13436755504 0014417 0 ustar 00 typeLexer = $typeLexer;
$this->typeParser = $typeParser;
$this->typeNodeResolver = $typeNodeResolver;
}
public function resolve(string $typeString, ?NameScope $nameScope = null): Type
{
$tokens = new TokenIterator($this->typeLexer->tokenize($typeString));
$typeNode = $this->typeParser->parse($tokens);
$tokens->consumeTokenType(Lexer::TOKEN_END);
return $this->typeNodeResolver->resolve($typeNode, $nameScope ?? new NameScope(null, []));
}
}
src/PhpDoc/Tag/ThrowsTag.php 0000666 00000000726 13436755504 0011703 0 ustar 00 type = $type;
}
public function getType(): Type
{
return $this->type;
}
/**
* @param mixed[] $properties
* @return ThrowsTag
*/
public static function __set_state(array $properties): self
{
return new self(
$properties['type']
);
}
}
src/PhpDoc/Tag/MethodTagParameter.php 0000666 00000002304 13436755504 0013470 0 ustar 00 type = $type;
$this->passedByReference = $passedByReference;
$this->isOptional = $isOptional;
$this->isVariadic = $isVariadic;
}
public function getType(): Type
{
return $this->type;
}
public function passedByReference(): PassedByReference
{
return $this->passedByReference;
}
public function isOptional(): bool
{
return $this->isOptional;
}
public function isVariadic(): bool
{
return $this->isVariadic;
}
/**
* @param mixed[] $properties
* @return self
*/
public static function __set_state(array $properties): self
{
return new self(
$properties['type'],
$properties['passedByReference'],
$properties['isOptional'],
$properties['isVariadic']
);
}
}
src/PhpDoc/Tag/PropertyTag.php 0000666 00000001521 13436755504 0012233 0 ustar 00 type = $type;
$this->readable = $readable;
$this->writable = $writable;
}
public function getType(): Type
{
return $this->type;
}
public function isReadable(): bool
{
return $this->readable;
}
public function isWritable(): bool
{
return $this->writable;
}
/**
* @param mixed[] $properties
* @return PropertyTag
*/
public static function __set_state(array $properties): self
{
return new self(
$properties['type'],
$properties['readable'],
$properties['writable']
);
}
}
src/PhpDoc/Tag/ParamTag.php 0000666 00000001223 13436755504 0011446 0 ustar 00 type = $type;
$this->isVariadic = $isVariadic;
}
public function getType(): Type
{
return $this->type;
}
public function isVariadic(): bool
{
return $this->isVariadic;
}
/**
* @param mixed[] $properties
* @return self
*/
public static function __set_state(array $properties): self
{
return new self(
$properties['type'],
$properties['isVariadic']
);
}
}
src/PhpDoc/Tag/MethodTag.php 0000666 00000002231 13436755504 0011626 0 ustar 00 */
private $parameters;
/**
* @param \PHPStan\Type\Type $returnType
* @param bool $isStatic
* @param array $parameters
*/
public function __construct(
Type $returnType,
bool $isStatic,
array $parameters
)
{
$this->returnType = $returnType;
$this->isStatic = $isStatic;
$this->parameters = $parameters;
}
public function getReturnType(): Type
{
return $this->returnType;
}
public function isStatic(): bool
{
return $this->isStatic;
}
/**
* @return array
*/
public function getParameters(): array
{
return $this->parameters;
}
/**
* @param mixed[] $properties
* @return self
*/
public static function __set_state(array $properties): self
{
return new self(
$properties['returnType'],
$properties['isStatic'],
$properties['parameters']
);
}
}
src/PhpDoc/Tag/ReturnTag.php 0000666 00000000726 13436755504 0011674 0 ustar 00 type = $type;
}
public function getType(): Type
{
return $this->type;
}
/**
* @param mixed[] $properties
* @return ReturnTag
*/
public static function __set_state(array $properties): self
{
return new self(
$properties['type']
);
}
}
src/PhpDoc/Tag/VarTag.php 0000666 00000000716 13436755504 0011144 0 ustar 00 type = $type;
}
public function getType(): Type
{
return $this->type;
}
/**
* @param mixed[] $properties
* @return self
*/
public static function __set_state(array $properties): self
{
return new self(
$properties['type']
);
}
}
src/PhpDoc/PhpDocStringResolver.php 0000666 00000001761 13436755504 0013334 0 ustar 00 phpDocNodeResolver = $phpDocNodeResolver;
$this->phpDocLexer = $phpDocLexer;
$this->phpDocParser = $phpDocParser;
}
public function resolve(string $phpDocString, NameScope $nameScope): ResolvedPhpDocBlock
{
$tokens = new TokenIterator($this->phpDocLexer->tokenize($phpDocString));
$phpDocNode = $this->phpDocParser->parse($tokens);
$tokens->consumeTokenType(Lexer::TOKEN_END);
return $this->phpDocNodeResolver->resolve($phpDocNode, $nameScope);
}
}
src/PhpDoc/TypeNodeResolverAwareExtension.php 0000666 00000000274 13436755504 0015372 0 ustar 00 */
private $varTags;
/** @var array */
private $methodTags;
/** @var array */
private $propertyTags;
/** @var array */
private $paramTags;
/** @var \PHPStan\PhpDoc\Tag\ReturnTag|null */
private $returnTag;
/** @var \PHPStan\PhpDoc\Tag\ThrowsTag|null */
private $throwsTag;
/** @var bool */
private $isDeprecated;
/** @var bool */
private $isInternal;
/** @var bool */
private $isFinal;
/**
* @param array $varTags
* @param array $methodTags
* @param array $propertyTags
* @param array $paramTags
* @param \PHPStan\PhpDoc\Tag\ReturnTag|null $returnTag
* @param \PHPStan\PhpDoc\Tag\ThrowsTag|null $throwsTags
* @param bool $isDeprecated
* @param bool $isInternal
* @param bool $isFinal
*/
private function __construct(
array $varTags,
array $methodTags,
array $propertyTags,
array $paramTags,
?ReturnTag $returnTag,
?ThrowsTag $throwsTags,
bool $isDeprecated,
bool $isInternal,
bool $isFinal
)
{
$this->varTags = $varTags;
$this->methodTags = $methodTags;
$this->propertyTags = $propertyTags;
$this->paramTags = $paramTags;
$this->returnTag = $returnTag;
$this->throwsTag = $throwsTags;
$this->isDeprecated = $isDeprecated;
$this->isInternal = $isInternal;
$this->isFinal = $isFinal;
}
/**
* @param array $varTags
* @param array $methodTags
* @param array $propertyTags
* @param array $paramTags
* @param \PHPStan\PhpDoc\Tag\ReturnTag|null $returnTag
* @param \PHPStan\PhpDoc\Tag\ThrowsTag|null $throwsTag
* @param bool $isDeprecated
* @param bool $isInternal
* @param bool $isFinal
* @return self
*/
public static function create(
array $varTags,
array $methodTags,
array $propertyTags,
array $paramTags,
?ReturnTag $returnTag,
?ThrowsTag $throwsTag,
bool $isDeprecated,
bool $isInternal,
bool $isFinal
): self
{
return new self(
$varTags,
$methodTags,
$propertyTags,
$paramTags,
$returnTag,
$throwsTag,
$isDeprecated,
$isInternal,
$isFinal
);
}
public static function createEmpty(): self
{
return new self([], [], [], [], null, null, false, false, false);
}
/**
* @return array
*/
public function getVarTags(): array
{
return $this->varTags;
}
/**
* @return array
*/
public function getMethodTags(): array
{
return $this->methodTags;
}
/**
* @return array
*/
public function getPropertyTags(): array
{
return $this->propertyTags;
}
/**
* @return array
*/
public function getParamTags(): array
{
return $this->paramTags;
}
public function getReturnTag(): ?\PHPStan\PhpDoc\Tag\ReturnTag
{
return $this->returnTag;
}
public function getThrowsTag(): ?\PHPStan\PhpDoc\Tag\ThrowsTag
{
return $this->throwsTag;
}
public function isDeprecated(): bool
{
return $this->isDeprecated;
}
public function isInternal(): bool
{
return $this->isInternal;
}
public function isFinal(): bool
{
return $this->isFinal;
}
/**
* @param mixed[] $properties
* @return self
*/
public static function __set_state(array $properties): self
{
return new self(
$properties['varTags'],
$properties['methodTags'],
$properties['propertyTags'],
$properties['paramTags'],
$properties['returnTag'],
$properties['throwsTag'],
$properties['isDeprecated'],
$properties['isInternal'],
$properties['isFinal']
);
}
}
src/PhpDoc/PhpUnit/MockObjectTypeNodeResolverExtension.php 0000666 00000002537 13436755504 0017746 0 ustar 00 typeNodeResolver = $typeNodeResolver;
}
public function getCacheKey(): string
{
return 'phpunit-v1';
}
public function resolve(TypeNode $typeNode, \PHPStan\Analyser\NameScope $nameScope): ?Type
{
if (!$typeNode instanceof UnionTypeNode) {
return null;
}
static $mockClassNames = [
'PHPUnit_Framework_MockObject_MockObject' => true,
'PHPUnit\Framework\MockObject\MockObject' => true,
];
$types = $this->typeNodeResolver->resolveMultiple($typeNode->types, $nameScope);
foreach ($types as $type) {
if (!$type instanceof TypeWithClassName) {
continue;
}
if (array_key_exists($type->getClassName(), $mockClassNames)) {
return \PHPStan\Type\TypeCombinator::intersect(...$types);
}
}
return null;
}
}
src/DependencyInjection/Configurator.php 0000666 00000000666 13436755504 0014457 0 ustar 00 loaderFactory = $loaderFactory;
parent::__construct();
}
protected function createLoader(): Loader
{
return $this->loaderFactory->createLoader();
}
}
src/DependencyInjection/RulesExtension.php 0000666 00000000744 13436755504 0015001 0 ustar 00 config;
$builder = $this->getContainerBuilder();
foreach ($config as $key => $rule) {
$builder->addDefinition($this->prefix((string) $key))
->setFactory($rule)
->setAutowired(false)
->addTag(RegistryFactory::RULE_TAG);
}
}
}
src/DependencyInjection/LoaderFactory.php 0000666 00000000471 13436755504 0014545 0 ustar 00 addAdapter('dist', NeonAdapter::class);
return $loader;
}
}
src/DependencyInjection/ContainerFactory.php 0000666 00000004516 13436755504 0015265 0 ustar 00 currentWorkingDirectory = $currentWorkingDirectory;
$fileHelper = new FileHelper($currentWorkingDirectory);
$this->rootDirectory = $fileHelper->normalizePath(__DIR__ . '/../..');
$this->configDirectory = $this->rootDirectory . '/conf';
}
/**
* @param string $tempDirectory
* @param string[] $additionalConfigFiles
* @param string[] $analysedPaths
* @return \Nette\DI\Container
*/
public function create(
string $tempDirectory,
array $additionalConfigFiles,
array $analysedPaths = []
): \Nette\DI\Container
{
$configurator = new Configurator(new LoaderFactory());
$configurator->defaultExtensions = [
'php' => PhpExtension::class,
'extensions' => \Nette\DI\Extensions\ExtensionsExtension::class,
];
$configurator->setDebugMode(true);
$configurator->setTempDirectory($tempDirectory);
$configurator->addParameters([
'rootDir' => $this->rootDirectory,
'currentWorkingDirectory' => $this->currentWorkingDirectory,
'cliArgumentsVariablesRegistered' => ini_get('register_argc_argv') === '1',
'tmpDir' => $tempDirectory,
]);
$configurator->addConfig($this->configDirectory . '/config.neon');
foreach ($additionalConfigFiles as $additionalConfigFile) {
$configurator->addConfig($additionalConfigFile);
}
$configurator->addServices([
'relativePathHelper' => new RelativePathHelper($this->currentWorkingDirectory, DIRECTORY_SEPARATOR, $analysedPaths),
]);
$container = $configurator->createContainer();
/** @var Broker $broker */
$broker = $container->getService('broker');
Broker::registerInstance($broker);
$container->getService('typeSpecifier');
return $container;
}
public function getCurrentWorkingDirectory(): string
{
return $this->currentWorkingDirectory;
}
public function getRootDirectory(): string
{
return $this->rootDirectory;
}
public function getConfigDirectory(): string
{
return $this->configDirectory;
}
}
build.xml 0000666 00000012273 13436755504 0006412 0 ustar 00
CODE_OF_CONDUCT.md 0000666 00000006227 13436755504 0007372 0 ustar 00 # Contributor Code of Conduct
## Our Pledge
In the interest of fostering an open and welcoming environment, we as
contributors and maintainers pledge to making participation in our project and
our community a harassment-free experience for everyone, regardless of age, body
size, disability, ethnicity, gender identity and expression, level of experience,
nationality, personal appearance, race, religion, or sexual identity and
orientation.
## Our Standards
Examples of behavior that contributes to creating a positive environment
include:
* Using welcoming and inclusive language
* Being respectful of differing viewpoints and experiences
* Gracefully accepting constructive criticism
* Focusing on what is best for the community
* Showing empathy towards other community members
Examples of unacceptable behavior by participants include:
* The use of sexualized language or imagery and unwelcome sexual attention or
advances
* Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or electronic
address, without explicit permission
* Other conduct which could reasonably be considered inappropriate in a
professional setting
## Our Responsibilities
Project maintainers are responsible for clarifying the standards of acceptable
behavior and are expected to take appropriate and fair corrective action in
response to any instances of unacceptable behavior.
Project maintainers have the right and responsibility to remove, edit, or
reject comments, commits, code, wiki edits, issues, and other contributions
that are not aligned to this Code of Conduct, or to ban temporarily or
permanently any contributor for other behaviors that they deem inappropriate,
threatening, offensive, or harmful.
## Scope
This Code of Conduct applies both within project spaces and in public spaces
when an individual is representing the project or its community. Examples of
representing a project or community include using an official project e-mail
address, posting via an official social media account, or acting as an appointed
representative at an online or offline event. Representation of a project may be
further defined and clarified by project maintainers.
## Enforcement
Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported by contacting the project maintainer at . All
complaints will be reviewed and investigated and will result in a response that
is deemed necessary and appropriate to the circumstances. The project team is
obligated to maintain confidentiality with regard to the reporter of an incident.
Further details of specific enforcement policies may be posted separately.
Project maintainers who do not follow or enforce the Code of Conduct in good
faith may face temporary or permanent repercussions as determined by other
members of the project's leadership.
## Attribution
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
available at [http://contributor-covenant.org/version/1/4][version]
[homepage]: http://contributor-covenant.org
[version]: http://contributor-covenant.org/version/1/4/
tmp/cache/.gitignore 0000666 00000000006 13436755504 0010413 0 ustar 00 *
!.*
tmp/generated/.gitignore 0000666 00000000006 13436755504 0011306 0 ustar 00 *
!.*
tmp/.gitignore 0000666 00000000032 13436755504 0007347 0 ustar 00 *
!/cache
!/generated
!.*
composer.json 0000666 00000002642 13436755504 0007312 0 ustar 00 {
"name": "phpstan/phpstan",
"description": "PHPStan - PHP Static Analysis Tool",
"license": [
"MIT"
],
"require": {
"php": "~7.1",
"composer/xdebug-handler": "^1.3.0",
"jean85/pretty-package-versions": "^1.0.3",
"nette/bootstrap": "^2.4 || ^3.0",
"nette/di": "^2.4.7 || ^3.0",
"nette/robot-loader": "^3.0.1",
"nette/utils": "^2.4.5 || ^3.0",
"nikic/php-parser": "^4.0.2",
"phpstan/phpdoc-parser": "^0.3",
"symfony/console": "~3.2 || ~4.0",
"symfony/finder": "~3.2 || ~4.0"
},
"require-dev": {
"ext-gd": "*",
"ext-intl": "*",
"ext-mysqli": "*",
"ext-zip": "*",
"brianium/paratest": "^2.0",
"consistence/coding-standard": "^3.5",
"dealerdirect/phpcodesniffer-composer-installer": "^0.4.4",
"jakub-onderka/php-parallel-lint": "^1.0",
"localheinz/composer-normalize": "~0.9.0",
"phing/phing": "^2.16.0",
"phpstan/phpstan-deprecation-rules": "^0.10.2",
"phpstan/phpstan-php-parser": "^0.10",
"phpstan/phpstan-phpunit": "^0.10",
"phpstan/phpstan-strict-rules": "^0.10",
"phpunit/phpunit": "^7.0",
"slevomat/coding-standard": "^4.7.2"
},
"config": {
"sort-packages": true
},
"extra": {
"branch-alias": {
"dev-master": "0.10-dev"
}
},
"autoload": {
"psr-4": {
"PHPStan\\": [
"src/",
"build/PHPStan"
]
}
},
"autoload-dev": {
"classmap": [
"tests/PHPStan"
]
},
"minimum-stability": "dev",
"prefer-stable": true,
"bin": [
"bin/phpstan"
]
}
.travis.yml 0000666 00000001123 13436755504 0006672 0 ustar 00 language: php
php:
- 7.1
- 7.2
- master
env:
- dependencies=lowest
- dependencies=highest
matrix:
allow_failures:
- php: master
env: dependencies=lowest
- php: master
env: dependencies=highest
before_script:
- if php --ri xdebug >/dev/null; then phpenv config-rm xdebug.ini; fi
install:
- if [ "$dependencies" = "lowest" ]; then composer update --prefer-lowest --no-interaction; fi
- if [ "$dependencies" = "highest" ]; then composer update --no-interaction; fi
script:
- vendor/bin/phing
cache:
directories:
- $HOME/.composer/cache
- tmp
bin/phpstan 0000666 00000001666 13436755504 0006745 0 ustar 00 #!/usr/bin/env php
check();
unset($xdebug);
$version = 'Version unknown';
try {
$version = \Jean85\PrettyVersions::getVersion('phpstan/phpstan')->getPrettyVersion();
} catch (\OutOfBoundsException $e) {
}
$application = new \Symfony\Component\Console\Application(
'PHPStan - PHP Static Analysis Tool',
$version
);
$application->add(new AnalyseCommand());
$application->run();
.editorconfig 0000666 00000000543 13436755504 0007243 0 ustar 00 root = true
[*]
end_of_line = lf
insert_final_newline = true
charset = utf-8
trim_trailing_whitespace = true
[*.{php,phpt}]
indent_style = tab
indent_size = 4
[*.xml]
indent_style = tab
indent_size = 4
[*.neon]
indent_style = tab
indent_size = 4
[*.{yaml,yml}]
indent_style = space
indent_size = 2
[composer.json]
indent_style = tab
indent_size = 4
appveyor.yml 0000666 00000006166 13436755504 0007165 0 ustar 00 build: false
clone_folder: c:\projects\phpstan
clone_depth: 1
platform:
- x64
environment:
matrix:
- dependencies: lowest
php_version: 7.1
- dependencies: highest
php_version: 7.1
- dependencies: lowest
php_version: 7.2
- dependencies: highest
php_version: 7.2
project_directory: c:\projects\phpstan
composer_directory: c:\tools\composer
composer_executable: c:\tools\composer\composer.phar
composer_installer: c:\tools\composer\installer.php
php_root_directory: c:\tools\php
cache:
- c:\ProgramData\chocolatey\bin -> appveyor.yml
- c:\ProgramData\chocolatey\lib -> appveyor.yml
- c:\tools\composer -> appveyor.yml
- '%LOCALAPPDATA%\Composer -> appveyor.yml'
- c:\tools\php -> appveyor.yml
init:
- ps: $Env:php_directory = $Env:php_root_directory + '\' + $Env:php_version
- ps: $Env:exact_php_version = (((choco search php --exact --all-versions --limit-output | Select-String -pattern $Env:php_version) -replace '[php|]', '') | %{ New-Object System.Version $_ } | Sort-Object | Select-Object -Last 1).ToString()
- ps: $Env:PATH = $Env:php_directory + ';' + $Env:composer_directory + ';' + $Env:PATH
- ps: $Env:COMPOSER_NO_INTERACTION = 1
- ps: $Env:ANSICON = '121x90 (121x90)'
install:
# Install PHP
- ps: If ((Test-Path $Env:php_directory) -eq $False) { New-Item -Path $Env:php_directory -ItemType 'directory' }
- ps: $php_install_parameters = '"/DontAddToPath /InstallDir:' + $Env:php_directory + '"'
- ps: appveyor-retry choco upgrade php --yes --version=$Env:exact_php_version --params=$php_install_parameters
# Prepare PHP
- ps: cd $Env:php_directory
- ps: Copy-Item php.ini-production -Destination php.ini
- ps: Add-Content -Path php.ini -Value 'memory_limit=1G'
- ps: Add-Content -Path php.ini -Value 'date.timezone="UTC"'
- ps: Add-Content -Path php.ini -Value 'extension_dir=ext'
- ps: Add-Content -Path php.ini -Value 'extension=php_curl.dll'
- ps: Add-Content -Path php.ini -Value 'extension=php_intl.dll'
- ps: Add-Content -Path php.ini -Value 'extension=php_mbstring.dll'
- ps: Add-Content -Path php.ini -Value 'extension=php_openssl.dll'
- ps: Add-Content -Path php.ini -Value 'extension=php_gd2.dll'
- ps: Add-Content -Path php.ini -Value 'extension=php_mysqli.dll'
- ps: php --version
# Prepare composer
- ps: If ((Test-Path $Env:composer_directory) -eq $False) { New-Item -Path $Env:composer_directory -ItemType 'directory' }
- ps: If ((Test-Path $Env:composer_installer) -eq $False) { appveyor-retry appveyor DownloadFile https://getcomposer.org/installer -FileName $Env:composer_installer }
- ps: If ((Test-Path $Env:composer_executable) -eq $False) { php $Env:composer_installer --install-dir=$Env:composer_directory }
- ps: Set-Content -Path ($Env:composer_directory + '\composer.bat') -Value ('@php ' + $Env:composer_executable + ' %*')
# Install dependencies
- ps: cd $Env:project_directory
- IF %dependencies%==lowest composer update --prefer-dist --prefer-lowest --prefer-stable --no-progress
- IF %dependencies%==highest composer update --prefer-dist --no-progress
test_script:
- ps: cd $Env:project_directory
- vendor\bin\phing
.gitignore 0000666 00000000136 13436755504 0006554 0 ustar 00 /build/phpstan-generated.neon
/composer.lock
/conf/config.local.yml
/vendor
/.idea
/tests/tmp
conf/config.level0.neon 0000666 00000006623 13436755504 0011034 0 ustar 00 parameters:
customRulesetUsed: false
rules:
- PHPStan\Rules\Arrays\DuplicateKeysInLiteralArraysRule
- PHPStan\Rules\Classes\ClassConstantRule
- PHPStan\Rules\Classes\ExistingClassesInClassImplementsRule
- PHPStan\Rules\Classes\ExistingClassesInInterfaceExtendsRule
- PHPStan\Rules\Classes\ExistingClassInClassExtendsRule
- PHPStan\Rules\Classes\ExistingClassInTraitUseRule
- PHPStan\Rules\Classes\InstantiationRule
- PHPStan\Rules\Classes\RequireParentConstructCallRule
- PHPStan\Rules\Classes\UnusedConstructorParametersRule
- PHPStan\Rules\Functions\CallToFunctionParametersRule
- PHPStan\Rules\Functions\ExistingClassesInClosureTypehintsRule
- PHPStan\Rules\Functions\ExistingClassesInTypehintsRule
- PHPStan\Rules\Functions\InnerFunctionRule
- PHPStan\Rules\Functions\NonExistentDefinedFunctionRule
- PHPStan\Rules\Functions\PrintfParametersRule
- PHPStan\Rules\Functions\UnusedClosureUsesRule
- PHPStan\Rules\Methods\ExistingClassesInTypehintsRule
- PHPStan\Rules\Properties\AccessStaticPropertiesRule
- PHPStan\Rules\Variables\ThisVariableRule
services:
-
class: PHPStan\Rules\Classes\ExistingClassInInstanceOfRule
tags:
- phpstan.rules.rule
arguments:
checkClassCaseSensitivity: %checkClassCaseSensitivity%
-
class: PHPStan\Rules\Exceptions\CaughtExceptionExistenceRule
tags:
- phpstan.rules.rule
arguments:
checkClassCaseSensitivity: %checkClassCaseSensitivity%
-
class: PHPStan\Rules\Functions\CallToNonExistentFunctionRule
tags:
- phpstan.rules.rule
arguments:
checkFunctionNameCase: %checkFunctionNameCase%
-
class: PHPStan\Rules\Methods\CallMethodsRule
tags:
- phpstan.rules.rule
arguments:
checkFunctionNameCase: %checkFunctionNameCase%
reportMagicMethods: %reportMagicMethods%
-
class: PHPStan\Rules\Methods\CallStaticMethodsRule
tags:
- phpstan.rules.rule
arguments:
checkFunctionNameCase: %checkFunctionNameCase%
reportMagicMethods: %reportMagicMethods%
-
class: PHPStan\Rules\Namespaces\ExistingNamesInGroupUseRule
tags:
- phpstan.rules.rule
arguments:
checkFunctionNameCase: %checkFunctionNameCase%
-
class: PHPStan\Rules\Namespaces\ExistingNamesInUseRule
tags:
- phpstan.rules.rule
arguments:
checkFunctionNameCase: %checkFunctionNameCase%
-
class: PHPStan\Rules\Operators\InvalidIncDecOperationRule
tags:
- phpstan.rules.rule
arguments:
checkThisOnly: %checkThisOnly%
-
class: PHPStan\Rules\Properties\AccessPropertiesRule
tags:
- phpstan.rules.rule
arguments:
reportMagicProperties: %reportMagicProperties%
-
class: PHPStan\Rules\Properties\ExistingClassesInPropertiesRule
tags:
- phpstan.rules.rule
arguments:
checkClassCaseSensitivity: %checkClassCaseSensitivity%
-
class: PHPStan\Rules\Properties\WritingToReadOnlyPropertiesRule
arguments:
checkThisOnly: %checkThisOnly%
tags:
- phpstan.rules.rule
-
class: PHPStan\Rules\Properties\ReadingWriteOnlyPropertiesRule
arguments:
checkThisOnly: %checkThisOnly%
tags:
- phpstan.rules.rule
-
class: PHPStan\Rules\Variables\DefinedVariableRule
arguments:
cliArgumentsVariablesRegistered: %cliArgumentsVariablesRegistered%
checkMaybeUndefinedVariables: %checkMaybeUndefinedVariables%
tags:
- phpstan.rules.rule
-
class: PHPStan\Rules\Variables\DefinedVariableInAnonymousFunctionUseRule
arguments:
checkMaybeUndefinedVariables: %checkMaybeUndefinedVariables%
tags:
- phpstan.rules.rule
conf/config.level7.neon 0000666 00000000103 13436755504 0011026 0 ustar 00 includes:
- config.level6.neon
parameters:
checkNullables: true
conf/config.level5.neon 0000666 00000000166 13436755504 0011035 0 ustar 00 includes:
- config.level4.neon
parameters:
checkFunctionArgumentTypes: true
checkArgumentsPassedByReference: true
conf/config.level6.neon 0000666 00000000130 13436755504 0011025 0 ustar 00 includes:
- config.level5.neon
parameters:
checkUnionTypes: true
reportMaybes: true
conf/config.level3.neon 0000666 00000001716 13436755504 0011035 0 ustar 00 includes:
- config.level2.neon
rules:
- PHPStan\Rules\Arrays\AppendedArrayItemTypeRule
- PHPStan\Rules\Arrays\IterableInForeachRule
- PHPStan\Rules\Arrays\NonexistentOffsetInArrayDimFetchRule
- PHPStan\Rules\Functions\ClosureReturnTypeRule
- PHPStan\Rules\Functions\ReturnTypeRule
- PHPStan\Rules\Methods\ReturnTypeRule
- PHPStan\Rules\Properties\DefaultValueTypesAssignedToPropertiesRule
- PHPStan\Rules\Properties\TypesAssignedToPropertiesRule
- PHPStan\Rules\Variables\ThrowTypeRule
- PHPStan\Rules\Variables\VariableCloningRule
services:
-
class: PHPStan\Rules\Arrays\AppendedArrayKeyTypeRule
arguments:
checkUnionTypes: %checkUnionTypes%
tags:
- phpstan.rules.rule
-
class: PHPStan\Rules\Arrays\InvalidKeyInArrayDimFetchRule
arguments:
reportMaybes: %reportMaybes%
tags:
- phpstan.rules.rule
-
class: PHPStan\Rules\Arrays\InvalidKeyInArrayItemRule
arguments:
reportMaybes: %reportMaybes%
tags:
- phpstan.rules.rule
conf/config.neon 0000666 00000032624 13436755504 0007646 0 ustar 00 parameters:
bootstrap: null
excludes_analyse: []
autoload_directories: []
autoload_files: []
fileExtensions:
- php
checkAlwaysTrueCheckTypeFunctionCall: false
checkAlwaysTrueInstanceof: false
checkAlwaysTrueStrictComparison: false
checkClassCaseSensitivity: false
checkFunctionArgumentTypes: false
checkFunctionNameCase: false
checkArgumentsPassedByReference: false
checkMaybeUndefinedVariables: false
checkNullables: false
checkThisOnly: true
checkUnionTypes: false
reportMaybes: false
polluteScopeWithLoopInitialAssignments: true
polluteCatchScopeWithTryAssignments: false
reportMagicMethods: false
reportMagicProperties: false
ignoreErrors: []
internalErrorsCountLimit: 50
reportUnmatchedIgnoredErrors: true
scopeClass: PHPStan\Analyser\Scope
universalObjectCratesClasses:
- stdClass
- SimpleXMLElement
earlyTerminatingMethodCalls: []
memoryLimitFile: %tmpDir%/.memory_limit
dynamicConstantNames:
- ICONV_IMPL
- PHP_VERSION
- PHP_EXTRA_VERSION
- PHP_OS
- PHP_OS_FAMILY
- PHP_SAPI
- DEFAULT_INCLUDE_PATH
- PEAR_INSTALL_DIR
- PEAR_EXTENSION_DIR
- PHP_EXTENSION_DIR
- PHP_PREFIX
- PHP_BINDIR
- PHP_BINARY
- PHP_MANDIR
- PHP_LIBDIR
- PHP_DATADIR
- PHP_SYSCONFDIR
- PHP_LOCALSTATEDIR
- PHP_CONFIG_FILE_PATH
- PHP_CONFIG_FILE_SCAN_DIR
- PHP_SHLIB_SUFFIX
- PHP_FD_SETSIZE
- PHP_MAJOR_VERSION
- PHP_MINOR_VERSION
- PHP_RELEASE_VERSION
- PHP_VERSION_ID
- PHP_ZTS
- PHP_DEBUG
- PHP_MAXPATHLEN
extensions:
rules: PHPStan\DependencyInjection\RulesExtension
services:
-
class: PhpParser\BuilderFactory
-
class: PhpParser\Lexer
-
class: PhpParser\NodeTraverser
setup:
- addVisitor(@PhpParser\NodeVisitor\NameResolver)
-
class: PhpParser\NodeVisitor\NameResolver
-
class: PhpParser\Parser\Php7
-
class: PhpParser\PrettyPrinter\Standard
-
class: PHPStan\Broker\AnonymousClassNameHelper
-
class: PHPStan\PhpDocParser\Lexer\Lexer
-
class: PHPStan\PhpDocParser\Parser\TypeParser
-
class: PHPStan\PhpDocParser\Parser\ConstExprParser
-
class: PHPStan\PhpDocParser\Parser\PhpDocParser
-
class: PHPStan\PhpDoc\PhpDocNodeResolver
-
class: PHPStan\PhpDoc\PhpDocStringResolver
-
class: PHPStan\PhpDoc\TypeNodeResolver
factory: @typeNodeResolverFactory::create
-
class: PHPStan\PhpDoc\PhpUnit\MockObjectTypeNodeResolverExtension
tags:
- phpstan.phpDoc.typeNodeResolverExtension
-
class: PHPStan\PhpDoc\TypeStringResolver
-
class: PHPStan\Analyser\Analyser
arguments:
ignoreErrors: %ignoreErrors%
reportUnmatchedIgnoredErrors: %reportUnmatchedIgnoredErrors%
internalErrorsCountLimit: %internalErrorsCountLimit%
-
class: PHPStan\Analyser\ScopeFactory
arguments:
scopeClass: %scopeClass%
dynamicConstantNames: %dynamicConstantNames%
-
class: PHPStan\Analyser\NodeScopeResolver
arguments:
polluteScopeWithLoopInitialAssignments: %polluteScopeWithLoopInitialAssignments%
polluteCatchScopeWithTryAssignments: %polluteCatchScopeWithTryAssignments%
earlyTerminatingMethodCalls: %earlyTerminatingMethodCalls%
-
class: PHPStan\Cache\Cache
arguments:
storage: @cacheStorage
-
class: PHPStan\Command\AnalyseApplication
arguments:
memoryLimitFile: %memoryLimitFile%
currentWorkingDirectory: %currentWorkingDirectory%
-
class: PHPStan\File\FileHelper
arguments:
workingDirectory: %currentWorkingDirectory%
-
class: PHPStan\File\FileExcluder
arguments:
analyseExcludes: %excludes_analyse%
-
class: PHPStan\Parser\CachedParser
arguments:
originalParser: @directParser
-
class: PHPStan\Parser\FunctionCallStatementFinder
-
implement: PHPStan\Reflection\FunctionReflectionFactory
-
class: PHPStan\Reflection\Annotations\AnnotationsMethodsClassReflectionExtension
-
class: PHPStan\Reflection\Annotations\AnnotationsPropertiesClassReflectionExtension
-
class: PHPStan\Reflection\Php\PhpClassReflectionExtension
-
class: PHPStan\Reflection\PhpDefect\PhpDefectClassReflectionExtension
-
implement: PHPStan\Reflection\Php\PhpMethodReflectionFactory
-
class: PHPStan\Reflection\Php\UniversalObjectCratesClassReflectionExtension
tags:
- phpstan.broker.propertiesClassReflectionExtension
arguments:
classes: %universalObjectCratesClasses%
-
class: PHPStan\Reflection\SignatureMap\SignatureMapParser
-
class: PHPStan\Reflection\SignatureMap\SignatureMapProvider
-
class: PHPStan\Rules\ClassCaseSensitivityCheck
-
class: PHPStan\Rules\Comparison\ConstantConditionRuleHelper
-
class: PHPStan\Rules\Comparison\ImpossibleCheckTypeHelper
-
class: PHPStan\Rules\FunctionCallParametersCheck
arguments:
checkArgumentTypes: %checkFunctionArgumentTypes%
checkArgumentsPassedByReference: %checkArgumentsPassedByReference%
-
class: PHPStan\Rules\FunctionDefinitionCheck
arguments:
checkClassCaseSensitivity: %checkClassCaseSensitivity%
checkThisOnly: %checkThisOnly%
-
class: PHPStan\Rules\FunctionReturnTypeCheck
-
class: PHPStan\Rules\Properties\PropertyDescriptor
-
class: PHPStan\Rules\Properties\PropertyReflectionFinder
-
class: PHPStan\Rules\RegistryFactory
-
class: PHPStan\Rules\RuleLevelHelper
arguments:
checkNullables: %checkNullables%
checkThisOnly: %checkThisOnly%
checkUnionTypes: %checkUnionTypes%
-
class: PHPStan\Rules\UnusedFunctionParametersCheck
-
class: PHPStan\Type\FileTypeMapper
-
class: PHPStan\Type\Php\ArgumentBasedFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\ArrayFillFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\ArrayFillKeysFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\ArrayFilterFunctionReturnTypeReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\ArrayKeyExistsFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\ArrayKeysFunctionDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\ArrayMapFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\ArrayMergeFunctionDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\ArrayPopFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\ArrayReduceFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\ArrayShiftFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\ArraySearchFunctionDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\ArrayValuesFunctionDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\CountFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\CurlInitReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\DioStatDynamicFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\ExplodeFunctionDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\GetParentClassDynamicFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\GettimeofdayDynamicFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\StatDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
- phpstan.broker.dynamicMethodReturnTypeExtension
-
class: PHPStan\Type\Php\MethodExistsTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\PropertyExistsTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\MinMaxFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\PathinfoFunctionDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\ReplaceFunctionsDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\ArrayPointerFunctionsDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\VarExportFunctionDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\MbStrlenFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\MicrotimeFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\VersionCompareFunctionDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\StrtotimeFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\RangeFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\AssertFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\DefineConstantTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\DefinedConstantTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\InArrayFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\IsIntFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\IsFloatFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\IsNullFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\IsArrayFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\IsBoolFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\IsCallableFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\IsResourceFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\IsIterableFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\IsStringFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\IsSubclassOfFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\IsObjectFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\IsNumericFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\IsScalarFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\IsAFunctionTypeSpecifyingExtension
tags:
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
-
class: PHPStan\Type\Php\TypeSpecifyingFunctionsDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
-
class: PHPStan\Type\Php\StrSplitFunctionReturnTypeExtension
tags:
- phpstan.broker.dynamicFunctionReturnTypeExtension
typeSpecifier:
class: PHPStan\Analyser\TypeSpecifier
factory: @typeSpecifierFactory::create
typeSpecifierFactory:
class: PHPStan\Analyser\TypeSpecifierFactory
relativePathHelper:
class: PHPStan\File\RelativePathHelper
dynamic: true
broker:
class: PHPStan\Broker\Broker
factory: @brokerFactory::create
brokerFactory:
class: PHPStan\Broker\BrokerFactory
cacheStorage:
class: PHPStan\Cache\FileCacheStorage
arguments:
directory: %tmpDir%/cache/PHPStan
autowired: no
directParser:
class: PHPStan\Parser\DirectParser
autowired: no
registry:
class: PHPStan\Rules\Registry
factory: @PHPStan\Rules\RegistryFactory::create
typeNodeResolverFactory:
class: PHPStan\PhpDoc\TypeNodeResolverFactory
errorFormatter.raw:
class: PHPStan\Command\ErrorFormatter\RawErrorFormatter
errorFormatter.table:
class: PHPStan\Command\ErrorFormatter\TableErrorFormatter
errorFormatter.checkstyle:
class: PHPStan\Command\ErrorFormatter\CheckstyleErrorFormatter
errorFormatter.json:
class: PHPStan\Command\ErrorFormatter\JsonErrorFormatter
arguments:
pretty: false
errorFormatter.prettyJson:
class: PHPStan\Command\ErrorFormatter\JsonErrorFormatter
arguments:
pretty: true
conf/config.level4.neon 0000666 00000002560 13436755504 0011034 0 ustar 00 includes:
- config.level3.neon
rules:
- PHPStan\Rules\Comparison\BooleanAndConstantConditionRule
- PHPStan\Rules\Comparison\BooleanNotConstantConditionRule
- PHPStan\Rules\Comparison\BooleanOrConstantConditionRule
- PHPStan\Rules\Comparison\ElseIfConstantConditionRule
- PHPStan\Rules\Comparison\IfConstantConditionRule
- PHPStan\Rules\Comparison\TernaryOperatorConstantConditionRule
- PHPStan\Rules\Cast\UselessCastRule
services:
-
class: PHPStan\Rules\Classes\ImpossibleInstanceOfRule
arguments:
checkAlwaysTrueInstanceof: %checkAlwaysTrueInstanceof%
tags:
- phpstan.rules.rule
-
class: PHPStan\Rules\Comparison\ImpossibleCheckTypeFunctionCallRule
arguments:
checkAlwaysTrueCheckTypeFunctionCall: %checkAlwaysTrueCheckTypeFunctionCall%
tags:
- phpstan.rules.rule
-
class: PHPStan\Rules\Comparison\ImpossibleCheckTypeMethodCallRule
arguments:
checkAlwaysTrueCheckTypeFunctionCall: %checkAlwaysTrueCheckTypeFunctionCall%
tags:
- phpstan.rules.rule
-
class: PHPStan\Rules\Comparison\ImpossibleCheckTypeStaticMethodCallRule
arguments:
checkAlwaysTrueCheckTypeFunctionCall: %checkAlwaysTrueCheckTypeFunctionCall%
tags:
- phpstan.rules.rule
-
class: PHPStan\Rules\Comparison\StrictComparisonOfDifferentTypesRule
arguments:
checkAlwaysTrueStrictComparison: %checkAlwaysTrueStrictComparison%
tags:
- phpstan.rules.rule
conf/config.level2.neon 0000666 00000001133 13436755504 0011025 0 ustar 00 includes:
- config.level1.neon
parameters:
checkClassCaseSensitivity: true
checkThisOnly: false
rules:
- PHPStan\Rules\Cast\InvalidCastRule
- PHPStan\Rules\Cast\InvalidPartOfEncapsedStringRule
- PHPStan\Rules\Operators\InvalidBinaryOperationRule
- PHPStan\Rules\Operators\InvalidUnaryOperationRule
- PHPStan\Rules\PhpDoc\IncompatiblePhpDocTypeRule
- PHPStan\Rules\PhpDoc\InvalidPhpDocTagValueRule
- PHPStan\Rules\PhpDoc\InvalidThrowsPhpDocValueRule
services:
-
class: PHPStan\Rules\Functions\CallCallablesRule
arguments:
reportMaybes: %reportMaybes%
tags:
- phpstan.rules.rule
conf/config.levelmax.neon 0000666 00000000040 13436755504 0011445 0 ustar 00 includes:
- config.level7.neon
conf/config.level1.neon 0000666 00000000360 13436755504 0011025 0 ustar 00 includes:
- config.level0.neon
parameters:
checkMaybeUndefinedVariables: true
reportMagicMethods: true
reportMagicProperties: true
rules:
- PHPStan\Rules\Constants\ConstantRule
- PHPStan\Rules\Variables\VariableCertaintyInIssetRule
.gitattributes 0000666 00000000052 13436755504 0007454 0 ustar 00 /build export-ignore
/tests export-ignore