private function repackageCallWithNewArguments(Call $call, array $newArguments)
    {
        if ($call instanceof DefinitionCall) {
            return $this->repackageDefinitionCall($call, $newArguments);
        }

        if ($call instanceof TransformationCall) {
            return $this->repackageTransformationCall($call, $newArguments);
        }

        throw new UnsupportedCallException(
            sprintf(
                'ServicesResolver can not filter `%s` call.',
                get_class($call)
            ), $call
        );
    }