Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:92519 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 84679 invoked from network); 20 Apr 2016 04:01:37 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 20 Apr 2016 04:01:37 -0000 Authentication-Results: pb1.pair.com header.from=php@golemon.com; sender-id=softfail Authentication-Results: pb1.pair.com smtp.mail=php@golemon.com; spf=softfail; sender-id=softfail Received-SPF: softfail (pb1.pair.com: domain golemon.com does not designate 209.85.215.65 as permitted sender) X-PHP-List-Original-Sender: php@golemon.com X-Host-Fingerprint: 209.85.215.65 mail-lf0-f65.google.com Received: from [209.85.215.65] ([209.85.215.65:36209] helo=mail-lf0-f65.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 68/B0-14036-02FF6175 for ; Wed, 20 Apr 2016 00:01:36 -0400 Received: by mail-lf0-f65.google.com with SMTP id j10so4488152lfg.3 for ; Tue, 19 Apr 2016 21:01:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=golemon-com.20150623.gappssmtp.com; s=20150623; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc; bh=wnfgtsYxiHhR/A6nF3xz6X8E2ROpgkiW62VvWNePFNQ=; b=kyHiOx21p7PuB4nPHy5g+jl7hF5Mws3IkBd1iGKx6uhj48Wo5o36UONKuLERUrOpqq eWHRsScTCkj63b3iyN+HW7Jm6HmgMQN2bgUc9aBPkl3ShHanx7Gn62gDFLkZw5aoy5AX gEVaum4nhd3tBdKghS1gV/y/j+28i+aqDahcHDf/DEJ9bKWwjpx4ZfCeo23KvCiyN/4D vLSmPssr3rV2N7IGohMNQ3l2+wCVVVs6I67Jm9EtfMRUtS6tUS5C5I06GFKloFjLjUJA x/w8QFzLIY79KxlqSX6P8gB3HpxbrZpTX3pjjCTIl8n8gwtcRFWKfR3rAfUdfmiutZyQ Op5w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:date :message-id:subject:from:to:cc; bh=wnfgtsYxiHhR/A6nF3xz6X8E2ROpgkiW62VvWNePFNQ=; b=OyZgkTU18ltgkS78/Vvn53SFvoMF/YjK8yyKzP2s6L4oQcx42yUmPNTvDT2Xj4gx2E 3BipkFVx6jdE06eo//kRJAN96p9/ZrfzpeYwudfP0/l6PljLzdOAb/3Y7GYfK0AU5BDN tyIGscoYwoakzrtEcTQNJIrvNR9pwFCUJ2yCcVp+GsRlV3GluKseyHhJUAOvtfIX0Ra9 p2UBq8JRBXB16B0hsjX38aEpVdbUvgeFiwfz66lh1ZFMErGroHFyYT/YpCnNV8FSejDB xnLoPtfsued21yflmELwkntttxLX6NuUk+8IjoOictusmhspYI+TDlUFgyMXl3bTjFwX +m0Q== X-Gm-Message-State: AOPr4FWWOf+ha8vDUxVHnFyYm83qfICFC1rQpxCzkCaLuK6spXqQmQhKkBojG115VnekFQO5CXdHUZjskTlFRQ== MIME-Version: 1.0 X-Received: by 10.25.169.144 with SMTP id s138mr2679137lfe.108.1461124893163; Tue, 19 Apr 2016 21:01:33 -0700 (PDT) Sender: php@golemon.com Received: by 10.112.19.74 with HTTP; Tue, 19 Apr 2016 21:01:33 -0700 (PDT) X-Originating-IP: [107.198.91.68] In-Reply-To: References: <3cc8a4c7-2640-11ae-a67b-06f909ac1e27@texthtml.net> Date: Tue, 19 Apr 2016 21:01:33 -0700 X-Google-Sender-Auth: BSoqideEDHe4tSGQ16yrb-QIe6I Message-ID: To: Jesse Schalken Cc: Mathieu Rochette , Dominic Grostate , Josh Di Fabio , PHP internals , "Ben Scholzen 'DASPRiD'" , Rasmus Schultz Content-Type: text/plain; charset=UTF-8 Subject: Re: [PHP-DEV] [RFC:generics] From: pollita@php.net (Sara Golemon) On Tue, Apr 19, 2016 at 7:56 PM, Jesse Schalken wrote: >> class Collection {... > > I think the "where T is Traversable, T is Countable" syntax was intended to > represent the intersection (i.e. a "Countable Traversable"), not the union. > > So you would need an intersection syntax > > class Collection {... > And that's precisely my point for why reusing the suggested syntax for union types makes sense. You can to specify either intersection or union (or potentially a complex combination of the two (A | (B & C))), rather than being limited to intersections only. -Sara