private function completeArgumentTypeFromTypeHint(Argument $arg, ReflectionMethod $method, ReflectionParameter $param, DocBlockReader $docBlock): void
    {
        if (!$arg->getTypeInstance()) {
            $typeDeclaration = $docBlock->getParameterType($param);
            $this->throwIfArray($param, $typeDeclaration);
            $arg->setTypeInstance($this->getTypeFromPhpDeclaration($method, $typeDeclaration, true));
        }

        $type = $param->getType();
        if (!$arg->getTypeInstance() && $type) {
            $this->throwIfArray($param, (string) $type);
            $arg->setTypeInstance($this->reflectionTypeToType($type, true));
        }

        $this->nonNullIfHasDefault($arg);

        $this->throwIfNotInputType($param, $arg);
    }