Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:85868 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 67696 invoked from network); 19 Apr 2015 13:33:36 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 19 Apr 2015 13:33:36 -0000 Authentication-Results: pb1.pair.com smtp.mail=francois@php.net; spf=unknown; sender-id=unknown Authentication-Results: pb1.pair.com header.from=francois@php.net; sender-id=unknown Received-SPF: unknown (pb1.pair.com: domain php.net does not designate 212.27.42.2 as permitted sender) X-PHP-List-Original-Sender: francois@php.net X-Host-Fingerprint: 212.27.42.2 smtp2-g21.free.fr Received: from [212.27.42.2] ([212.27.42.2:24575] helo=smtp2-g21.free.fr) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 06/C0-57547-EAEA3355 for ; Sun, 19 Apr 2015 09:33:34 -0400 Received: from moorea (unknown [82.240.16.115]) by smtp2-g21.free.fr (Postfix) with ESMTP id 0E16D4B008E; Sun, 19 Apr 2015 15:30:46 +0200 (CEST) Reply-To: To: "'georges'" , "'PHP Internals'" References: In-Reply-To: Date: Sun, 19 Apr 2015 15:33:30 +0200 Message-ID: <008901d07aa5$6d1af4a0$4750dde0$@php.net> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Outlook 14.0 Thread-Index: AQGzXfVGvoehXzJETz9/z2ZvJFIwNp2Oi9lw Content-Language: fr X-Antivirus: avast! (VPS 150419-0, 19/04/2015), Outbound message X-Antivirus-Status: Clean Subject: RE: [PHP-DEV] RFC: spl_autoload_register() should provide kind of entity to load From: francois@php.net (=?utf-8?Q?Fran=C3=A7ois_Laupretre?=) > De : georges [mailto:geolim4@gmail.com] > > Currently spl_autoload_register() pass the name of the class entity to = the > first *Callable* argument=E2=80=8B, but there is now way (as i far i = know) to know > what kind of entity we're looking for. > -Class ? > -Interface ? > -Trait? As others already said, classes, interfaces, and trait names share the = same table, and there are a lot of places where you cannot determine the = type you're looking for when autoloading a symbol. However, we'll need to provide a type when we extend autoloading to = functions and constants, if we do it someday. Regards Fran=C3=A7ois