public function withFragment(string $fragment): Uri
    {
        if ($fragment === $this->fragment) {
            return clone $this;
        }

        $fragment = $this->validateFragment($fragment);

        $new = clone $this;

        $new->fragment = $fragment;

        return $new;
    }