Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:126016 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 D37011A00BD for ; Thu, 21 Nov 2024 09:36:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1732181929; bh=tfFTjjHJI96pKZevGpZRgq6D0MvLAFh3z2s+eU4iwps=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=fS8pyAIzGWqH2gnCBjcM2dlnUgtqO1Hf1zo9TeQeIkWp9ZWwgzHeFaozbZ3mc5qUD By+hwUksB8YDmlWw+C+gIVUOgc3FGJWwCSLk97bbro7IRZUMxC2C37qGwCbEp8fO5I ygM0vhfCoJSEXlBgbOZm94SbK/b/qTMrNm2LoiKQUIwOM+pQLy8OIfJf4lIGIe3TW/ BQsi4JK9l2jB4pO4vHYbPBXPPF048ePjyaCUsi4D+MEQcQJfo4crCKmxvr3hWTgdaR J/Ekwx+jGCxToLgmR5OahDYiprsg96zsw9jm9gTDoNDbo0F+xOgQ/72lx0RTOmlmAT POgQfTCf13SYA== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 9912918007E for ; Thu, 21 Nov 2024 09:38:45 +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=0.6 required=5.0 tests=BAYES_50,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: No 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 ; Thu, 21 Nov 2024 09:38:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bastelstu.be; s=mail20171119; t=1732181763; bh=C2fEsr+h1dgHiFK5KEFTLyZ/WBZB/RmHTNtlUJOLJBg=; h=MIME-Version:Date:From:To:Cc:Subject:In-Reply-To:References: Message-ID:Content-Type:from:to:cc:subject:message-id; b=dN1/LRFn1k8fqJVxx47wBE7smzjRGbyShEqjxT7fReTgd5OOuxLft4KIpw1PTdFr+ yzKaDmgsyVKGc9tkNSk3u06pb2+S8MpcFcD9DAbcDweFOzF9ac34c8rB5m3SMdLi1h JOopAT+gJs0jVY3GePARMADDyvpSe6p9vqPMueyrJtNB9OkjqLWpATCtLYAykQj5EI Ao+ZAqSw0ohYXy/03x+Y6dit8GtMAjUm9G3UTQEkLuPArDU0/Nb3LDX0u1q2Nkd9zR CQeBHcmUEyHaWiD7E5uxl4swZh7mAHH+DfJY7g156HvRgJULAYhJp/EkeMLJuNFrLL gr3deiUzzvy0Q== Precedence: bulk list-help: list-post: List-Id: internals.lists.php.net x-ms-reactions: disallow MIME-Version: 1.0 Date: Thu, 21 Nov 2024 10:36:03 +0100 To: Derick Rethans Cc: internals@lists.php.net, Theodore Brown , Kamil Tekiela Subject: Re: [PHP-DEV] Deprecate alternate switch case syntax? In-Reply-To: <943CFFC1-B0F8-4326-BF2E-138BC1E48DB7@php.net> References: <943CFFC1-B0F8-4326-BF2E-138BC1E48DB7@php.net> Message-ID: <4b592cbebc0dcb6bcd66f3ef75e9d847@bastelstu.be> 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 2024-11-20 20:03, schrieb Derick Rethans: > All my PHP based templates for the xdebug.org site use this style. I > don't think it's atrocious, and quite a bit nicer than the "new" > syntax. This proposal would not affect that. You would just need to add a colon after the `case` statement, not a semicolon. In fact that would more closely match the corresponding `switch`, which would also need to have a colon: BAR BAZ Though using `switch` in such templates is somewhat finicky anyway, because it will need to be merged with the first `case`, because otherwise: > Parse error: syntax error, unexpected T_INLINE_HTML "", expecting > "endswitch" or "case" or "default" Best regards Tim Düsterhus