Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:116057 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 31476 invoked from network); 17 Sep 2021 04:33:41 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 17 Sep 2021 04:33:41 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 86B2C1804E3 for ; Thu, 16 Sep 2021 22:13:32 -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,HTML_MESSAGE, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS 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-vs1-f46.google.com (mail-vs1-f46.google.com [209.85.217.46]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Thu, 16 Sep 2021 22:13:31 -0700 (PDT) Received: by mail-vs1-f46.google.com with SMTP id n17so7665771vsr.10 for ; Thu, 16 Sep 2021 22:13:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=jRth/L8qm5b9B1xMsjcn0GeARpipFT6y4ZR8Z1K/7c8=; b=lz5Ahc3lG6W7lmzzuDVE070wdvJyPhKFwwc+i2Np4XhuPBOrbM5J7KXgFFLIHE3siw 06JY/yKU90f4xKLC/ItlMudmvEYubOFcYhwcvx3js5/OPgiQ3SwOw6TsNKuJEDK2hG32 Lr8i/J5hgg1QJqo0m5kRRxC/HzbKfQY2A6sDk03LMg0ze4RkX4C6AWlgBrauy93CkMho enDiEVsFdTI3Qr2sRDv0nqUA8D6xnra12LdqG6CrWgsN+/uTO7hai3WT9SC6JdnkA8TZ 4VAe3MN9QO5c7Su0oZxTCGLp+j9ws1Ny59S6fzm5RDifL2dwPw8HWZVFO+UU6VN0eoV1 TfbA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=jRth/L8qm5b9B1xMsjcn0GeARpipFT6y4ZR8Z1K/7c8=; b=bS62u/3ABrF/Mns/igFT2HRaBKG+IBayEyyMMLTDn9GzHuJF+RfQ8peElfv61V1fsz qJaIF5wqn1JLWC0f/i572EdrVDgUTR/JKezfm1a6O0tAGPuVYyJ5jwAnX67EBx4u1WIQ uT3oE0n+Mymn9C6C0bK2IZjVOlORT4jXl/dd6uEyXKw4w9qg2/h6DkZ3LVbVgzpyJLQv dgyCtSIb4kD520YHB/hzofsM/SfozTceqzIzSLUX59+CrGn6ndwzAKgFB3rsNaHrCHfd VHEdHTGZzsuWzuVyCCbaHdDuYdSzbonIfGDyCM2yt26tM4rDlfmV7GUbZ48ekF9tPmPf Y3iw== X-Gm-Message-State: AOAM532my1x7xOXrtNXZvjPG2AzQORZ3L75n3y0NwfH8jVxYhb9H6g1Q d0950qTQgJwkdakRj1aOBWedvZQWf2MRfIEgqwA9V+sZEa0= X-Google-Smtp-Source: ABdhPJzh87wyVd+m8Bgl26fhJe93G0XtR6fi4iN5OoXluPsWSqo+khFOE4JJrf+AENcl5ILIOvGhAr7Q1aQySsz4k6U= X-Received: by 2002:a67:db82:: with SMTP id f2mr7454205vsk.23.1631855611131; Thu, 16 Sep 2021 22:13:31 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Fri, 17 Sep 2021 01:13:20 -0400 Message-ID: To: tyson andre Cc: "internals@lists.php.net" Content-Type: multipart/alternative; boundary="00000000000006bc1905cc29fe22" Subject: Re: [PHP-DEV] RFC: Add `final class Vector` to PHP From: matthewmatthew@gmail.com (Matthew Brown) --00000000000006bc1905cc29fe22 Content-Type: text/plain; charset="UTF-8" I can also give some in-the-trenches perspective of vec's utility, having spent the last month and a half writing Hack. vec is a really useful data structure to be able to use explicitly in code. It makes code that uses it easier to understand. The main benefit over Vector is that it could be used as a straightforward replacement for array in many cases, with the same copy-on-write semantics helping developers avoid spooky action-at-a-distance. I'm confident that by the time that such a feature would be ready for primetime, there would be tools in place to assist migrations. We could also presumably allow for casts between vec and array. And once opcache is sorted out, I'm also confident that the advice "using vec will make your code a bit faster" would be a successful recruitment tool. Best wishes, Matt --00000000000006bc1905cc29fe22--