Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:120438 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 65810 invoked from network); 29 May 2023 19:34:34 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 29 May 2023 19:34:34 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 3D390180549 for ; Mon, 29 May 2023 12:34:34 -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.7 required=5.0 tests=BAYES_05,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, 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-ed1-f47.google.com (mail-ed1-f47.google.com [209.85.208.47]) (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 ; Mon, 29 May 2023 12:34:33 -0700 (PDT) Received: by mail-ed1-f47.google.com with SMTP id 4fb4d7f45d1cf-5149c51fd5bso2757665a12.0 for ; Mon, 29 May 2023 12:34:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1685388872; x=1687980872; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=+OuzD55qsJDxxLXNlsItUNh0EuEbkpahC3j8V44r8TE=; b=HeiZJVV2+7d+mSUqNCHyfuEecniKISbgkM2nTjsBhw3zhvRUFNEVrFw252uw2ZmXMn d0Xr3yQ6raS4tYnF7837aB/LFv903WCdV3azAk9wX2wSzuLRWOaP6q7ixn4/xHxSNQxY r0lMK21Pg0zoyrtGIySi23eeafORmDvdKpNxSWKj0D98qoFq5DBRFDacsWtIJ3xlY5zO vYzMytqcOq/MLcULNB9kIlFKzV2TjG8Xg2Umzn2ukdMtcDo117IEDS7CzWrdlZr190+o N+7PyQ6pz3gmEPygCAjd9W/r0RcusXo06XX5ixNc/euSg5qATaj4dGTAiHIU7mwqzN5F BkZA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1685388872; x=1687980872; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=+OuzD55qsJDxxLXNlsItUNh0EuEbkpahC3j8V44r8TE=; b=g+VV3uyOMhN4JBqv9qL1IYxynnRwSHx1PhZk/HD/V9CBBXmYNX7rISsCOrlIRK5ehN 2Nncq0HIzZttHf/t7KPEoXxHGicLyo8fcw/gzaDc4lM0647/4V1k0uOFVXH1Efl+fVRB LnfWa9ToZ0a2yt8NGKXvAM7CTyptogTjTIDATWVJjgS9PyxVNIeEJBHIlY2U6o5yETx7 yec8udL1locteoncl9O87mUU9CDJi7/DAiWa6nKjum/MuBbSRPe/25UtcKUULl+lF2AH osjildkNaPxLY659Fla9PnElqD3nzFVwLcS6DCo3qXoPHO8X2f1WleL1iwIIZmdSyiUJ v+Gw== X-Gm-Message-State: AC+VfDwuSkonOTE9QbboilHMyvxCoQ2oth0GCx3uFq8dUHzbwCXDUK18 i6XoVWHI6QnTAHN+Wdd92WBiNCFUkuA= X-Google-Smtp-Source: ACHHUZ6YJ8h+lu/ufhEgjUr48wnVHBz0ppz/ghM0pFGXl0lwC4wCYwJLuIjBKlkbyqkFTGueQiyxFg== X-Received: by 2002:a17:906:5d0f:b0:94f:29f0:edc0 with SMTP id g15-20020a1709065d0f00b0094f29f0edc0mr229772ejt.44.1685388872423; Mon, 29 May 2023 12:34:32 -0700 (PDT) Received: from smtpclient.apple ([89.249.45.14]) by smtp.gmail.com with ESMTPSA id ci15-20020a170906c34f00b009658264076asm6195318ejb.45.2023.05.29.12.34.31 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 29 May 2023 12:34:32 -0700 (PDT) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3731.600.7\)) In-Reply-To: Date: Mon, 29 May 2023 21:34:21 +0200 Cc: PHP internals Content-Transfer-Encoding: quoted-printable Message-ID: <91F5F43D-5A20-4B14-B2D1-475607021940@gmail.com> References: To: =?utf-8?Q?Tim_D=C3=BCsterhus?= X-Mailer: Apple Mail (2.3731.600.7) Subject: Re: [PHP-DEV] RFC [Discussion]: Marking overridden methods (#[\Override]) From: claude.pache@gmail.com (Claude Pache) > Le 11 mai 2023 =C3=A0 18:37, Tim D=C3=BCsterhus a = =C3=A9crit : >=20 > Hi >=20 > I'm now opening discussion for the RFC "Marking overridden methods = (#[\Override])": >=20 > ---- >=20 > RFC: Marking overridden methods (#[\Override]) > https://wiki.php.net/rfc/marking_overriden_methods >=20 Hi Tim, One weakness of the proposal, is that there is no notice when a method = without #[\Override] annotation accidentally overrides a parent method. = This is necessary for the sake of BC, of course. Therefore, (inspired by = the --noImplicitOverride flag of TypeScript), I suggest adding a = complementary #[\NoImplicitOverride] annotation on the derived class, = that makes #[\Override] mandatory on overriding methods. The following = example would then trigger a compilation error since Laravel 5.4: message =3D Http::get($this->url); $this->save(); } } ?> =E2=80=95Claude