Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:120815 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 29157 invoked from network); 14 Jul 2023 03:21:57 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 14 Jul 2023 03:21:57 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 55A18180382 for ; Thu, 13 Jul 2023 20:21:53 -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_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-ua1-f51.google.com (mail-ua1-f51.google.com [209.85.222.51]) (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 ; Thu, 13 Jul 2023 20:21:52 -0700 (PDT) Received: by mail-ua1-f51.google.com with SMTP id a1e0cc1a2514c-7940f3f20dbso151602241.0 for ; Thu, 13 Jul 2023 20:21:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1689304912; x=1689909712; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=2fdEwLaSRlZYytDbzEQHQ8jY7vNHQo63M6NtZrhz6sc=; b=EKCyf7yiK2qStqVwuEVVwbjHmGWND8cPQh+eii0Qz4QUwgqXF0Wsklw9oNRYD6OoVx ZNHy3/tLI6s+od5wVCaCzw5D2xycq4AWRDdyorV4bLZwO16i5HODhc6Eqw2/Q2iaPTEE rGPmbcDPkKpKWr9AVmmZB1ZyhcPNqq31die9SC/fincbnNvaCj05hwj+EeAte5WqYOqj 8/x6XHZXPm5EI/qiyZoMg1hQhURxU8ovww6r7civotoD94p6sfAy1jh89y6DyPvne7ZC hWoKcr2dAlPzsOTkqmmXtnSlTN1n3XEQkJ5GRWJGT85vKY4iduSFM6DVQUELmhxL4o8h 0JpQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1689304912; x=1689909712; 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=2fdEwLaSRlZYytDbzEQHQ8jY7vNHQo63M6NtZrhz6sc=; b=I+9y0iXgIcAOxFsg1+wbXKIdtn5tcbVxuJy2srFfa9+aEGuk3ivYY9X3ywrr2Ymny9 rob7VwWmco+nGdW2Jm50iP79etw9FypVNj1NMYM9mocuJ09Ic9ayMDWxzhrTR4ZFyWZ3 899TUCPWxfBY3pLCQ2brbCwZG6q5H7wLHZVg7JpK+jN711H4NFctj/ElySOIeEOSnJgE XmDBQRQxUYjj9qrcgnKc7Q0WZdUQUskyA7ye74Pe0Nh1p3bWkUOHozpM9o00JOKxRyBp he3o4Xkwhd0DOV3zYaFC0xti+NwEoduOn1Ub9lozCxzMWRJMP/CHZColzKXtUEcGfFnl hH8Q== X-Gm-Message-State: ABy/qLbD4XhO/8eClXaEimviylAP7nc3264sfoc5syno7mwe/o1e2sfh 87CUXaKCIO5YBfQLEt6ehMfPzwPv3kMEvybr5Ls= X-Google-Smtp-Source: APBJJlHAlJWjGhmv8BUyT5y6LBxZ2nta5TqFS6Kh6+mSRnWaXpTRfESfF5tHPZr24wqZ1t1f2Pr89nqEq+Xo6e/6XVA= X-Received: by 2002:a05:6102:3d21:b0:440:b96f:d146 with SMTP id i33-20020a0561023d2100b00440b96fd146mr1736235vsv.3.1689304911730; Thu, 13 Jul 2023 20:21:51 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Fri, 14 Jul 2023 00:21:38 -0300 Message-ID: To: Levi Morrison Cc: internals Content-Type: multipart/alternative; boundary="0000000000002e5e91060069f30c" Subject: Re: [PHP-DEV] Re: [VOTE] Interface Default Methods From: deleugyn@gmail.com (Deleu) --0000000000002e5e91060069f30c Content-Type: text/plain; charset="UTF-8" Perhaps a little too late, but I was wondering whether folks that voted NO would reconsider in case this was made a bit more opt-in. There could be some bikesheding around syntax but essentially the idea would be a new RFC targeting 8.4 with the following adjustment: interface Foo { public function bar() { echo "hello"; } } class Out implements Foo {} // RFC is ignored. // Fatal error: Class Out contains 1 abstract method and must therefore be declared abstract or implement the remaining methods (Foo::bar) class In use Foo {} // RFC takes effect. class In extends Foo {} // RFC takes effect but the class is no longer allowed to extend abstract classes, only interfaces class In with Foo {} // RFC takes effect class In as Foo {} // RFC takes effect ========== In the spirit of minimizing impact, the proposed syntaxes only use keywords already present in the language as to not run the risk of causing more issues (https://www.php.net/manual/en/reserved.keywords.php). This idea occurred to me when someone pointed out that they don't want to implement interfaces which might bring code into their class. Does this adjustment makes things better, worse or the same? --0000000000002e5e91060069f30c--