Path: ...!3.eu.feeder.erje.net!feeder.erje.net!news2.arglkargh.de!news.karotte.org!fu-berlin.de!uni-berlin.de!not-for-mail From: ram@zedat.fu-berlin.de (Stefan Ram) Newsgroups: comp.lang.c Subject: Re: is it possible to have functions with 0, 1, or 2 args? Date: 5 Aug 2024 09:45:37 GMT Organization: Stefan Ram Lines: 7 Expires: 1 Jul 2025 11:59:58 GMT Message-ID: References: <7q-dnbTDU4oBES37nZ2dnZfqnPednZ2d@brightview.co.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Trace: news.uni-berlin.de qau2e28Qdx2SpSPgvZgjkwWIrsVfOzjzSn8c3/6qLkAHv3 Cancel-Lock: sha1:VXUz0mj2YbwrLSpacS5gM9cOiK0= sha256:Obw0AdnIqdab1GCDvd/8AlzED4XNV63CqsSz3HXXZr0= X-Copyright: (C) Copyright 2024 Stefan Ram. All rights reserved. Distribution through any means other than regular usenet channels is forbidden. It is forbidden to publish this article in the Web, to change URIs of this article into links, and to transfer the body without this notice, but quotations of parts in other Usenet posts are allowed. X-No-Archive: Yes Archive: no X-No-Archive-Readme: "X-No-Archive" is set, because this prevents some services to mirror the article in the web. But the article may be kept on a Usenet archive server with only NNTP access. X-No-Html: yes Content-Language: en-US Bytes: 1866 ram@zedat.fu-berlin.de (Stefan Ram) wrote or quoted: >#define NARGS(...) NARGS_(__VA_ARGS__, 5, 4, 3, 2, 1, 0) Up top, C's totally buggin' about the diff between one argument and zilch, 'cause that comma in "__VA_ARGS__," is always chillin' there. We could 86 it with the fresh "__VA_OPT__(,)", but not all C implementations are down to clown with that yet . . .