Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:123004 X-Original-To: internals@lists.php.net Delivered-To: internals@lists.php.net Received: from php-smtp4.php.net (php-smtp4.php.net [45.112.84.5]) by qa.php.net (Postfix) with ESMTPS id 2BC0B1A009C for ; Sat, 6 Apr 2024 16:14:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1712420118; bh=n1EKCvcj7agDNRClv550CyoKSDgqfOIHWNRL1Y+/F2o=; h=Subject:From:In-Reply-To:Cc:Date:References:To:From; b=hE/E+lCwCXk7JihB0cSJtLpbyUs0c6LzBc251uzfGFbhh3PTa5G/BYfIw9H+LA/3Z WA/u/7Dkpodji/q+jNgWrrNj0XHwhJYdGQ2pLkyzt8eXstTO598AkKnocPB/EEbVGb eql421huQceA3iIfd99OnoRE6h2Ut4fAfn3YXgq22xHf2R/jFBYqgJr56C7MjK6wGq Ms0AtMLaDZIYw6fAHR37sZkgAsO8JxAwf5ZeBuBTMe+Jw2H+q6ZaZkHbMW0LhGm/Im SdZ/yQ3SDnOmJGtwnhIDqP0whOPFY80jiafgZsFJA3Syyjd20nKKJYl9SIruNCtdp+ V9PtDDmfz0MzA== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 4019E180DBF for ; Sat, 6 Apr 2024 16:15:17 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.0 (2022-12-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,DMARC_PASS,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=4.0.0 X-Spam-Virus: No X-Envelope-From: Received: from mail.sakiot.com (mail.sakiot.com [160.16.227.216]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Sat, 6 Apr 2024 16:15:16 +0000 (UTC) Received: from smtpclient.apple (unknown [117.55.37.250]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by mail.sakiot.com (Postfix) with ESMTPSA id 0A546401F4; Sun, 7 Apr 2024 01:14:41 +0900 (JST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=sakiot.com; s=default; t=1712420081; bh=n1EKCvcj7agDNRClv550CyoKSDgqfOIHWNRL1Y+/F2o=; h=Subject:From:In-Reply-To:Cc:Date:References:To:From; b=ZF340rt6KyF6l8Hs0VyGnAg/N8swT4X77GbOS4U6kGO5MLn9E0SMwBSShUtvSUmes 1j8Y33IRXj/uJaWhzkjLG1D4ALVmcsWSwlaeEUcGSp3Om23omgjRDlYeHpGHoFxEQk KFw643APiej+IVJOXktl0ay4BZJKAGapVmeY97PM= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Precedence: bulk list-help: list-post: List-Id: internals.lists.php.net Mime-Version: 1.0 (1.0) Subject: Re: [PHP-DEV] [RFC] Casing of acronyms in class and method names In-Reply-To: <4c56763c-2d65-4f64-b1ef-87e6ab88a473@bastelstu.be> Cc: PHP internals Date: Sun, 7 Apr 2024 01:14:28 +0900 Message-ID: References: <4c56763c-2d65-4f64-b1ef-87e6ab88a473@bastelstu.be> To: =?utf-8?Q?Tim_D=C3=BCsterhus?= X-Mailer: iPhone Mail (21D61) From: saki@sakiot.com (Saki Takamachi) Hi Tim, > =EF=BB=BFHi >=20 > On 4/6/24 17:54, Saki Takamachi wrote: >> However, in the example from "RFC: Namespaces in bundled PHP extensions",= the acronyms are not camelcased. e.g. `FFI\FFI`, `OpenSSL` >> In other words, the RFC can be interpreted as "excluding acronyms" implic= itly. >=20 > This is correct, because the current class naming policy specifies that ac= ronyms must be written in UPPERCASE. Thus the examples are consistent with t= he current policy. >=20 >> Just to clarify: I agree with your RFC. However, I think it is best to av= oid vague statements where the meaning changes depending on interpretation, i= f possible. >=20 > I've added namespaced examples: >=20 > https://wiki.php.net/rfc/class-naming-acronyms?do=3Ddiff&rev2%5B0%5D=3D171= 2350524&rev2%5B1%5D=3D1712419286&difftype=3Dsidebyside >=20 >> In fact, due to some ambiguity in the namespace RFC, I couldn't decide wh= ether BCMath's namespace should be "BcMath" or "BCMath=E2=80=9D. >=20 > With the current policy it should be "BCMath", if my RFC passes it should b= e "BcMath". I think Bcmath would be fine as well, if you consider the extens= ion name to be a single word. >=20 > Best regards > Tim D=C3=BCsterhus Thanks for adding examples. Maybe it's the "namespace is implicitly part of the class name" thing that f= eels strange to me. Because not only classes but also functions and constant= s can belong to it.=20 Regards. Saki=