mirror of
https://github.com/danog/psalm.git
synced 2024-11-30 04:39:00 +01:00
Fix #1701 - allow count to be called on SimpleXMLElement
This commit is contained in:
parent
4f48c6388d
commit
e31cdf3be5
@ -1533,7 +1533,7 @@ return [
|
||||
'Couchbase\WildcardSearchQuery::jsonSerialize' => ['array'],
|
||||
'Couchbase\zlibCompress' => ['string', 'data'=>'string'],
|
||||
'Couchbase\zlibDecompress' => ['string', 'data'=>'string'],
|
||||
'count' => ['int', 'var'=>'Countable|array', 'mode='=>'int'],
|
||||
'count' => ['int', 'var'=>'Countable|array|SimpleXMLElement|ResourceBundle', 'mode='=>'int'],
|
||||
'count_chars' => ['mixed', 'input'=>'string', 'mode='=>'int'],
|
||||
'Countable::count' => ['int'],
|
||||
'crack_check' => ['bool', 'dictionary'=>'', 'password'=>'string'],
|
||||
|
@ -1675,6 +1675,11 @@ class FunctionCallTest extends TestCase
|
||||
takesString($s);
|
||||
}',
|
||||
],
|
||||
'countableSimpleXmlElement' => [
|
||||
'<?php
|
||||
$xml = new SimpleXMLElement("<?xml version=\"1.0\"?><a><b></b><b></b></a>");
|
||||
echo count($xml);'
|
||||
],
|
||||
];
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user