2016-11-13 05:59:31 +01:00
|
|
|
<?php
|
2018-05-12 00:35:02 +02:00
|
|
|
namespace Psalm\Scanner;
|
2016-11-13 05:59:31 +01:00
|
|
|
|
|
|
|
class FunctionDocblockComment
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* @var string|null
|
|
|
|
*/
|
|
|
|
public $return_type = null;
|
|
|
|
|
|
|
|
/**
|
2017-11-19 19:05:35 +01:00
|
|
|
* @var array<int, array{name:string, type:string, line_number: int}>
|
2016-11-13 05:59:31 +01:00
|
|
|
*/
|
|
|
|
public $params = [];
|
|
|
|
|
2018-06-08 15:31:21 +02:00
|
|
|
/**
|
|
|
|
* @var array<int, array{name:string, type:string, line_number: int}>
|
|
|
|
*/
|
|
|
|
public $globals = [];
|
|
|
|
|
2016-11-13 05:59:31 +01:00
|
|
|
/**
|
|
|
|
* Whether or not the function is deprecated
|
2017-05-27 02:16:18 +02:00
|
|
|
*
|
|
|
|
* @var bool
|
2016-11-13 05:59:31 +01:00
|
|
|
*/
|
|
|
|
public $deprecated = false;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Whether or not the function uses get_args
|
|
|
|
*
|
2017-05-27 02:16:18 +02:00
|
|
|
* @var bool
|
2016-11-13 05:59:31 +01:00
|
|
|
*/
|
|
|
|
public $variadic = false;
|
|
|
|
|
2017-05-10 18:36:11 +02:00
|
|
|
/**
|
|
|
|
* Whether or not to ignore the nullability of this function's return type
|
|
|
|
*
|
2017-05-27 02:16:18 +02:00
|
|
|
* @var bool
|
2017-05-10 18:36:11 +02:00
|
|
|
*/
|
|
|
|
public $ignore_nullable_return = false;
|
|
|
|
|
2018-01-25 00:52:58 +01:00
|
|
|
/**
|
|
|
|
* Whether or not to ignore the nullability of this function's return type
|
|
|
|
*
|
|
|
|
* @var bool
|
|
|
|
*/
|
|
|
|
public $ignore_falsable_return = false;
|
|
|
|
|
2016-11-13 05:59:31 +01:00
|
|
|
/**
|
2017-01-02 07:07:44 +01:00
|
|
|
* @var array<int, string>
|
2016-11-13 05:59:31 +01:00
|
|
|
*/
|
|
|
|
public $suppress = [];
|
2016-12-04 01:11:30 +01:00
|
|
|
|
2018-06-22 07:13:49 +02:00
|
|
|
/**
|
|
|
|
* @var array<int, string>
|
|
|
|
*/
|
|
|
|
public $throws = [];
|
|
|
|
|
2016-12-04 01:11:30 +01:00
|
|
|
/** @var int */
|
|
|
|
public $return_type_line_number;
|
2017-02-10 02:35:17 +01:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @var array<int, array<int, string>>
|
|
|
|
*/
|
2018-06-19 19:19:34 +02:00
|
|
|
public $template_type_names = [];
|
2017-02-10 02:35:17 +01:00
|
|
|
|
|
|
|
/**
|
2018-03-17 23:05:50 +01:00
|
|
|
* @var array<int, array{template_type: string, param_name: string, line_number?: int}>
|
2017-02-10 02:35:17 +01:00
|
|
|
*/
|
|
|
|
public $template_typeofs = [];
|
2018-05-28 21:07:42 +02:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @var array<int, array{type: string, param_name: string}>
|
|
|
|
*/
|
|
|
|
public $assertions = [];
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @var array<int, array{type: string, param_name: string}>
|
|
|
|
*/
|
|
|
|
public $if_true_assertions = [];
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @var array<int, array{type: string, param_name: string}>
|
|
|
|
*/
|
|
|
|
public $if_false_assertions = [];
|
2018-07-15 23:23:17 +02:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @var array<string, array<int, string>>
|
|
|
|
*/
|
|
|
|
public $type_aliases = [];
|
2016-11-13 05:59:31 +01:00
|
|
|
}
|