Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:68924 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 50584 invoked from network); 6 Sep 2013 20:01:17 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 6 Sep 2013 20:01:17 -0000 Authentication-Results: pb1.pair.com header.from=danack@basereality.com; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=danack@basereality.com; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain basereality.com from 74.125.82.177 cause and error) X-PHP-List-Original-Sender: danack@basereality.com X-Host-Fingerprint: 74.125.82.177 mail-we0-f177.google.com Received: from [74.125.82.177] ([74.125.82.177:39428] helo=mail-we0-f177.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id AD/88-05619-C843A225 for ; Fri, 06 Sep 2013 16:01:17 -0400 Received: by mail-we0-f177.google.com with SMTP id t60so2304498wes.36 for ; Fri, 06 Sep 2013 13:01:14 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=HjsF5xmLyr4Tudk+8m67QcThSUN5nJC3z0uIlbxnjBg=; b=SpRBIwUiUfhM+QuQuFfJPn0Xp/w5l7+jUar3CFWlWvg2LL/xPt6gLPZLxvyB1s5R16 GTqJl7hUposnjncp107FU+aJFIy5Py0QmnWW/dkjI18wFm6sxBuVb3KPLrGzVhdsyWNN PkaVESo8FcZxZswAiDXr879H/QokypgE6b5IVKgshWYlM0wqV636Z7wJppElDEzRAsfF oHLYvPkRDdECebh+0kOxD0egouFkwVBPLFezbznRgGmMvpFz/qKrk9tIUzBaCwRxFTeP H9xDirtqyFd0PIkMkPGK7yfVLiIocb8D3uN/E4vpzzj6Iql8VVVOlPLw2hCUVE7MOu2u vc0Q== X-Gm-Message-State: ALoCoQnVfQuZCYmtvGc8BxUs0MHP+0odz3QFb6LBU0rxsrfVqsjARRoCkLaHHVXo7duYu/SB5F9a MIME-Version: 1.0 X-Received: by 10.194.120.68 with SMTP id la4mr3454198wjb.33.1378497674010; Fri, 06 Sep 2013 13:01:14 -0700 (PDT) Received: by 10.217.10.73 with HTTP; Fri, 6 Sep 2013 13:01:13 -0700 (PDT) X-Originating-IP: [2.96.87.110] In-Reply-To: References: Date: Fri, 6 Sep 2013 21:01:13 +0100 Message-ID: To: Adam Harvey Cc: Nikita Popov , PHP internals Content-Type: multipart/alternative; boundary=089e011600982ef25904e5bc8019 Subject: Re: [PHP-DEV] [RFC] Named parameters From: danack@basereality.com (Dan Ackroyd) --089e011600982ef25904e5bc8019 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable Hi Adam > I'd say the odds are that those sorts of users are going to be writing > code that is required to be notice/strict clean anyway =97 that's > certainly been true everywhere I've worked that's had a "modern" > codebase. Yes, so say you have a team that: * currently has a code base that is notice/strict clean * wants to move to PHP 5.x which has named parameters * have code which changes the param name in extends/implements Unless they rewrite their code, they wouldn't be able to upgrade next version of PHP without losing their strict/notice cleaness. So how would you suggest they upgrade to the version of PHP with named parameters? Also I'm not sure that having which error level is used actually changes the behaviour of the language in a meaningful way. It only suppresses a particular warning message, which can be suppressed anyway with error_reporting(0). cheers Dan On Fri, Sep 6, 2013 at 8:16 PM, Adam Harvey wrote: > On 6 September 2013 12:12, Dan Ackroyd wrote: > >> If named parameters are introduced, signature validation should includ= e > >> parameter names. Throwing a fatal error (for the interface/class > > combination) > >> would break backwards compatibility though. We could use some lower > error > >> type... > > > > Would it be possible to set the error level through an ini setting? Or > > disable it entirely? > > I've said this before, but to reiterate it: I'd be a huge -1 on > anything that involves configurable language behaviour. It's a support > nightmare, and I'm glad those days are now mostly over. > > > People who are writing new code that is aware of named parameters shoul= d > > want a fatal error for any coding mistake that violates the contract. > > I'd say the odds are that those sorts of users are going to be writing > code that is required to be notice/strict clean anyway =97 that's > certainly been true everywhere I've worked that's had a "modern" > codebase. > > Adam > --089e011600982ef25904e5bc8019--