예제 #1
0
 /**
  * Returns if the parameter is fully reassigned anywhere in the function.
  *
  * @param \Pharborist\Functions\ParameterNode $parameter
  *  The parameter to check.
  *
  * @return boolean
  */
 protected function isReassigned(ParameterNode $parameter)
 {
     return (bool) $parameter->getFunction()->find(Filter::isInstanceOf('\\Pharborist\\Variables\\VariableNode'))->filter(function (VariableNode $variable) use($parameter) {
         return $variable->getName() == $parameter->getName();
     })->filter($this->isAssigned)->count();
 }