Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:81852 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 37066 invoked from network); 5 Feb 2015 01:08:23 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 5 Feb 2015 01:08:23 -0000 Authentication-Results: pb1.pair.com smtp.mail=ajf@ajf.me; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=ajf@ajf.me; sender-id=pass Received-SPF: pass (pb1.pair.com: domain ajf.me designates 192.64.116.208 as permitted sender) X-PHP-List-Original-Sender: ajf@ajf.me X-Host-Fingerprint: 192.64.116.208 imap2-3.ox.privateemail.com Received: from [192.64.116.208] ([192.64.116.208:42524] helo=imap2-3.ox.privateemail.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id A7/F0-40930-382C2D45 for ; Wed, 04 Feb 2015 20:08:20 -0500 Received: from localhost (localhost [127.0.0.1]) by mail.privateemail.com (Postfix) with ESMTP id 364218C007D; Wed, 4 Feb 2015 20:08:17 -0500 (EST) X-Virus-Scanned: Debian amavisd-new at imap2.ox.privateemail.com Received: from mail.privateemail.com ([127.0.0.1]) by localhost (imap2.ox.privateemail.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id yNHbakabVFC2; Wed, 4 Feb 2015 20:08:17 -0500 (EST) Received: from oa-res-26-240.wireless.abdn.ac.uk (oa-res-26-240.wireless.abdn.ac.uk [137.50.26.240]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.privateemail.com (Postfix) with ESMTPSA id 555148C007B; Wed, 4 Feb 2015 20:08:16 -0500 (EST) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 8.2 \(2070.6\)) In-Reply-To: Date: Thu, 5 Feb 2015 01:08:13 +0000 Cc: Nikita Popov , PHP internals Content-Transfer-Encoding: quoted-printable Message-ID: <4A36329B-F17B-4665-A84E-D8CF01F5B29A@ajf.me> References: To: Hannes Magnusson X-Mailer: Apple Mail (2.2070.6) Subject: Re: [PHP-DEV] Allow dropping typehints during inheritance From: ajf@ajf.me (Andrea Faulds) Hi Hannes, > On 4 Feb 2015, at 23:58, Hannes Magnusson = wrote: >=20 > So what it supports "more inputs"? > It does constitute an LSP violation. "more inputs" is not what the > guarantee is at all, if that is what you want you'd typehint on a > interface. >=20 >=20 > It is a LSP failure to allow a string, or any other scalar value, when > the parent requires a specific type/object. >=20 > It sucks that we fail our arginfo very frequently, but this is the way = it is :] An interface requires only a minimum standard for accepted input. If a = class implementing that interface allows a wider range of values, but = still allows at least what the interface requires it to, it is not an = LSP violation. Scalars are not special. -- Andrea Faulds http://ajf.me/