Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:61883 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 91460 invoked from network); 30 Jul 2012 19:26:32 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 30 Jul 2012 19:26:32 -0000 Authentication-Results: pb1.pair.com smtp.mail=wfitch@meetme.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=wfitch@meetme.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain meetme.com designates 74.125.149.141 as permitted sender) X-PHP-List-Original-Sender: wfitch@meetme.com X-Host-Fingerprint: 74.125.149.141 na3sys009aog128.obsmtp.com Linux 2.5 (sometimes 2.4) (4) Received: from [74.125.149.141] ([74.125.149.141:51292] helo=na3sys009aog128.obsmtp.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 6A/D4-00342-7EFD6105 for ; Mon, 30 Jul 2012 15:26:32 -0400 Received: from mail-yw0-f49.google.com ([209.85.213.49]) (using TLSv1) by na3sys009aob128.postini.com ([74.125.148.12]) with SMTP ID DSNKUBbf5FVjZE0DDd6oxH0H6K6k+Ml90L+u@postini.com; Mon, 30 Jul 2012 12:26:31 PDT Received: by yhjj52 with SMTP id j52so5363364yhj.36 for ; Mon, 30 Jul 2012 12:26:27 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:sender:x-originating-ip:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :x-gm-message-state; bh=Gy4pPQsqsmNVn08pjp6Q0SnwqiNdZAPw15WB4ZpCXR8=; b=Wnicfdty4VT5jJAN0iJL570GV/MgrA/vYN27AdutKY/ejox6egAxQagHzmsm2GSgKR +IRiFlrwyPLya7OJF73OWSOz2u3BHc2nlO1VAiwVEjAt/lOb3lS+PYFq7aAWJ4TCJMXC 0xh732hKCn+BGHmrdJDA3TPGPfK/yiayT+346DDZKmSpOb+LNYoLd/6qXFhQLP8HMytJ PB8r/VdW2R7it86+jdhwNpJ6cLZD9yczSWlfZJHXEy6HHZds2oF0KFiF3MrrfIBok2yd Lw7SUkhyCYQhCMeagdiQ373PcK9SISuP/bQZmb8M09ZdQfWMyWl6+iql3rT+MLn9uZQp NniA== MIME-Version: 1.0 Received: by 10.60.154.232 with SMTP id vr8mr19019373oeb.30.1343676387430; Mon, 30 Jul 2012 12:26:27 -0700 (PDT) Sender: wfitch@meetme.com Received: by 10.60.1.195 with HTTP; Mon, 30 Jul 2012 12:26:27 -0700 (PDT) X-Originating-IP: [68.64.144.221] In-Reply-To: <1343675518.12438.84.camel@inspiron> References: <1343675518.12438.84.camel@inspiron> Date: Mon, 30 Jul 2012 15:26:27 -0400 X-Google-Sender-Auth: razL_48u_UubkGZRiH4fFjtGibM Message-ID: To: Todd Ruth Cc: "internals@lists.php.net" Content-Type: multipart/alternative; boundary=bcaec55245ecc411f904c61109c8 X-Gm-Message-State: ALoCoQlNIBsnY7cw3YKj/7IJ5eegqRtu88d1PTTg2JIb4J3G8AU1aEwWsh5WMKTgIP4Klk1DuwOO Subject: Re: [PHP-DEV] [RFC] Remove calls with incompatible Context From: willfitch@php.net (Will Fitch) --bcaec55245ecc411f904c61109c8 Content-Type: text/plain; charset=ISO-8859-1 On Mon, Jul 30, 2012 at 3:11 PM, Todd Ruth wrote: > On Mon, 2012-07-30 at 19:31 +0200, Gustavo Lopes wrote: > > https://wiki.php.net/rfc/incompat_ctx > > > > An RFC for deprecating and removing $this from incompatible context. > > > > Comments are welcome. > > > > -- > > Gustavo Lopes > > I'm just a user, but I'd like to beg that the feature not be > removed, at least not without having an ini setting for at least > a couple of years. As the RFC states, "This feature can, however, > be used to implement trait-like behavior, and I'm sure someone > somewhere did such a thing." I know in our company's code, such > uses were frequent. I believe they are still common. Refactoring > often doesn't fit the schedule. I doubt we're unusual in allowing > classes to do more than they should instead of separating code > off into a trait or making other high level changes. Note that > traits have only been available since March 1, 2012 (php 5.4.0). > I don't think axing register globals is very relevant. Perhaps after > traits have been available for several years the comparison would > be better. With register globals, a good alternative (the $_ > variables) have been around for many years. With traits, a good > alternative has been around for a few months. I think the point > of mentioning register globals is just to say "We've made huge > BC breaks before." That doesn't make it less painful. Software evolution at this level will always have some aches and pains for someone. This is a feature that has been discouraged (E_STRICT) for a very long time, and, as pointed out in the RFC, is around only to be compatible with PHP 4. This should've been nixed with the death of PHP 4 IMO. If we waited around for everyone to update their codebase before deprecating/removing features, it would never happen. The point of deprecation is to give a final warning that a feature is going to be removed in a future release. This should be your company's indication to make the necessary changes. That said, the length of deprecation is up in the air. I'm not sure that removing in the release immediately after deprecation is the right route, but deprecating this in the next release *should* happen. > Off-topic, but to show a potentially higher priority... > If you want to get rid of class related WTF, please put > get_class() back to the way it used to be. Right now, calling > get_class() with a variable that is null is the same as calling > get_class with no arguments. I can imagine why that might be > convenient for the implementation, but it is terribly confusing. > > Thanks for listening. > > - Todd > > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > > --bcaec55245ecc411f904c61109c8--