$results = []

WBOY
WBOYOriginal
2016-06-23 13:51:381085browse

$results = [];

foreach (array_merge([$class => $class], class_parents($class)) as $class)
{
$results += trait_uses_recursive($class);
}

return array_unique($results);


$a=[]; 这是什么意思?


回复讨论(解决方案)

是个数组的意思。

$a = [];
是 $a = array(); 的简化写法,php5.4开始可用

就是 $a = array();的意思。

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn