It seems that the (array) cast operation is not recognised, e.g. in:
$tags = (array) $tags;
The scope of array is marked as constant.other.php, while it should be marked as storage.type.php like when using (int), (object), etc.
When type hinting in a function definition, array is recognized correctly though.
Add support for array, binary and unset typecasts (closed by 5a99435)
Thanks for the report. I've pushed support for this, as well as binary and unset casts, which were also missing. Thanks!