Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:117921 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 54221 invoked from network); 12 Jun 2022 18:57:35 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 12 Jun 2022 18:57:35 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id BFCC9180384 for ; Sun, 12 Jun 2022 13:44:40 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-0.2 required=5.0 tests=BAYES_40,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,NICE_REPLY_A, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS15169 209.85.128.0/17 X-Spam-Virus: No X-Envelope-From: Received: from mail-wm1-f42.google.com (mail-wm1-f42.google.com [209.85.128.42]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Sun, 12 Jun 2022 13:44:40 -0700 (PDT) Received: by mail-wm1-f42.google.com with SMTP id q15so1965731wmj.2 for ; Sun, 12 Jun 2022 13:44:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=message-id:date:mime-version:user-agent:subject:content-language:to :references:from:in-reply-to:content-transfer-encoding; bh=GTT3eMCrSG8fQsNNj7ZhTF9bDk2avCMjYup6mFg8JeA=; b=ZNpw96MQi72GGybZAc3w4tvshvP4lTziOxMqoTGfeNWg2aZAjPEGGvJEHY1QbJgHUk BL0HqqFwyXcSrJYm5ubUY6hnrgQtYIYtmni6MOLFxgLZIOCNHezUd5U1U1Tgb2FZnuj2 uyROFlOA7f+9UaPK29LnKB3YIQsCVUShmYzc734Q6MEDWA7QKeYVJwX58dHpTK2T1qlJ xOuz4tLoQyWhmzGMJOITDFVMVEo0DqIX1LHE6V1nTWA314LTyLH7XznOTPe/ojLSUdjn 6Oxf33GoSW82OYgJB4iNmt6f+BJRqJMROPOjSBvCMuNGiNe0LMccsEdxEhpJD23KWQD/ XL2Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:references:from:in-reply-to :content-transfer-encoding; bh=GTT3eMCrSG8fQsNNj7ZhTF9bDk2avCMjYup6mFg8JeA=; b=UINOq/oPuknDsCdkp+xm0GAxiOamTPBTy5HPZPu2VsVyotH6JAbPVWc1qxYZyUGxK6 DLRMK5+Cbd5HnXIrLhIslVVljXOiy5YfpqDXcgg2vbekxqm/CUmtrujvkSzEMmrDc3r8 l+w/Oekwnt2yETTsrmM+aXIRtma8E2nxeWxssxGSCEfTeLRBQlLTTDrWwZiWOXPuJirD xDcsAeubNJYMsNzEcaBNzhzpB3lg0oQyuhxjjC3Xx7m/o14Da0lnWuAa1689lPf5bt+z VBWcLdOfZVY6uUpuqEtaMaZ7N4XEefvuNdUKCK182nUBXLGwrOu4r/Bu+imBEtERkAYg 6LVQ== X-Gm-Message-State: AOAM531xh48megBoGjk4uvI3is/1nCLQF11ExCK6h1jckMpKuxMelZfN KLkQa9+bQ/G6IKiwkdWM3uHUwREnuqk= X-Google-Smtp-Source: ABdhPJzl2A2c2GdOWyavmW2S/lP5q0GW4VqCqdbBD0S8tutgqDaCrW6I3OaW8hCwhBv2wzX4wiFv8A== X-Received: by 2002:a05:600c:22c3:b0:39c:5d0d:51f7 with SMTP id 3-20020a05600c22c300b0039c5d0d51f7mr11002216wmg.156.1655066679068; Sun, 12 Jun 2022 13:44:39 -0700 (PDT) Received: from [192.168.0.22] (cpc104104-brig22-2-0-cust548.3-3.cable.virginm.net. [82.10.58.37]) by smtp.googlemail.com with ESMTPSA id f6-20020a05600c4e8600b0039c6ce32a2dsm12085781wmq.33.2022.06.12.13.44.38 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 12 Jun 2022 13:44:38 -0700 (PDT) Message-ID: <25caf251-d9a4-ba57-9e23-7f0ccd914cf3@gmail.com> Date: Sun, 12 Jun 2022 21:44:37 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.10.0 Content-Language: en-GB To: internals@lists.php.net References: <2b35605f-8da8-46b1-aec3-00bd1bfe47fd@www.fastmail.com> <2279cbd2-fcfe-460f-97f9-0029b7b043bb@www.fastmail.com> In-Reply-To: <2279cbd2-fcfe-460f-97f9-0029b7b043bb@www.fastmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] [RFC] Short Closures 2, aka auto-capture take 3 From: rowan.collins@gmail.com (Rowan Tommins) On 12/06/2022 18:21, Larry Garfield wrote: > The primary target of this RFC is people writing 2-4 line closures that import 1-2 variables The first half of that sentence I was expecting - although as I've already said, I think the chosen syntax suggests strongly that the RFC is really targeting *all* closures, not any subset of them. The second half makes much less sense. If you are only importing 1 or 2 variables, is writing their names really that big a burden? Several of the conversations I've had on this in the past have been very explicitly about the burden of large numbers of captures; if that's really as rare as you suggest, it makes me wonder why we're even bothering. Regards, -- Rowan Tommins [IMSoP]