1
0
mirror of https://github.com/danog/psalm.git synced 2024-12-15 10:57:08 +01:00
psalm/src/Psalm/Internal/Analyzer/Statements/Expression/ArrayCreationInfo.php
AndrolGenhald d4590711d6
Fix object-like array keys when combining string and automatic keys (fixes #5427). (#5428)
* Fix object-like array keys (fixes #5427).

* Fix incorrect return types for tests.

* Fix false positive list with literal int key.
2021-03-19 21:44:44 -04:00

53 lines
858 B
PHP

<?php
namespace Psalm\Internal\Analyzer\Statements\Expression;
use Psalm\Type;
class ArrayCreationInfo
{
/**
* @var list<Type\Atomic>
*/
public $item_key_atomic_types = [];
/**
* @var list<Type\Atomic>
*/
public $item_value_atomic_types = [];
/**
* @var array<int|string, Type\Union>
*/
public $property_types = [];
/**
* @var array<string, true>
*/
public $class_strings = [];
/**
* @var bool
*/
public $can_create_objectlike = true;
/**
* @var array<int|string, true>
*/
public $array_keys = [];
/**
* @var int
*/
public $int_offset = 0;
/**
* @var bool
*/
public $all_list = true;
/**
* @var array<string, \Psalm\Internal\DataFlow\DataFlowNode>
*/
public $parent_taint_nodes = [];
}