I've been reading some code recently and I've come across a few instances where the developer would wrap parentheses around like following example.
There's this function:
foreach ((array) $middleware as $m) {
$this->middleware[] = [
'middleware' => $m,
'options' => &$options,
];
}
In the for each check there's array (array)
with parentheses around, what do these mean.
Or can someone guide me to a doc where I can read up on this matter. Thanks in advance.