Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:126344 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 qa.php.net (Postfix) with ESMTPS id 387DE1A00BC for ; Fri, 7 Feb 2025 23:19:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1738970218; bh=RsyzKGg2ItPAGU/rMU4ly2Y1fQDN4VmBUgkl4u8NdsA=; h=Date:From:To:In-Reply-To:References:Subject:From; b=KK+3jWc+NQfKIdZzZklIdTXke/a0p0THZfhGjyIv6189/Y4TnUJkQi7qrXdY/+ZxD NRCwIFZZbR5t1gQUv0lXbJm43FStdjiB/urZHqFjLaq6lWr9wNwXirJcHOUmJcSLj5 BciKjZsh/a6DN9E8uCvRmJQslusWi2S6XIiDyXwBmk+AByFIwj8nYh7yhn3eOw1RLj ydRQMdI/93HV5p32bSC6hBzjhfmWerMa5zM6HR8KJdTcqiQCQ9HuDZQ3fT0JVicO5H hFiOcCGztCnvhPmLsPXzfiP9ugo4VRHIstacaAwKkzDPhocX0cAETaVTyjwjzB+cnM 5dqlKud5O2itQ== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 81D9A180072 for ; Fri, 7 Feb 2025 23:16:56 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.0 (2022-12-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,DMARC_MISSING,RCVD_IN_DNSWL_LOW, SPF_HELO_PASS,SPF_NONE autolearn=no autolearn_force=no version=4.0.0 X-Spam-Virus: No X-Envelope-From: Received: from fhigh-b2-smtp.messagingengine.com (fhigh-b2-smtp.messagingengine.com [202.12.124.153]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Fri, 7 Feb 2025 23:16:56 +0000 (UTC) Received: from phl-compute-01.internal (phl-compute-01.phl.internal [10.202.2.41]) by mailfhigh.stl.internal (Postfix) with ESMTP id 4C0BA254010F for ; Fri, 7 Feb 2025 18:19:40 -0500 (EST) Received: from phl-imap-06 ([10.202.2.83]) by phl-compute-01.internal (MEProxy); Fri, 07 Feb 2025 18:19:40 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= garfieldtech.com; h=cc:content-transfer-encoding:content-type :content-type:date:date:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to; s=fm3; t=1738970380; x=1739056780; bh=aWSUftZFedq7iR4sEmb8D opasBj8i7JTnf3mK9rqDvI=; b=aHDah/4IOr2WgCP97viADdc5aEmmXGZulY8+9 jfz+AMtqIVIz9k1BZiEb+e9O732VB0mrnMRPbkkZHQ9Ph5jH8Jj8sDuBaiNoDi8J tfZN1T3MIMPp4xjNBT0VP8AI9bvVvD/BGC9vzvGNZgIrYO8qsH1X9OGPhQ+EOzAx 6yzByHeu/9F9uqWB7mGHvokpGqtliA4sD0Wg8JAWTO2a2MGgAEdJxY1TVjqdKZA7 vEPQb+NK70/LEatH7/JQk/NgSUhl3tL0Gbhyy9DRJ2dam2GHyNV8Nh675LSn6DbF Vxno3EVqzZFoDhZ2nuRGrc61iGN5WsT245lPHN0hAmffoACzQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :content-type:date:date:feedback-id:feedback-id:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:subject:subject:to:to:x-me-proxy:x-me-sender :x-me-sender:x-sasl-enc; s=fm3; t=1738970380; x=1739056780; bh=a WSUftZFedq7iR4sEmb8DopasBj8i7JTnf3mK9rqDvI=; b=b8ckKUu4l3AtfRhK+ N4IzPBq9msQ2stUGHYhwLVqyx+igEooiM/gaDh4ULwxCeUwiDqNMSGNVRv/w9MLM DF9UaYgSffteQcXnA2d3cJG54PkO/MEvbg+QPP6crQiWSlsDzXl8HpMZP4ixPBym AR+9M/vg1kWKPEKQkoAXDa3Gw7vF+oVjRJNwl4hqHKVwHSYS2psrdU8PlWwF0cp5 1q9ewT7bpdzbwbRPkX8h2Pk/hip3oag5bI/2mvDpYnaUIkEYJtzY2b7HX4Yzns65 q8Q5LTAH93HvORhfnSrOnaHoYXtTOzWCrVrQ1VsPjbtlfUhEVvSX7E9RwGxlU/bD dvfdg== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefvddrtddtgdeftdehlecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpggftfghnshhusghstghrihgsvgdp uffrtefokffrpgfnqfghnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivg hnthhsucdlqddutddtmdenucfjughrpefoggffhffvkfgjfhfutgfgsehtqhertdertdej necuhfhrohhmpedfnfgrrhhrhicuifgrrhhfihgvlhgufdcuoehlrghrrhihsehgrghrfh hivghlughtvggthhdrtghomheqnecuggftrfgrthhtvghrnhepheejfeevgfefudetffff vdehiedukeeifeelvedvudeigfekhedvveehffdvgeetnecuffhomhgrihhnpehgihhthh husgdrtghomhenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhr ohhmpehlrghrrhihsehgrghrfhhivghlughtvggthhdrtghomhdpnhgspghrtghpthhtoh epuddpmhhouggvpehsmhhtphhouhhtpdhrtghpthhtohepihhnthgvrhhnrghlsheslhhi shhtshdrphhhphdrnhgvth X-ME-Proxy: Feedback-ID: i8414410d:Fastmail Received: by mailuser.phl.internal (Postfix, from userid 501) id A94DD29C006F; Fri, 7 Feb 2025 18:19:39 -0500 (EST) X-Mailer: MessagingEngine.com Webmail Interface Precedence: bulk list-help: list-post: List-Id: internals.lists.php.net x-ms-reactions: disallow MIME-Version: 1.0 Date: Fri, 07 Feb 2025 17:19:18 -0600 To: "php internals" Message-ID: In-Reply-To: <040da4e2-2595-42ad-ab94-a0e87aed1a79@app.fastmail.com> References: <5a584219f120385e7e30f6d0a46cc108@bastelstu.be> <040da4e2-2595-42ad-ab94-a0e87aed1a79@app.fastmail.com> Subject: Re: [PHP-DEV] [RFC] Pipe Operator (again) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable From: larry@garfieldtech.com ("Larry Garfield") On Fri, Feb 7, 2025, at 4:54 PM, Rob Landers wrote: > Put another way, what is the order of operations for this new operator? > > For example, what is the output of > > $x ? $y |> strlen(=E2=80=A6) : $z > > $x + $y |> sqrt(=E2=80=A6) . EOL > > Etc. > > I noticed this seems to be missing from the RFC. As a new operator, I=20 > think it should be important to specify that.=20 > > =E2=80=94 Rob Pipe deliberately binds fairly low, so most other operators will happen = first. Including +, ?? and ? :, for which there are tests: https://github.com/php/php-src/pull/17118/files#diff-81789df7e324801626e= f4ef8f629cc95dceed4c09073a2b58b70c811bf776904 https://github.com/php/php-src/pull/17118/files#diff-56cbcf85bd7f68fa7a1= f837eb15dcc536576986f366976f9642ad20867c471fd https://github.com/php/php-src/pull/17118/files#diff-775c14f54cd1a27719d= 30bfab62024aeb1625bc3f3621fa0e7c16fb1c7957fdd So in the examples above, the second would add $x and $y first, then squ= are-root the result. The first, I think would probably need parens to a= void being invalid but I'd have to try it to be sure. --Larry Garfield