From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from esa1.mentor.iphmx.com (esa1.mentor.iphmx.com [68.232.129.153]) by sourceware.org (Postfix) with ESMTPS id 12598385840A for ; Tue, 29 Nov 2022 16:49:17 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 12598385840A Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=mentor.com X-IronPort-AV: E=Sophos;i="5.96,203,1665475200"; d="scan'208";a="91177496" Received: from orw-gwy-02-in.mentorg.com ([192.94.38.167]) by esa1.mentor.iphmx.com with ESMTP; 29 Nov 2022 08:49:16 -0800 IronPort-SDR: DV3r/ZlGVcWB4LgVXjRLZ1NrOZCq4w67g34l+ldHNAgjSAujPYaxddAAaa3NBfcdXrIOPaIYg+ 53yUEz00AGmRANdNOPFkNB7Jt/BRGTkzFIuDsWBbF962VkocwksMhV9yGFNjZYvrXYmontevA0 zPoD6yZeOqHdG6hpL9Fh+4aEvbrw2miX3TqQuHMAtBFFsqieweCG0snUsTulXlY5/ubO2tny95 z96wNqk5bxBUbLn3IaKfuOFuxQwL1OmweYadDktUjExJmm+9eJq6vAwbUAjCuvQ3NkxP/nJx1g TPs= Date: Tue, 29 Nov 2022 16:49:11 +0000 From: Joseph Myers To: Michael Matz CC: Alex Colomar , Martin Uecker , Ingo Schwarze , JeanHeyd Meneide , , Subject: Re: [PATCH] Various pages: SYNOPSIS: Use VLA syntax in function parameters In-Reply-To: Message-ID: References: <20220826210710.35237-1-alx.manpages@gmail.com> <4e3fee795769544738b3dc793aa95d6b34b72047.camel@tugraz.at> <69d694b3-756-792d-8880-87bab482ea34@codesourcery.com> <76c083af-c01f-a4b2-3df-c83075c6b0de@codesourcery.com> <75c352c-e8b5-90d0-5fae-7b211c647934@codesourcery.com> <68746776-87bf-80f9-8e3e-7392e8cef1bb@gmail.com> <77c3557f-4a62-3ede-4df4-4b2b78e265b1@codesourcery.com> <5ae032cd-7a5f-f72b-29ae-6ad7f418da8@codesourcery.com> <7931044a-b707-5a70-86c2-be298c35aa57@gmail.com> <792055f0-114d-d4bc-52f0-c242d1767c0b@gmail.com> <31e1cf34-b42f-24c5-2109-f8214c28af3e@gmail.com> <494309ce-c8ec-5219-f83e-b8dda5b9bcd1@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" X-Originating-IP: [137.202.0.90] X-ClientProxiedBy: svr-ies-mbx-10.mgc.mentorg.com (139.181.222.10) To svr-ies-mbx-10.mgc.mentorg.com (139.181.222.10) X-Spam-Status: No, score=-3109.8 required=5.0 tests=BAYES_00,HEADER_FROM_DIFFERENT_DOMAINS,KAM_DMARC_STATUS,SPF_HELO_PASS,SPF_PASS,TXREP autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On Tue, 29 Nov 2022, Michael Matz via Gcc wrote: > like. But I'm generally doubtful of this whole feature within C itself. > It serves a purpose in documentation, so in man-pages it seems fine enough > (but then still could use a different puncuator to not be confusable with > C syntax). In man-pages you don't need to invent syntax at all. You can write int f(char buf[n], int n); and in the context of a man page it will be clear to readers what is meant, though such a syntax would be problematic in actual C source files because of issues with circular dependencies between parameters and with n already being declared in an outer scope. -- Joseph S. Myers joseph@codesourcery.com