Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:129573 X-Original-To: internals@lists.php.net Delivered-To: internals@lists.php.net Received: from php-smtp4.php.net (php-smtp4.php.net [45.112.84.5]) by lists.php.net (Postfix) with ESMTPS id 237231A00BC for ; Tue, 9 Dec 2025 12:06:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1765281993; bh=3K464vyAUUbx/TOPddmCfdJA1tHugDKlLLh9NYaWayA=; h=Date:From:To:cc:Subject:In-Reply-To:References:From; b=l7oDBZmZxx3WHQMjTYIm7jCRU/0tplZ+X2FTbIVWDxYVTFXiqj6sJoATedzjgCO2V w8XUNJB8Q4GS7eJ+CnGeH6BoK6ozTRHJKJAoe1ovmILTtTuma1R1iI+wqFTm+Fa/Hg h0nq0GUwNAaQYjEhRGudnK+oLq5OZPzT/wACwPLf4fyi18Wf/nEaZo1PGAUkgiu9FU SBH8MOTTF6T4C18zNS/whV42jUyMGXXKTSPGYh3WQtgzmjJ+duBVHQH+VCm0icIXvu fjY7ET/XWvntOY1aXZLtaW2CvGZNPKMaVNfK27Kw8ohcLybi8nArb5lIvZQ1RxdiUY 2Mvvcam3RM/YQ== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 09D27180050 for ; Tue, 9 Dec 2025 12:06:33 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on php-smtp4.php.net X-Spam-Level: *** X-Spam-Status: No, score=3.6 required=5.0 tests=BAYES_50,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,DMARC_PASS,SPF_HELO_PASS, SPF_SOFTFAIL autolearn=no autolearn_force=no version=4.0.1 X-Spam-Virus: No X-Envelope-From: Received: from xdebug.org (xdebug.org [82.113.146.227]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Tue, 9 Dec 2025 12:06:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1765281986; bh=3K464vyAUUbx/TOPddmCfdJA1tHugDKlLLh9NYaWayA=; h=Date:From:To:cc:Subject:In-Reply-To:References:From; b=gidtL8ZZovkNAsR4OKIcww1HAFQyayvWhjYIc5JW849qUQMJzTdr22pr8k2vjTClL Zjz6vkzS0fcvTjwmuA1M+4s/kdFWUQbIiezUiQz1Dce8QWvfdgJzUMrPpfhIx9/xlK ZhMymew09FgCndhe6h++XomgW9lNScxQJTejsgEonVN9eJYR6HgHXWYrfHsZMKi9qW rdJp6loVSSzLzFvTqRjisBGFtnttLk4H4Dn757C7EBxOe2hy8JENw4F0LQEVor2XuD auckEz8EmpLHHYIT16Y+Zmq5DLIw8wnWBbFbvgKHUo4qJf0k7g4GNd56URrAsICPUr kB9iGXoF6xjyQ== Received: from localhost (localhost [IPv6:::1]) by xdebug.org (Postfix) with ESMTPS id C62EE10C07D; Tue, 09 Dec 2025 12:06:26 +0000 (GMT) Date: Tue, 9 Dec 2025 12:06:26 +0000 (GMT) To: =?UTF-8?Q?M=C3=A1t=C3=A9_Kocsis?= cc: PHP Internals List Subject: Re: [PHP-DEV] [RFC] [Discussion] Followup Improvements for ext/uri In-Reply-To: Message-ID: <83238ad3-c844-4457-dfb3-11321787e022@php.net> References: Precedence: list list-help: list-unsubscribe: list-post: List-Id: x-ms-reactions: disallow MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="8323329-1445357481-1765281986=:29692" From: derick@php.net (Derick Rethans) This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --8323329-1445357481-1765281986=:29692 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: QUOTED-PRINTABLE On Mon, 1 Dec 2025, M=C3=A1t=C3=A9 Kocsis wrote: > I'd like to introduce my latest RFC that I've been working on for a=20 > while now: https://wiki.php.net/rfc/uri_followup. >=20 > It proposes 5 followup improvements for ext/uri in the following areas: > - URI Building Would it make sense to have an interface for the set*() methods? Besides=20 build(), they all seem to have the same API. > - Query Parameter Manipulation I see this adds NoDiscard: #[\NoDiscard(message: "as Uri\Rfc3986\Uri::withQueryParams() does not modif= y the object itself")] But the original methods on the classes don't have these NoDiscards, and=20 it doesn't seem that this RFC is suggesting to add them. It should at=20 least be consistent. > - Accessing Path Segments as an Array Compare: "especially considering the fact that Uri\Rfc3986\Uri internally stores=20 the path as a list of segments." And: Uri\Rfc3986\Uri::withPathSegments() =E2=80=A6 internally concatenate the in= put=20 segments separated by a / character, and then trigger=20 Uri\Rfc3986\Uri::withPath() =E2=80=A6 Why does it need to do this concattenation, and then call withPath() for=20 Rfc3986\Uri then? cheers, Derick --=20 https://derickrethans.nl | https://xdebug.org | https://dram.io Author of Xdebug. Like it? Consider supporting me: https://xdebug.org/suppo= rt mastodon: @derickr@phpc.social @xdebug@phpc.social --8323329-1445357481-1765281986=:29692--