Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:98238 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 32571 invoked from network); 7 Feb 2017 10:39:38 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 7 Feb 2017 10:39:38 -0000 Authentication-Results: pb1.pair.com smtp.mail=me@kelunik.com; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=me@kelunik.com; sender-id=unknown Received-SPF: error (pb1.pair.com: domain kelunik.com from 81.169.146.162 cause and error) X-PHP-List-Original-Sender: me@kelunik.com X-Host-Fingerprint: 81.169.146.162 mo4-p00-ob.smtp.rzone.de Received: from [81.169.146.162] ([81.169.146.162:28220] helo=mo4-p00-ob.smtp.rzone.de) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 82/57-03389-7E3A9985 for ; Tue, 07 Feb 2017 05:39:37 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1486463972; l=3790; s=domk; d=kelunik.com; h=Content-Type:Cc:To:Subject:Date:From:References:In-Reply-To: MIME-Version; bh=ZAi23mAcGO1B1PEqJcDOL1a2NHkrlR7/gBCdTEzFCrE=; b=X2B/iEkrt1NeSosBVGYNtDwIvG8V1qn5DnvwNOKD6iDfFu5bAM+ja6lVBIoTNMHv/m srN6ZbS3wds6D2Dtpo9TYOUKnWqWkXUwYAbTF7ApF/oYCFQBYsEnrLxb0gE0njeOLym6 V6z97pA8onc/BjBN3cjpi4+0u88IWMauI4HrQ= X-RZG-AUTH: :IWkkfkWkbvHsXQGmRYmUo9mls2vWuiu+7SLDup6E67mzuoNJBqD/tmQ= X-RZG-CLASS-ID: mo00 Received: from mail-qt0-f176.google.com ([209.85.216.176]) by smtp.strato.de (RZmta 39.12 AUTH) with ESMTPSA id 608e46t17AdWBT5 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (curve secp384r1 with 384 ECDH bits, eq. 7680 bits RSA)) (Client did not present a certificate) for ; Tue, 7 Feb 2017 11:39:32 +0100 (CET) Received: by mail-qt0-f176.google.com with SMTP id w20so125435356qtb.1 for ; Tue, 07 Feb 2017 02:39:32 -0800 (PST) X-Gm-Message-State: AMke39n6jKvkWfHgbOof5631opF18lH3F0J9GBnr59RBJwcS0u/IGw2Hxzu/YuCsqZzaX2S9T8DpA960YE2lag== X-Received: by 10.200.2.8 with SMTP id k8mr12828690qtg.163.1486463972071; Tue, 07 Feb 2017 02:39:32 -0800 (PST) MIME-Version: 1.0 Received: by 10.12.144.132 with HTTP; Tue, 7 Feb 2017 02:39:31 -0800 (PST) In-Reply-To: <04295b76-3e0d-5ea3-7b4e-d07a15db4243@fleshgrinder.com> References: <459c6bef-8936-634a-9520-dbd65c35b7c7@fleshgrinder.com> <04295b76-3e0d-5ea3-7b4e-d07a15db4243@fleshgrinder.com> Date: Tue, 7 Feb 2017 11:39:31 +0100 X-Gmail-Original-Message-ID: Message-ID: To: PHP Internals Cc: Nikita Popov Content-Type: multipart/alternative; boundary=f403045e72d206e77c0547ee5d1e Subject: Re: [PHP-DEV] Namespaces in Core From: me@kelunik.com (Niklas Keller) --f403045e72d206e77c0547ee5d1e Content-Type: text/plain; charset=UTF-8 > > I thought about this too. I hope you understood that the main reasoning > for me to choose a well known namespace prefix is related to > auto-loading and when to trigger it. The lack of function and constant > auto-loading is a pain and having well known prefixes could solve the > issue since we would never require to even look at the auto-loader if > the namespace starts with php. > > Obviously this could be solved for C extensions by allowing them to > register another prefix that should not be auto-loaded: Sodium, MongoDB, > ... > > Another solution could be to use pecl as their prefix. Although this > couples it to the packaging system which might not be so nice. > > Any name that is tied to a company name or something else that makes > things impossible for users to claim (Oracle, MongoDB, ...) is not a > problem. In case of sodium that would probably be Paragon but Sodium > might be fine too. > > I am not the judge here, the only thing I want is to ensure that this > does not go unseen and that the potential of breaking something is real > if we choose a random route like some others do. Not saying that we > cannot do it, big ecosystems live without problems doing the same. > However, it should be a very conscious choice and none that is taken > lightly: meaning rules! I don't see this as a potential problem. Autoloadeds are (1) not triggered for already loaded symbols and (2) and more importantly, autoloaders usually use a list of prefixes to load, so a whitelist, not a blacklist. Regards, Niklas --f403045e72d206e77c0547ee5d1e--