Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:120796 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 10671 invoked from network); 12 Jul 2023 17:48:11 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 12 Jul 2023 17:48:11 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 195641804B0 for ; Wed, 12 Jul 2023 10:48:07 -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=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,HTML_MESSAGE, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,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-ot1-f43.google.com (mail-ot1-f43.google.com [209.85.210.43]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature ECDSA (P-256) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Wed, 12 Jul 2023 10:48:06 -0700 (PDT) Received: by mail-ot1-f43.google.com with SMTP id 46e09a7af769-6b5ef64bca6so6256700a34.3 for ; Wed, 12 Jul 2023 10:48:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1689184085; x=1691776085; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=mlamcSvXXUzc+4+qXwAxyd44S0YfveeeALWZ0a5Cs3Q=; b=ostaJCbKnYES2/2aE2hiHZ7c33i0T0DRU21BFQ+aoNy2pFiUkTxF7QwRqD0vWz1Noj 6lttytgR3Qwf5p99LcdCytJQKpdaKHvfDVy4ZgRSX/wCQU6oRR3RdNAYYR5eVjHLb3YA CagcVw2EooG5UaiL9YQHo7g8gx1YLkWzmiDSBK7coTbWiy5h90W4fuSfVjPccsAtlDRF +m58IUd5zqZEPur2KVk989NEXwDYJTsGpYvy+7mN9dXFxBl5zstbRT8NCtBFDbuloz/K fbAMRX1KmD/OyZ+JwAOPlvq+PGtJy3085b4JSa+f+pTUk5LEvONHcO4M1PNTuy9Z8OVB af0Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1689184085; x=1691776085; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=mlamcSvXXUzc+4+qXwAxyd44S0YfveeeALWZ0a5Cs3Q=; b=gyXt/kfpDt8BpmKAE3S8qNBO+RKqjeCQCc8Vhc+RDifC42bOjdFGkn9LBbXzUMLZg7 r9sPK4ZIOav4zZhtajPiwodFqaW/Fa/fJRBft66El5V0n/Gt0wgbgsjh+jnb4zc5EIQR DYLKjabFTYfc0UbhgZcddAyJLK1cU/OmgOI2x0iFyAM4i/1LvXw1apd2j9M/Gt9s/9dV dpMZP35YURkAj7apx/LlIm2/SHHTDDnjqj5TMO8H3FtbPQcvpdh1HDqpC1lZ+Fj1WNcY CM3643pSp9XFSfWzzRJ5CIfpAYVHSuY7uiH07qG70372hbZydscdQB7jt/8Q9KPdhYYa 47yA== X-Gm-Message-State: ABy/qLZQpojRDSF/dqebitNANOYKUy4dtZJ7xfvb+VKDoDxWoCjQXNd1 XS9gWXfE+pp2EM4wdSmpBKOykIAeZKOGza+jsw1P1m+cJeJt7g== X-Google-Smtp-Source: APBJJlGiuZpH3f0G3g1ztfF+JWEiW/BKTAnN93TCoKDmEfaJGuRrOUcOPwu/I41cQWK4oq5yEYxskJACfeHOOkEpicY= X-Received: by 2002:a05:6870:e88f:b0:1b0:2bff:b9b5 with SMTP id q15-20020a056870e88f00b001b02bffb9b5mr21598156oan.47.1689184085576; Wed, 12 Jul 2023 10:48:05 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Wed, 12 Jul 2023 18:47:55 +0100 Message-ID: To: "G. P. B." Cc: Levi Morrison , internals Content-Type: multipart/alternative; boundary="0000000000006192e306004dd10a" Subject: Re: [PHP-DEV] [VOTE] Interface Default Methods From: davidgebler@gmail.com (David Gebler) --0000000000006192e306004dd10a Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, Jul 12, 2023 at 5:01=E2=80=AFAM G. P. B. = wrote: > > Maybe the resistance to the proposal would be far less if the RFC, and > implementation, would check at compile time that the default > implementations only rely on known existing functions available to the > interface. > I asked in the discussion if this was a possibility, and it's the biggest concern I had about the feature as proposed. Rowan answered "As the RFC says, it introduces a form of multiple inheritance, and inheritance in PHP doesn't make any such guarantee" and Levi added "I hope static analysis can fill the gap here, but don't think these checks are necessary to ship this feature" - and this is fair enough, I think; we kind of do accept the nature of PHP is that there is some anti-intuitive weirdness versus statically compiled languages. I wasn't convinced at first but I've come to be persuaded even if it's not a perfect implementation of default methods as I would have wanted them, it's still a significant improvement on the trait + interface model we have now. It's ultimately a step in the right direction and I'm disappointed now it looks like it's not going to happen, at least in the next release. Would be good to know from some of the no votes if they'd reconsider for a future version. --0000000000006192e306004dd10a--