Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:122572 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 CD25E1AD8F6 for ; Tue, 5 Mar 2024 17:43:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1709660624; bh=vHgsPHDKQzUaRBrWaFyzvD0x0V2/b87YQqne6N3MRwM=; h=In-Reply-To:References:Date:From:To:Subject:From; b=TLfzHyotLLS3AGP5UCbpejw25IT1k56BZordQwKycyGH+TJOsSrok4XF9UnW0kk6Q y5XDO6aIL9fw4V/rLkd8BsMgkcV7yXh5v4wPKTm9hUHo9VWRUrD5Zed+QbnHD2ispc SkZtL7RspdXfGAAyMiyHaRLujKiN8pP9AkMEc1mDs5FELzlrgg8BvP3KNU6JqbxAaL GVMzCuqyboC6chzB/iKvH6bNrPczQX6f8YOL9rAkddAwV+nS2fAOyKfSyOKF6TVaXp 2dSOFCIxzd/WWWJTPP2WZXTcxLznkROXxl4MinJRllco2AZgXGSg2uybwsDeoQMgBu xsof4b3/hsAVA== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 6D4081804C7 for ; Tue, 5 Mar 2024 17:43:42 +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=-0.9 required=5.0 tests=BAYES_40,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,DMARC_MISSING,RCVD_IN_DNSWL_LOW, SPF_HELO_PASS,SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=4.0.0 X-Spam-Virus: No X-Envelope-From: Received: from wout5-smtp.messagingengine.com (wout5-smtp.messagingengine.com [64.147.123.21]) (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, 5 Mar 2024 17:43:40 +0000 (UTC) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.west.internal (Postfix) with ESMTP id 9368532001FF for ; Tue, 5 Mar 2024 12:43:27 -0500 (EST) Received: from imap50 ([10.202.2.100]) by compute1.internal (MEProxy); Tue, 05 Mar 2024 12:43:27 -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=fm1; t=1709660607; x=1709747007; bh=RHyIxJR5d+kVeTcYh1+YZ x+DmyyivGJt/O4pe93TK4k=; b=BUHuu2xBweUqOCfS9AZ0+waBV3jq0ifAsKOE9 HxTCDEnqgW+Yt0C2lE98lMQCKegBUhgIJZTQ9ifc5a8BGYpd6GQsMxeXhmjwMsdH IJDPejiH705Rbv2A+556mWunnhOAmZBP0nz0OmvW0mwhbJBkGYaIFBmvFCg+3+2w Rd7/u/9R2BIBUEroYqbtRpJiVcgq1FiNaMC0PjNfPhTO74tPSj+dgLTFL3G8Dope WpmYwmq7H3gcf6CF6H42k2IwE+9aObZ1uK00IWrXjaAM4DO6QJAaQqjKIkpq8pm7 h2RzNX9ezy2Xvf2oehD+fanu0+3mahpz+cf0FruT+G2XXLGGA== 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-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t=1709660607; x= 1709747007; bh=RHyIxJR5d+kVeTcYh1+YZx+DmyyivGJt/O4pe93TK4k=; b=f 9HZaLbge3xLM4Sdzf/Vg38yC4IU8nVS058XalgDWN834FCbsr7OTf39DEfjxHWGG EKKYodOOIqs6Dk1vT1xREUqWbZD//f4w+Fbi1x3IHjRKMNPWwBWRnHsBEOxTAey9 WLsHaWVvEpcfK0n0dHCaAc1baPCC3A2yJMHfSelih4HxYSilAX/s1zNiTjiXUoW1 d56S7XaIFGq4v2VONQwFjFW5LnaMu1eoPj1w4Z82/hAbdnJ4YjUJWz5fj0aRJ7FB ujCotzRniJuQLIVk0Dz53foY0ElJQLfDhZaUVZTUgDnID2oQchbmYdPs3nQEZOXD rj79/645+svrIw4ECsPQQ== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrheelgddutddtucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepofgfggfkjghffffhvffutgfgsehtqhertderreejnecuhfhrohhmpedfnfgr rhhrhicuifgrrhhfihgvlhgufdcuoehlrghrrhihsehgrghrfhhivghlughtvggthhdrtg homheqnecuggftrfgrthhtvghrnhephefhvdettdefgfdutefgtdetkeeiudduvedvteeu veehueelhffhheehiedthffhnecuffhomhgrihhnpehgihhthhhusgdrtghomhdpshhlvg gvphgpfhhunhgtthhiohhnpghflhhorghtpghsuhhpphhorhhtrdhmugenucevlhhushht vghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehlrghrrhihsehgrghrfh hivghlughtvggthhdrtghomh X-ME-Proxy: Feedback-ID: i8414410d:Fastmail Received: by mailuser.nyi.internal (Postfix, from userid 501) id D72401700098; Tue, 5 Mar 2024 12:43:26 -0500 (EST) X-Mailer: MessagingEngine.com Webmail Interface User-Agent: Cyrus-JMAP/3.11.0-alpha0-208-g3f1d79aedb-fm-20240301.002-g3f1d79ae Precedence: bulk list-help: list-post: List-Id: internals.lists.php.net MIME-Version: 1.0 Message-ID: In-Reply-To: References: <7d05d51f-f301-4d62-b1c0-83e6a2e0632e@bastelstu.be> Date: Tue, 05 Mar 2024 17:43:04 +0000 To: "php internals" Subject: Re: [PHP-DEV] int|float for sleep? sleep(0.1) => sleep 0.1 seconds Content-Type: text/plain;charset=utf-8 Content-Transfer-Encoding: quoted-printable From: larry@garfieldtech.com ("Larry Garfield") On Tue, Mar 5, 2024, at 1:09 PM, Hans Henrik Bergan wrote: > Voting has now been simplified to 3x no/php 8.4/php 9.0 questions. > (I actually would've preferred the original 6, would have been > unambiguous if people are supposed to checkbox only 8.4 or both 8.4 > and 9.0, and would have been easier to see the % of people who voted > only 9.0, I think. But I don't care enough about it to actually fight > for it, and multiple people requested it be reduced to 3, so let's go > with that :) ) > >>That said, thanks for making this, it's something I'd like to see in P= HP as well. > > Happy to hear it :) > > >> - Instead of using backticks, use `sleep()` for inline and > `=E2=80=A6` for multi-line snippets. This comes with syntax > highlighting and documentation links. >>(...) >> - It would help readability if you'd use additional headlines for each > of the three sub-proposals within the Proposal section. >> > > I don't want to spend too much effort on nitpicks, but if someone > volunteers to improve it, I'd be happy to add it, in which case please > send a PR to=20 > https://github.com/divinity76/stuff/blob/phprfc/2024/sleep_function_fl= oat_support.md > >> For (2) it would help if you'd explain what it means for sleep() to be > interrupted and how this can happen. I believe this is signal-handling > related, but writing it out explicitly for the folks that didn't yet > encounter it would probably make sense. > > I'm not an expert, but when researching this on Windows 10 + PHP 8.3.2, > I couldn't actually get it to return 192. (nor return anything except = 0): > - When sending a WM_CLOSE message (equivalent to `taskkill /IM > php.exe`), it was just completely ignored: PHP kept sleeping. > - When doing a TerminateProcess() call (equivalent to `taskkill /IM > php.exe /F`), PHP was just terminated, sleep never returned. > - When sending a CTRL_C_EVENT (equivalent to ctrl+C), PHP just > terminated, sleep never returned. > - When sending a CTRL_BREAK_EVENT (equivalent to ctrl+Break), PHP just > terminated, sleep never returned. > > I don't know how to make it return 192 on Windows.. Anyone know? > >>For the "Unaffected PHP Functionality" you could just spell out that a= nything that is not the sleep() function will be unaffected > > meh, someone else pointed out that the irrelevant sections could be > removed, I removed the "Unaffected PHP Functionality" section (along > with 2-3 others) > >> I'd just put a single "Do all of this in the next minor" vote there. = All >>of the suggested improvements make sense to me and the breaking changes >>are mostly theoretical. > > meh, I don't want to risk the RFC getting rejected because too many > people thought it should be done in next.major instead of next.minor, > let's keep both next.minor + next.major vote options. (You're probably > right, I predict a majority vote for next.minor for all 3, but i'll > keep the vote options just in case.) A 3 way up-down vote doesn't make sense. What happens if none of the 3 = options reaches 66%? =20 The viable options here are a single RCV vote (which we've done before),= or a single "Should we do this" vote that requires 66%, followed by a "= when should we do this" vote with 2 options, majority wins. --Larry Garfield