Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:83658 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 71595 invoked from network); 24 Feb 2015 12:29:55 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 24 Feb 2015 12:29:55 -0000 Authentication-Results: pb1.pair.com smtp.mail=yohgaki@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=yohgaki@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.192.41 as permitted sender) X-PHP-List-Original-Sender: yohgaki@gmail.com X-Host-Fingerprint: 209.85.192.41 mail-qg0-f41.google.com Received: from [209.85.192.41] ([209.85.192.41:48088] helo=mail-qg0-f41.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id AC/D5-37184-1CE6CE45 for ; Tue, 24 Feb 2015 07:29:54 -0500 Received: by mail-qg0-f41.google.com with SMTP id i50so29468718qgf.0 for ; Tue, 24 Feb 2015 04:29:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc:content-type; bh=h6tpvPu0gcrn5xWBKbpU125LkUujE3ibUw2Tf7MMlA0=; b=0oyYWsSNj5s6WYWzAuxM+38xD3X9qVksJXkqNHXjESj+HTbTq+g/zB/QnOUiRHBjYz LiYDGhRZ3vBkEkOvRQMqisKTdN2TsEp5k1lR+js6yn8dKroW7BWenVo226yTayx1Pxts 60tqxB8a2oD/sYPlvMmfv9Ry+Ljlt168OAoQESiaVK5JFum8T5eyJCmelrcAlF3BNtG2 +tJT0g5Gcz+4MyopL30K8eRp/HQTt9jLhKt27Sde41YOlDkkyAy3CJx7e8QfF4o6d/62 /oJtwuTCB6l1stGEuSr+Nwew66ckZ2Bqn6E2ASc2Oa9JogRMXBmMmHP81Y8x/p26uiSO BoeA== X-Received: by 10.140.39.179 with SMTP id v48mr34386093qgv.77.1424780989666; Tue, 24 Feb 2015 04:29:49 -0800 (PST) MIME-Version: 1.0 Sender: yohgaki@gmail.com Received: by 10.229.198.8 with HTTP; Tue, 24 Feb 2015 04:29:08 -0800 (PST) In-Reply-To: <54EC5AD9.3040505@birkholz.biz> References: <54EC5AD9.3040505@birkholz.biz> Date: Tue, 24 Feb 2015 21:29:08 +0900 X-Google-Sender-Auth: 9JwQNfopTvPm3aehicv5o_wvHF8 Message-ID: To: Dennis Birkholz Cc: "internals@lists.php.net" Content-Type: multipart/alternative; boundary=001a11c131f6c59c21050fd4acf8 Subject: Re: [PHP-DEV] [VOTE] Exceptions in the engine From: yohgaki@ohgaki.net (Yasuo Ohgaki) --001a11c131f6c59c21050fd4acf8 Content-Type: text/plain; charset=UTF-8 Hi all, On Tue, Feb 24, 2015 at 8:04 PM, Dennis Birkholz wrote: > Am 23.02.2015 um 19:15 schrieb Nikita Popov: > > A second vote will decide whether to use a BaseException based > inheritance > > hierarchy. This vote uses a simple majority. > > I like this RFC and hope it passes. I am a little concerned about > littering the global namespace. It would be preferable to have a single > namespace that is reserved for all build in classes (like \PHP) that > contains all classes like exceptions. The name BaseException seems to be > a very common one: > https://github.com/search?l=php&q=baseexception&type=Code finds about > 14k matches, so this may be a huge BC break if the actual class name is > not changed. > It seems AbstractException is better choice for BC. https://github.com/search?l=php&q=abstractexception&ref=searchresults&type=Code There are 661 matches, but most of them are using namespace unlike BaseException. Someone proposed to use namespace for all PHP functions/classes and clean global namespace up. This gives us flexibility also. e.g Providing compatibility to older functions/classes to mitigate BC impact. Use of namespace is BC by itself, but it may be better to consider namespace use for internal features. We don't have much time, so it may be for PHP8... Regards, -- Yasuo Ohgaki yohgaki@ohgaki.net --001a11c131f6c59c21050fd4acf8--