Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:127300 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 lists.php.net (Postfix) with ESMTPS id D80AB1A00BC for ; Wed, 7 May 2025 13:18:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1746623803; bh=RunKTY8w/zOnQQEn3Eb0I9Mi5H48c/ilRuesGx/1GCw=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=h6U4XggoU9TqZ7+nDpU1u80u0+U+nh1kB6LrUG2JUH2J5KO2mqypsZs0bjYE4iHnR JfaZkQ7Bg4DlZGVw745nXS9Li7vByUXltfi8yPvR2OtUMiqsrASwGhwpz8P1fG939q rw5NLNzjKGs2HwKmq/X4mnq3ANkv6YclEeZZpBhPh+p3PzBPlAJfYduYnjqSWCf49f DJaY38giarVWmmbJTCbq+yZIIrIX9HyLkn2UkuwAAdybWUi1uiT+k/BMzpojiMasUg i0Z2iH7uK5ggh2oYpe94SeqWRO6+W4xWS1HOA0INmmLorly9ROYaGe5iMrcIL/viph JI7k+hhOhXOng== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 3AF3E180053 for ; Wed, 7 May 2025 13:16:43 +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 autolearn=no autolearn_force=no version=4.0.0 X-Spam-Virus: Error (Cannot connect to unix socket '/var/run/clamav/clamd.ctl': connect: Connection refused) X-Envelope-From: Received: from chrono.xqk7.com (chrono.xqk7.com [176.9.45.72]) (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 ; Wed, 7 May 2025 13:16:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bastelstu.be; s=mail20171119; t=1746623935; bh=meYIMJ9kZCtMXBT5xU3H4tNGWW/kOBP1facECmJ/mh4=; h=MIME-Version:Date:From:To:Cc:Subject:In-Reply-To:References: Message-ID:Content-Type:from:to:cc:subject:message-id; b=UNb8ZGz940LRHtePxnp1fb1EVaxacAxPLyaWX7Bb6Et4nmPK5i6xfx+WN2bO/mD8A AWfTQdJE8uXpXt8UsG72I10hLfgS7LMpzKxBqGksDLeNAS1fC7GmzugOwJlRzJ2FBG j+tRqmhUPJ6Nx2U2C/Ab9Ezi8xmYbTadESC4gf32pfoUBaVRmMkmviDPq73u8EvQMg 8Z+9BZuStneEStpUyGkRhuWjsvlRG3hzonHrBDcRG9uJg+Po5QbDnrJJhKtEe/y4Au J3L+8+eWfY3xIYfGx6EUrMaxotm1Cbv2+xN6pwxeYv9JxuKwdMMn8LvodcPqc0ZHFW NdSHvE1KZoqhg== Precedence: bulk list-help: list-post: List-Id: internals.lists.php.net x-ms-reactions: disallow MIME-Version: 1.0 Date: Wed, 07 May 2025 15:18:54 +0200 To: Rob Landers Cc: "Rowan Tommins [IMSoP]" , internals@lists.php.net Subject: Re: [PHP-DEV] Re: RFC: Nested Classes In-Reply-To: <386b4359-be5b-4872-b2c1-c8211a08d7dd@app.fastmail.com> References: <9c4ac301-dfb2-49da-90e5-37a2824fc4e3@app.fastmail.com> <5b1e6d70-a1c9-455c-93d3-6b22cf1fef11@app.fastmail.com> <52d84a5b-09d3-4e42-9620-a62fb239c21e@app.fastmail.com> <09a82882-f1ee-4bdb-8a27-e46144a711f1@app.fastmail.com> <706e22d7-94eb-44bd-a280-f629ba93b630@app.fastmail.com> <03a5b9a8-9fe1-4656-ab04-dd58669488b3@app.fastmail.com> <158a5d7c-8ef6-4b5f-b8ef-593879a7a896@bastelstu.be> <72ef8352-2afb-4024-b4ae-857fcd94edd6@app.fastmail.com> <213a8711-adbc-42b7-bcb8-86e64cb22cf2@bastelstu.be> <5A723310-1AB6-4D4A-88CC-52EC4E81AE5C@rwec.co.uk> <681845d2-ff1e-4ab8-97b2-50fecfdcb62b@bastelstu.be> <386b4359-be5b-4872-b2c1-c8211a08d7dd@app.fastmail.com> Message-ID: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit From: tim@bastelstu.be (=?UTF-8?Q?Tim_D=C3=BCsterhus?=) Hi Am 2025-05-06 22:04, schrieb Rob Landers: > I think these are fundamental problems (if they are a problem at all) > with how PHP currently does namespaces and names. I don't think that this is a fundamental problem of namespaces and names. Ilija solved the naming conflict issue in his file-private class proposal. > I'm curious if you would vote "no" for namespace visibility as well? I cannot answer this question. PHP doesn't have namespace visibility and whether or not I would be in favor of a proposal depends greatly on the proposed semantics. In the current nested classes RFC, the proposed semantics for `private` classes are inconsistent with how `private` in PHP currently behaves, which makes it unacceptable to me. > For everyone else who voted "no"; I would sincerely love to know the > reason. Even if you just email me directly; it would really help me > understand what can be improved in any future RFCs. I unfortunately didn't have the time to follow the discussion and think about the RFC in depth. Besides the `private` semantics, the autoloading impact is also a no for me, since to be able to properly use nested classes, a composer update would be required, so that composer’s autoloading implementation becomes aware of nested classes to properly load them. This means that if a package uses nested classes, it will *silently* be broken until the *consumer* updates their composer installation. I don't think it is currently possible to define a minimum composer version as part of a package’s dependencies. Best regards TIm Düsterhus