Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:120381 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 73429 invoked from network); 22 May 2023 11:49:04 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 22 May 2023 11:49:04 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 60156180546 for ; Mon, 22 May 2023 04:49:03 -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.5 required=5.0 tests=BAYES_05,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE, 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-f41.google.com (mail-ed1-f41.google.com [209.85.208.41]) (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, 22 May 2023 04:49:02 -0700 (PDT) Received: by mail-ed1-f41.google.com with SMTP id 4fb4d7f45d1cf-510ea8d0bb5so6708792a12.0 for ; Mon, 22 May 2023 04:49:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=basereality-com.20221208.gappssmtp.com; s=20221208; t=1684756141; x=1687348141; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=9IUw+Rm4Eh7vu5z8Mdwl46xEZ6DgNR0shKyynowyMx0=; b=THKdVkKVEv/2NmFtWI+g+ucUp6oJouOH6B83oZtHUHJkRyyZsN2E/JoPFOZNHXTS9y 2UlXX2KTeD3mphWC4yqBUNcjCibVKX5DMJZyaLz7dxBb0O7RBpOZMHu7YREM+GrrG0ze 2EwGZrU+wDcDMI7fiL3M5eqVH8LgvqOCEFBjww+yECn48ZBe6cEgc0TXT06qn8Bnqdol oKi6GGC8JY2rtS/jK3O631agXPxMX31g9gZeHFP0qag53+9l8ZKZTCb/tiAMKit1Nr9s nmuYScYYMmyZ9oTMGXVostpZZVsdmZw3a6yyT17GVJdcvW3MltgXiq1wf/5Kk6KiAnJ5 VTiQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684756141; x=1687348141; 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=9IUw+Rm4Eh7vu5z8Mdwl46xEZ6DgNR0shKyynowyMx0=; b=H3EbtPT7e3EbONWDYMPJuBix3vKkMO4bLxZwoOPR1F1IEXSujGVvV1XFlrGy6m8F/G ycuhvCedIaJCOEGX0bLSfdoelDPVFwVdtXpoRJWBYDWiy0J5fdxbA/CmYgeiaPTLqS/e +5xQUl/II49grpFQ0epsPRnbXy9mmaP/Ac96gTYjHDWxNvs5Pt6xcY9wwrV0/mZKFrKu P3iGUAT7F3cZc5YI5lWo6kMnfBYYkw4tVxTK9huhzyPqYD7vweja45ixPe6/wkR9sCqb s3aaH4p8Ygkj9sW1GoRu68peFj9n62YTeL+2kCPMUSn6mUsNHZL1hTNguObDZR41rm14 X1yw== X-Gm-Message-State: AC+VfDz0E/zoB1Wg9X6dZ/aw/DunYpnQ1fdzFQtT+CPokt++HCbbwSnr iPE5rK7tEJZNQ7SGfuFE1cebDOfb1rno9DJGx19GTA== X-Google-Smtp-Source: ACHHUZ7bqljJw1NgmfxHTirhIIiII8NuiddYGnrnNQ//4Z0g+mLktQYWmDlleweVgk7QuP82dzV2IVRHJin/QYypWu0= X-Received: by 2002:aa7:da16:0:b0:510:f3a6:d50 with SMTP id r22-20020aa7da16000000b00510f3a60d50mr7857335eds.36.1684756141507; Mon, 22 May 2023 04:49:01 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Mon, 22 May 2023 12:48:50 +0100 Message-ID: To: Marco Pivetta Cc: =?UTF-8?Q?Tim_D=C3=BCsterhus?= , PHP internals Content-Type: text/plain; charset="UTF-8" Subject: Re: [PHP-DEV] RFC [Discussion]: Marking overridden methods (#[\Override]) From: Danack@basereality.com (Dan Ackroyd) On Thu, 18 May 2023 at 09:12, Marco Pivetta wrote: > > I am not sure this RFC is really relevant... Would it perhaps > make sense to have this in userland first, in phpstan or psalm > plugins, to see if there is interest? The RFC lists other languages where an equivalent is available, and we can see that it appears quite popular: https://stackoverflow.com/questions/94361/when-do-you-use-javas-override-annotation-and-why https://github.com/microsoft/TypeScript/issues/2000 In those languages, it is a recommended "defensive programming" (https://ocramius.github.io/extremely-defensive-php/#/23) technique, that protects against the types of mistakes that are listed in the RFC. So one should be able to see there is interest....unless of course someone is so bad at basic human empathy, that they can't accept other people's lived experiences as valid, and will only accept something as 'good programming practice' if they have invented or experienced it themselves. But if that's the case, there's no use trying to persuade them. All you can do is point out that habit of not liking things that they haven't yet used/invented themselves, and hope that other people don't spend too much time arguing with someone who has a pattern of being unreasonable. cheers Dan Ack