Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:110230 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 62440 invoked from network); 21 May 2020 10:31:17 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 21 May 2020 10:31:17 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id ACD69180211 for ; Thu, 21 May 2020 02:10:09 -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=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS36024 206.123.114.0/23 X-Spam-Virus: No X-Envelope-From: Received: from mail1.25mail.st (mail1.25mail.st [206.123.115.54]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Thu, 21 May 2020 02:10:08 -0700 (PDT) Received: from [10.0.1.28] (unknown [49.48.242.27]) by mail1.25mail.st (Postfix) with ESMTPSA id A5521604FA; Thu, 21 May 2020 09:10:00 +0000 (UTC) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (1.0) Date: Thu, 21 May 2020 16:09:57 +0700 Message-ID: <883BA843-77D6-41D4-A6DF-D930E5398151@koalephant.com> References: Cc: PHP internals In-Reply-To: To: Dan Ackroyd X-Mailer: iPhone Mail (17E262) Subject: Re: [PHP-DEV] Draft RFC callable types + callable type/function autoloading From: php-lists@koalephant.com (Stephen Reay) > On 20 May 2020, at 20:07, Dan Ackroyd wrote: >=20 > =EF=BB=BFHi internals, >=20 > A while ago, I spent some time thinking about callables, and how they > are not very consistent, which makes people sad: > https://wiki.php.net/rfc/consistent_callables >=20 > The reason I didn't pursue that RFC is that although tidying up PHP > core to be more consistent would be nice, it would be a large amount > of work, that wouldn't dramatically improve the developer experience > when programming in PHP. In fact it would mostly just break otherwise > working code. >=20 > What would be better would be an RFC to make callables be more useful, > specifically by allowing you to define the parameter and return types > for them. Making it possible to autoload those types would be > required, and function autoloading is also a feature that has been > desired for a while. >=20 > So here are two draft RFCs: >=20 > Callable types > https://github.com/Danack/FunctionTypes/blob/master/1_callable_type_rfc.md= >=20 > Function + callable type autoloading > https://github.com/Danack/FunctionTypes/blob/master/2_autoloading_part_2.m= d >=20 > I'll leave them on github for the moment, as it is easier to do PRs > and track issues there but I wanted to gather initial feedback before > getting closer to the RFC cutoff date. >=20 > I'll move them to the wiki and formally submit them for discussion > when the implementation is closer to being done. >=20 > cheers > Dan > Ack >=20 > --=20 > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php >=20 Hi Dan, =46rom a userland perspective I like both of these, a lot. I have a question though, and i wasn=E2=80=99t sure if you=E2=80=99d rather d= iscuss particular points here on in a GH issue. Would the changes to spl_autoload_* impact on the built in autoload implemen= tation, spl_autoload?=20 Cheers Stephen=20