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 1oBLsl-0003f0-TN for pgsql-hackers@arkaria.postgresql.org; Tue, 12 Jul 2022 19:49:19 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1oBLsj-0004Tq-TD for pgsql-hackers@arkaria.postgresql.org; Tue, 12 Jul 2022 19:49:17 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oBLsj-0004Tc-Kg for pgsql-hackers@lists.postgresql.org; Tue, 12 Jul 2022 19:49:17 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oBLsh-0004vt-Cg for pgsql-hackers@postgresql.org; Tue, 12 Jul 2022 19:49:16 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 26CJnB2O1739896; Tue, 12 Jul 2022 15:49:11 -0400 From: Tom Lane To: Peter Eisentraut cc: Andres Freund , David Rowley , pgsql-hackers Subject: Re: automatically generating node support functions In-reply-to: <101171fc-da4c-7799-991d-65ad84f53d7d@enterprisedb.com> References: <1294462.1656875649@sss.pgh.pa.us> <57df9f30-d2cf-9126-28d4-ae40a2e733a9@enterprisedb.com> <1593978.1656953960@sss.pgh.pa.us> <2592455.1657140387@sss.pgh.pa.us> <3302658.1657288366@sss.pgh.pa.us> <611d2e! 93-6330-47fa-0970-72316aed50f2@enterprisedb.com> <3488143.1657310625@sss.pgh.pa.us> <11148777-fbe2-5188-195d-48f5083573c5@enterprisedb.com> <20220710214622.haiektrjzisob6rl@awork3.anarazel.de> <815831.1657494597@sss.pgh.pa.us> <45f508cb-e30b-c252-e081-4548deafa34c@enterprisedb.com> <1116889.1657553859@sss.pgh.pa.us> <1201553.1657562258@sss.pgh.pa.us> <101171fc-da4c-7799-991d-65ad84f53d7d@enterprisedb.com> Comments: In-reply-to Peter Eisentraut message dated "Tue, 12 Jul 2022 21:03:47 +0200" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <1739894.1657655351.1@sss.pgh.pa.us> Date: Tue, 12 Jul 2022 15:49:11 -0400 Message-ID: <1739895.1657655351@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Peter Eisentraut writes: > On 11.07.22 19:57, Tom Lane wrote: >> So at this point I'm rather attracted to the idea of reverting to >> a manually-maintained NodeTag enum. We know how to avoid ABI >> breakage with that, and it's not exactly the most painful part >> of adding a new node type. > One of the nicer features is that you now get to see the numbers > assigned to the enum tags, like > T_LockingClause = 91, > T_XmlSerialize = 92, > T_PartitionElem = 93, > so that when you get an error like "unsupported node type: %d", you can > just look up what it is. Yeah, I wasn't thrilled about reverting that either. I think the defenses I installed in eea9fa9b2 should be sufficient to deal with the risk. regards, tom lane