Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:117688 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 86690 invoked from network); 7 May 2022 16:01:07 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 7 May 2022 16:01:07 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id CEC9018005D for ; Sat, 7 May 2022 10:39:06 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-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,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS, SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS29838 64.147.123.0/24 X-Spam-Virus: No X-Envelope-From: Received: from wout1-smtp.messagingengine.com (wout1-smtp.messagingengine.com [64.147.123.24]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Sat, 7 May 2022 10:39:06 -0700 (PDT) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.west.internal (Postfix) with ESMTP id D441232007CF for ; Sat, 7 May 2022 13:39:03 -0400 (EDT) Received: from imap43 ([10.202.2.93]) by compute1.internal (MEProxy); Sat, 07 May 2022 13:39:03 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= garfieldtech.com; h=cc:content-type:date:date:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to; s=fm1; t=1651945143; x= 1652031543; bh=+VDVqwbqFTuuCwS6HxEh3MNG9VfRFA3sBdGKO3WwEFw=; b=H 2nRJI4dnSoGcT9Cl6o4uqcmTaEiZJuT0bL+Z0R5ggnw9fz5zFEMD/vLSEowwMgrg qJViH5Ku9t45eMSo9N3siXqw1p+AG2mkYluzWaw0I4V7EJ5PJsKKiAORCOXWjCmw CuDseto3NQgls5nXLmX4Jexmw0I4bn4/NmhdSZB3527zkg1VyQGr09ZzcheWna2l aohaqtVN3jFsQ/c/vImL6bK6hWWQ4alGg+UpCDihhKLNVGUtHUa3SXNO9odTK/sJ QFtzz5As2j972KY9lbos5Ka3toZyE3cj60yt/3RJ38KwVXhq7DJHuNK1Oo0jOIkZ d3RXiy0I41w8ikjgeM3nQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:date:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t=1651945143; x= 1652031543; bh=+VDVqwbqFTuuCwS6HxEh3MNG9VfRFA3sBdGKO3WwEFw=; b=x utyUxUDDnq/zogKzpvCpV6tfJoWomnlXQgkVles4mzVUx84QYc89SU+lbewuER+1 dtl7kHJegffsr8ItJgUzF+N6cA3xkr9e1w/J2FxdndcIxxp1BHXeAukdGDbBIscM a0k2EmTCciPTK7BTPrMg2rg5ZumFrAZ+/LhVv61j4on6D94iLeDbCtL1Q/Z49zxx kDeftB+p2DHq07eG/c6tqqHSzv1HgGQZfDelzpzI3xxS2sZfIMLh+gBNVzAkJ7Eu 0OL6BfN13FW9CJ+Cajc0LWPbwzbpQvi279vI8C9OYRXXZGMKUQ/6Hw8XCT00con7 WZVdv95EXpfos70UCWjaQ== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvfedrfeehgdduudeiucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepofgfggfkjghffffhvffutgesthdtredtreertdenucfhrhhomhepfdfnrghr rhihucfirghrfhhivghlugdfuceolhgrrhhrhiesghgrrhhfihgvlhguthgvtghhrdgtoh hmqeenucggtffrrghtthgvrhhnpeekteelheffgeefvddufeeujeekhfdvtdeuuedvveet ieevheeludegjeduhffhteenucffohhmrghinhepghhithhhuhgsrdgtohhmnecuvehluh hsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomheplhgrrhhrhiesghgr rhhfihgvlhguthgvtghhrdgtohhm X-ME-Proxy: Received: by mailuser.nyi.internal (Postfix, from userid 501) id 241B82D4005E; Sat, 7 May 2022 13:39:03 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface User-Agent: Cyrus-JMAP/3.7.0-alpha0-591-gfe6c3a2700-fm-20220427.001-gfe6c3a27 Mime-Version: 1.0 Message-ID: <0eed8cd6-cf23-4eeb-ab3e-a851d0266081@www.fastmail.com> In-Reply-To: References: Date: Sat, 07 May 2022 12:38:42 -0500 To: "php internals" Content-Type: text/plain Subject: Re: [PHP-DEV] Possible improvements to the Reflection functionality From: larry@garfieldtech.com ("Larry Garfield") On Thu, May 5, 2022, at 12:04 PM, Ollie Read wrote: > Hello all, > > I've been spending a lot of time in the world of PHP reflection lately, > which has led me to create PRs for the documentation, a bug for closure > attributes, and even a new method on ReflectionMethod. I've also > compiled a list of suggestions for various additions and improvements > to some parts of reflection. > > You can find it here: > https://gist.github.com/ollieread/34c878bf120ee70f9d2a869cb7a242d1 > > I'm looking for some feedback on the various elements and some > guidance, if any have merit, as to whether they're going to require any > sort of RFC. I'm also happy to create PRs for some of the features, if > not all, though I think there are definitely some beyond my current > knowledge. I would also be interested in hearing from anyone who also > has other suggestions that could be added to this. > > Apologies if I'm missing something, or I could have done something > better, this is my first interaction with this mailing list, so I am > also happy to receive any feedback about the best approaches and ways > to handle things, if necessary. Greetings. I've also been doing a lot of work with Reflection lately as part of https://github.com/Crell/AttributeUtils . I agree with and support almost all of these additions. (I'm no entirely convinced by getNumberOfAttributes(), but I don't really see a harm in it.) There was another short thread on the list back in February?, I think, about some improvements to reflection. We desperately need a few more well-placed interfaces and stubs for things like attributes, and even getName(). My C-fu is paltry if I'm being polite, but I'm happy to help with process and RFC writing/documentation. The Reflection API is badly in need of some love. In practice, I think most of these would require RFCs. The question is whether they're better as a bunch of stand-alone RFCs or one big "clean up Reflection" RFC or a series of "clustered" RFCs. I'm not sure what's most palatable to folks these days. --Larry Garfield