Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nlJCW-0005wb-9w for pgsql-hackers@arkaria.postgresql.org; Sun, 01 May 2022 23:42:04 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1nlJCT-0005xH-KC for pgsql-hackers@arkaria.postgresql.org; Sun, 01 May 2022 23:42:01 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nlJCT-0005x8-9L for pgsql-hackers@lists.postgresql.org; Sun, 01 May 2022 23:42:01 +0000 Received: from mail-io1-xd2e.google.com ([2607:f8b0:4864:20::d2e]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1nlJCQ-0000ui-OP for pgsql-hackers@postgresql.org; Sun, 01 May 2022 23:42:00 +0000 Received: by mail-io1-xd2e.google.com with SMTP id e15so14749128iob.3 for ; Sun, 01 May 2022 16:41:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:from:date:message-id:subject:to; bh=3vAJkVOfCc4o/lcFFoJibIFQA3GXvDsHqpSvSCh97UQ=; b=BbN5mCvm0yqaSSVaAGQea2nd4MmVCO739Qy6EILW2RXCbcJ3tPOOAO6oxOAoh3U7sG GNozHm0v91ADfK/mYM0bRQapST9wkwHFOwU03GkKvXUCT+mpQdXq58rNL9INsbsj6kDQ s6HXFUY6lfgW3MeWOAaYitRvgjQQ55f+5XF9wxRHQuXCeUBH90TnYWE1DEWC6P6HKfZz BheZvs2YL/da7s7uhH03kiifQKvBYA4gXfPkocQ/G92riN52K/P+gwhMjqDnZdqz225p kfYIYtj7e3FQbXv8pfgz7EFteHkaOR7x+8WdCGSMWe9147Yv8xOpYtGAtXHsVlM1JmB9 Re4Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=3vAJkVOfCc4o/lcFFoJibIFQA3GXvDsHqpSvSCh97UQ=; b=kUbOZV9VWPI5CgIQxPFo3xmUkBjwR9AZ8oJxXg9sKEZA1PfYazA0Sxj9pAyOEbkYDa 5ww07sAby19/6rjEkhlb1q0/SDaOkmxmaxcb3A9SwLRs8glcF/tFgvxtX0a0hlOSIWLW W0mRcHDaAZ4ZT0YGUJzmobw5BlApVy+4smmdGRA0vH+NuEQgwT+H13aWh5lvTlaDuBSo pGUEulBut/HSyRzJPgZ6UxHGwn9CuEVQwAAAryt3lFVmGr1D6rO1mYKGdD9W68zZ1jR5 gi/52FRfLfHlH4X1BdFYQwO3vNCqgnJ7B119knI/stxfz2EdA98vbDL7UclbluXisb/6 vL4w== X-Gm-Message-State: AOAM533dxzjRw3kAB4BNpB1dVOu81Hypd2c3A71LRMERkXuYDC73tEzQ wc2Blwm4YiCxFp8Ehu3UqN/+NinfT9m83I8AAnyufD7zsv+ror5X X-Google-Smtp-Source: ABdhPJwa0n5yxsS7O5MoD8kNUvhcl4Znp+rpMMk0x2pzz6bsFDx3/8touGTMQs0Up5LIKR/FOI6bDU0qjLnXGSpBzPY= X-Received: by 2002:a05:6602:3c7:b0:64f:cb21:a8a0 with SMTP id g7-20020a05660203c700b0064fcb21a8a0mr3420883iov.28.1651448516216; Sun, 01 May 2022 16:41:56 -0700 (PDT) MIME-Version: 1.0 From: Thomas Munro Date: Mon, 2 May 2022 11:41:20 +1200 Message-ID: Subject: Tree-walker callbacks vs -Wdeprecated-non-prototype To: pgsql-hackers Content-Type: text/plain; charset="UTF-8" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hi, As visible on seawasp (and noticed here in passing, while hacking on the opaque pointer changes for bleeding edge LLVM), Clang 15 now warns by default about our use of tree walkers functions with no function prototype, because the next revision of C (C23?) will apparently be harmonising with C++ in interpreting f() to mean f(void), not f(anything goes). nodeFuncs.c:2051:17: warning: passing arguments to a function without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype] return walker(((WithCheckOption *) node)->qual, context); Discussion trail: https://reviews.llvm.org/D123456 https://discourse.llvm.org/t/rfc-enabling-wstrict-prototypes-by-default-in-c/60521 http://www.open-std.org/jtc1/sc22/wg14/www/docs/n2841.htm Not sure where to see the official status of N2841 (other than waiting for the next draft to pop out), but on random/unofficial social media I saw that it was accepted in February, and the Clang people apparently think it's in and I also saw a rumour that bleeding edge GCC takes this view if you run with -std=c2x (not tested by me).