Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:130696 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 D1B5E1A00BC for ; Sat, 25 Apr 2026 22:04:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1777154691; bh=/cxoMtpe4tCM9v643m33EI+jzCoygI5BMU/W7jSqUXU=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=H1qIP5tW3w5yPQ6yjUTfMbK4aTGnls+0N+dd10onEvqHzOhztpJVaMxIe2H5dCdzV qGk5leFzBEPJTO2wTtFWO7M7w+SPKeDS7aOhDhyapqNBBboP+acMUxXHkG5V1/ZQ4q 3syA/Em0L4p73av69OuMnhBUBoAUwjdP4/U/XiC3NTsq5ShNh/gqJi6Is3iDb7NJDs 4DQdCYW4LtBl1EGOoN4s9+bqBJA5N2540LrM0IyDI2lLUah/NE5DgqkAiU/9sKc9UF wAhFFDsPHuUErHme/J6HHG9rLOtt1u4uhKJTn7kf5KNvFQBrhSSojsqlJRNhxTIJxF OiehTPXcPPJDw== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id D3DEF180068 for ; Sat, 25 Apr 2026 22:04:50 +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=2.0 required=5.0 tests=BAYES_50,DMARC_NONE, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS, HTML_MESSAGE,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL, SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=4.0.1 X-Spam-Virus: No X-Envelope-From: Received: from mail-oo1-f51.google.com (mail-oo1-f51.google.com [209.85.161.51]) (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 ; Sat, 25 Apr 2026 22:04:50 +0000 (UTC) Received: by mail-oo1-f51.google.com with SMTP id 006d021491bc7-6948da50eb5so3259562eaf.1 for ; Sat, 25 Apr 2026 15:04:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1777154685; cv=none; d=google.com; s=arc-20240605; b=ejpGyyGfBSNFiTRprsmfD80gS/94wyTN3rQYHsCi4NRwlwok9mc+P0pD/EdAcuhNfR NzAgHwEyTtaMPKqDFrIW56+bTYeGpDs3gkB1iLeC36zYHCy350h33gi3Ra309BvC1JRC UViKK5hbO3cwZQhdpOqFYVwu02FNonBpNUv6bxGTH9BtMJqcWoMVp6oePJ84J+efoyWT TMLJdkLYc5yS/+lchGCm89cvsc2nEma5FI5ViLEFeRPPjfiRaaUEPc1s8VeIr/Hm8ju/ etWy/SxJDlORYuhRFJsmP0ECt/EGooN8eK3fZH4GgYYc3h5MVSfSoTQW7cjgth+H0F8y jV4g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version; bh=/cxoMtpe4tCM9v643m33EI+jzCoygI5BMU/W7jSqUXU=; fh=jEt2AjRw7yo7C0cJJPEFOBfwq5Ujbc1t0glDrJHMrmw=; b=ErGXAMLQ4bM6/932L/+dhtIuPHzoqUWPXAySvinCv/RXhFoN5i2HqbX4ZEj4rkVS+/ PsaDSBLyBlI82vhNuMdAggNvi7iUUufx0N11nu8uwiBtO7lTF52wCZ8pYJP9azZinQ+e cDioiaqjoVhhdx9rjs5U2+q8kDYPvRf+G9cX7yOvWrEujWpQq+aBWx+McPSLvcZ/dJwx UG1Qs1tEAc/2YHdX+53ywENmnZZ92arL+GJTj/06eLIv+pfZK3pvOy9o5J0pcGothC9P Lvg5EvCI6BzOOKh2J01eJ2g00wchnPK0n77yfZ2fnK/FT2npGkr524xk7HEdqFPzCpHV uTog==; darn=lists.php.net ARC-Authentication-Results: i=1; mx.google.com; arc=none X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777154685; x=1777759485; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=/cxoMtpe4tCM9v643m33EI+jzCoygI5BMU/W7jSqUXU=; b=L1+gamH2rQM2ocCpPVyHZ8HTbFo+ZsZN4ywLkRAYeitaWAR2LJqzqfM61TRiQKL7Yd 2E/F4cBOtA/L/W+mD92op6mvU52arVKxhLUkV3/qELf0QiTT3hHuR8h7rNjv1CNAkZgm JjqMkD1mKzu2iB1zY+Fj+jXBoq1Sc1O2qQiR2rygD+DrE3yjpyrAyxnQo84roshGDvju +7MqElHnskd7Hbw6lEPe7cHw5c/RAi0HG8p2Pgbk/EnXi6Q8zDgbKXAgJmnu5LC8skRb VBEqkAMjwthOjGtlLNBOMXAZ2LJau3RGG6fWyv350ovgmAdYepd6WEnLiklTLpum+Iv3 tKSQ== X-Forwarded-Encrypted: i=1; AFNElJ9odzq/zHsQB491tcX/rbSXHUBgtGM34hyVn7zmoIAv3fIUo9TnctRS3/fX2cIGvT/xTrILza8Lyos=@lists.php.net X-Gm-Message-State: AOJu0YzL1jtVEisKQV4f6ji12TJA3SHT0Xpb5ewx5ub5sOLW+IVtaQb2 m77TLutknEKbaXhbL5W8CzBY8EG5o+YsNxPBQd6gDhdejg0IbsTGNaiybnlxVgLt6s5Uz+3IVjQ kOVXzHhlZ4iLGxhLErgsQ+sxbQhS4hI0= X-Gm-Gg: AeBDieteIpxKFLCNQeiecY9GOTwov6GyF6p77MFQdGvZaOoMA+QQqtCv/a73Xb2AVAm p1BAVTqSNqUXTeSjkcMJLkaZXSH/wIuPeLg02NoXkyy+MKBMo/ZqrcaToi5pUGXKGMkE24DXKyJ F1FNw/Ky5fn5YDfdnQcAN01vFWqrsAn1/vscp/1ZkL+Agg3jn3kfAbCHLgho0iM5pe9ocDAIk00 Qvc7dzZWO3tdcRyfIHG/7DC8c+2JW527Y18+6Z1iCxmwNikVgjfSAkB051y46yn0UINHQA4DKkl tvrzY4cM4V7fshqBZA== X-Received: by 2002:a05:6820:620:b0:694:a30c:24fc with SMTP id 006d021491bc7-694a30c285fmr9327448eaf.7.1777154684972; Sat, 25 Apr 2026 15:04:44 -0700 (PDT) Precedence: list list-help: list-unsubscribe: list-post: List-Id: x-ms-reactions: disallow MIME-Version: 1.0 References: <126fb4b28fde5cb46753d22edd17ab01@bastelstu.be> In-Reply-To: <126fb4b28fde5cb46753d22edd17ab01@bastelstu.be> Date: Sun, 26 Apr 2026 00:04:33 +0200 X-Gm-Features: AQROBzAAL4cw0005eNE0eETEt2x8WQmnmS03LtTlmF8Mo0xhCyRa0PVXZODFYUQ Message-ID: Subject: Re: [PHP-DEV] Re: [RFC] Polling API To: =?UTF-8?Q?Tim_D=C3=BCsterhus?= Cc: Valentin Udaltsov , PHP internals list Content-Type: multipart/alternative; boundary="000000000000b571300650501100" From: bukka@php.net (Jakub Zelenka) --000000000000b571300650501100 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Thu, Apr 2, 2026 at 10:15=E2=80=AFPM Tim D=C3=BCsterhus wrote: > Hi > > Am 2026-03-31 15:23, schrieb Jakub Zelenka: > > There is actually no internal API for hooks so it would require using > > object handlers (which is from the user space point of view just > > __get). It > > means no stubs declaration either. We also don't have an internal > > policy > > where to use hooks and where methods. So there are still lots of > > blockers > > to start using it in core. > > While I agree with the conclusion that using hooks internally is > complicated and there is no real policy there, Valentin was actually > making a good point: We could use regular `readonly` properties for > those cases where we're just exposing a =E2=80=9Cconstructor parameter=E2= =80=9D. > Specifically: > > - Context::getBackend() -> public readonly Backend $backend; > - Watcher::getHandle() -> public readonly Handle $handle; > > Potentially Watcher::$data could also be a regular (non-readonly) > property, or does `modifyData()` contain additional logic that is not > just =E2=80=9Cstore the value somewhere=E2=80=9D? > I tried to convert few but it resulted in quite ugly inconsistent mess. Some of those need back calls to backend so they are really not ideal for this. So I will stick with the current getters as the API is a bit nicer with them IMO. Kind regards, Jakub --000000000000b571300650501100 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
On Thu, Apr 2, 2026 at 10:15=E2=80=AFPM T= im D=C3=BCsterhus <tim@bastelstu.be<= /a>> wrote:
--000000000000b571300650501100--