code: public function arguments(\ReflectionFunctionAbstract $reflector, $parameters = array())
      {
          $arguments = array();
  
          foreach ($reflector->getParameters() as $key => $parameter) {
              $argument = $this->argument($parameter);
  
              $name = $parameter->getName();
  
              $arguments[$key] = $argument ?: $parameters[$name];
          }
  
          return $arguments;
      }
docs: Resolves the specified parameters from a container.
  
  @param  \ReflectionFunctionAbstract $reflector
  @param  array                       $parameters
  @return array