Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:120434 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 58163 invoked from network); 29 May 2023 18:35:43 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 29 May 2023 18:35:43 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 18F68180506 for ; Mon, 29 May 2023 11:35:43 -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,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-ed1-f49.google.com (mail-ed1-f49.google.com [209.85.208.49]) (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 11:35:42 -0700 (PDT) Received: by mail-ed1-f49.google.com with SMTP id 4fb4d7f45d1cf-514ab6cb529so824823a12.1 for ; Mon, 29 May 2023 11:35:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1685385341; x=1687977341; h=references:to:cc:in-reply-to:date:subject:mime-version:message-id :from:from:to:cc:subject:date:message-id:reply-to; bh=OaOQS6y43dvBO27ucYSMha6IeRNxQ1Uk/5E7TukBDNA=; b=C72s6G6WZwUZ7NN7wHrqQerKJ9gS0cwacAY3iHsSUynj6fYNJH6UDgV0Pd7SND3SOs aEV+yJuyzN+fXP0Demk4h1A9N8iFYLogx8VBs3c+ZK00I8X3vG+GRJqGeQlLmQpkPdPG wrHz678FMWkbFyFjpBEU2zNsW5BIlqrkwh5fziOIyb0em/cPkdS93FTrfkQ+6rPCud6x JMkWJcpBwXVTUD9/XCjO4APh1g8VxwcsE/Z9Jv3fAPoCkRAbhs3N8c9L+PUypN+t7KLs idqdq1vJjome64dA+z4wzkQ4vmQaSf2uVi711JwakPx6h+RxoRxsj3lFff5/1OWHwA2P rfgQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1685385341; x=1687977341; h=references:to:cc:in-reply-to:date:subject:mime-version:message-id :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=OaOQS6y43dvBO27ucYSMha6IeRNxQ1Uk/5E7TukBDNA=; b=MEvio7R2HpBdgbQslJUrMSKxg8kMF6UNoOTtU6OyBQFlAg3e7g0zJvyffrF6YP0ls4 Il2QKjK7quXa58fL6dulbZQiLUs+gX/PeEd5BwFNbiR5vrVi+b+bxD4DOPvUAZXkaPba cnGKozN8P9saHA5bAzs0P/W1+3yR7rGajUpWMqMq5a3TMDnl3a7R1145uq2gHcKsyvo8 tWxnBdnd8s69WfqA8Ek0mZvDwItwXR1Qzp5L2qXMqE+1jvmXUphhUDTVkWxgKjOspysV /73YKHhPTJd3jxPCy+wOqwlIqnhHlEVpbriM0bmVrTIPNdoBMyoHXmIQNEaXoQ/t/6Tc EAbA== X-Gm-Message-State: AC+VfDx8SYEaSyyvxzBP3jIvq+vjwJthsrgxqKm+J5AioR4eZI3cM/kY BEorhqrIW6MVjYXvebY/PlA= X-Google-Smtp-Source: ACHHUZ6w8kDH0gLjijpFgIknksyQIrIjqikNygpcZguVmoOrR4wiZjJX67izzaWwaSzBLbSD9tW08w== X-Received: by 2002:a17:907:3ea5:b0:96a:99d2:a680 with SMTP id hs37-20020a1709073ea500b0096a99d2a680mr8160877ejc.34.1685385341043; Mon, 29 May 2023 11:35:41 -0700 (PDT) Received: from smtpclient.apple ([89.249.45.14]) by smtp.gmail.com with ESMTPSA id k7-20020a170906054700b0096f675ce45csm6149224eja.182.2023.05.29.11.35.40 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 29 May 2023 11:35:40 -0700 (PDT) Message-ID: <5798AD17-3FA6-48E5-83E9-B5773BE94598@gmail.com> Content-Type: multipart/alternative; boundary="Apple-Mail=_1BE4FD64-5C5F-48DD-8764-E82E04F870E8" Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3731.600.7\)) Date: Mon, 29 May 2023 20:35:29 +0200 In-Reply-To: Cc: PHP Internals List To: =?utf-8?B?TcOhdMOpIEtvY3Npcw==?= References: X-Mailer: Apple Mail (2.3731.600.7) Subject: Re: [PHP-DEV] [RFC] [Discussion] Deprecate functions with overloaded signatures From: claude.pache@gmail.com (Claude Pache) --Apple-Mail=_1BE4FD64-5C5F-48DD-8764-E82E04F870E8 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > Le 27 avr. 2023 =C3=A0 23:28, M=C3=A1t=C3=A9 Kocsis = a =C3=A9crit : >=20 > Hi Internals, >=20 > As you have possibly already experienced, overloaded signatures cause > various smaller and bigger issues, while the concept is not natively > supported by PHP. That's why I drafted an RFC which intends to phase = out > the majority of overloaded function/method signatures and also forbid > the introduction of such functions in the future: > = https://wiki.php.net/rfc/deprecate_functions_with_overloaded_signatures >=20 >=20 Hi M=C3=A1t=C3=A9, The replacement methods for IntlCalendar::set() (namely = IntlCalendar::setDate() and IntlCalendar::setDateTime()) must not have a = return type of `void`, but `true`, like the original method, for the two = following reasons: 1. By changing the returned value, you are introducing an unnecessary = hazard when migrating code. 2. Per https://www.php.net/IntlCalendar, all modification methods of = that class (clear(), roll(), setTime(), etc.) consistently return `true` = on success and `false` on failure, even when the method is infallible = (and thus would always return `true`). Don=E2=80=99t break consistency. =E2=80=94Claude --Apple-Mail=_1BE4FD64-5C5F-48DD-8764-E82E04F870E8--