Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:72845 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 4962 invoked from network); 27 Feb 2014 21:34:44 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 27 Feb 2014 21:34:44 -0000 Authentication-Results: pb1.pair.com header.from=ocramius@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=ocramius@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.216.175 as permitted sender) X-PHP-List-Original-Sender: ocramius@gmail.com X-Host-Fingerprint: 209.85.216.175 mail-qc0-f175.google.com Received: from [209.85.216.175] ([209.85.216.175:62278] helo=mail-qc0-f175.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 01/11-33117-37FAF035 for ; Thu, 27 Feb 2014 16:34:43 -0500 Received: by mail-qc0-f175.google.com with SMTP id e16so275708qcx.20 for ; Thu, 27 Feb 2014 13:34:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=SkMOV2Adl/53HBwLPkwjZLX+a35vRvEXlSgjk+38Ob0=; b=IapdVRovKczOpZFiSQ9kEwKh7+0YMTHnBHU81u+Nap+HWXwPcW2qwkLrQldX3aiuJj MdnDfYbbaZe3n8Soyk4dwHeWb39Rb8MPYZSsU/Glb6FB6GwmhJBD/8/MkRbp1218H8AZ MxJUWGgnKiBPWsdP4JvYQEYASGTgSyRgHNWk+FUrKoqFHSQYYI/kxXC2Pvo9XcCmsyCj bX7P/IwzBKN9/1Yer4xxrqTjQnFQesZIT3DSA2YXu6cwetM3OrlZ82xrTZRjlZBV/7Ou lE/MghLmdRMKW46fxMTwb+1DlCfdsFxDdViSIwDUiSC7S/TLd8/8HdYOJ/c4X18u9BZk tnPg== X-Received: by 10.224.125.4 with SMTP id w4mr20561213qar.68.1393536880553; Thu, 27 Feb 2014 13:34:40 -0800 (PST) MIME-Version: 1.0 Received: by 10.140.28.247 with HTTP; Thu, 27 Feb 2014 13:34:20 -0800 (PST) In-Reply-To: References: <52D865C7.4070009@sugarcrm.com> Date: Thu, 27 Feb 2014 22:34:20 +0100 Message-ID: To: Philip Sturgeon Cc: Andrey Andreev , "internals@lists.php.net" Content-Type: multipart/alternative; boundary=001a11c248f8bf372004f36a16d1 Subject: Re: [PHP-DEV] Introducing "Array Of" RFC From: ocramius@gmail.com (Marco Pivetta) --001a11c248f8bf372004f36a16d1 Content-Type: text/plain; charset=UTF-8 On 27 February 2014 22:11, Philip Sturgeon wrote: > So, should we allow nulls in an arrayof-style type hint? > > `null` has its own type, which is mismatching the type required by the array-of syntax when requesting, for example, `Foo[]`. If `null` was allowed in the array, as a user, I'd still be forced to `array_filter()` on every call, so it would defeat the new feature completely. Cheers, Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ --001a11c248f8bf372004f36a16d1--