Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1vmsSH-00HIOz-2V for pgsql-hackers@arkaria.postgresql.org; Mon, 02 Feb 2026 11:50:57 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1vmsSF-00DfXj-2o for pgsql-hackers@arkaria.postgresql.org; Mon, 02 Feb 2026 11:50:56 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1vmsSF-00DfXa-14 for pgsql-hackers@lists.postgresql.org; Mon, 02 Feb 2026 11:50:56 +0000 Received: from fout-b6-smtp.messagingengine.com ([202.12.124.149]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1vmsSE-00000000Bed-1S3s for pgsql-hackers@lists.postgresql.org; Mon, 02 Feb 2026 11:50:55 +0000 Received: from phl-compute-03.internal (phl-compute-03.internal [10.202.2.43]) by mailfout.stl.internal (Postfix) with ESMTP id 2C81D1D0011C; Mon, 2 Feb 2026 06:50:53 -0500 (EST) Received: from phl-frontend-03 ([10.202.2.162]) by phl-compute-03.internal (MEProxy); Mon, 02 Feb 2026 06:50:53 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kurilemu.de; h= cc:cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :reply-to:subject:subject:to:to; s=fm1; t=1770033052; x= 1770119452; bh=kEICaLEYg6ePxGZzMAoZz6HGif+Z6csrBDddkg2ThsA=; b=D AE38O33k2ECl2hn4cXRJV5aTt5NSYKveFOKpP6MTiYgiQL9yqB0j4EAXWglHGsRz fqprxfkQd6DcSh0Q2rTVluUU6U4YmH5BLUUHrNfY+7Y91uDkSUoMzCWhyunIeoMk PcQKwUVNBQC7j/3NmxKc6nmpsmxXwpi2ZbLb0MwyFPGevIp7MgEQa1jl/HJSv8YT y8lg4MUlGg16+S6pnLw6uNzXD+b+GqZNUZQnviLBSEe7q4/YW+862to59rYpMjci x0W1gAUcngRwmR0zxEcRwCEf0JaR/TymgloL0EJ858vgEvUvsO/Pz+nclptSFxvy 9SlVcuH9oJUIB+5IwMeTA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :reply-to:subject:subject:to:to:x-me-proxy:x-me-sender :x-me-sender:x-sasl-enc; s=fm3; t=1770033052; x=1770119452; bh=k EICaLEYg6ePxGZzMAoZz6HGif+Z6csrBDddkg2ThsA=; b=TapcmqjII9+KI1f21 S2iRiCNheaT0y3L7ZriVUINV/T2F529DUf7XBLtyIMCb+Fkn9dZdWTHG4p38/AeS OcNBk5ra7QV/qNgssDC4/4abg2v9+OoPFCylkGJ6MVTBdU5RPWmFBzcLR2GmFWNk UPSf201k8y8nq1Fc1pVy2JfAjjVM94j932n/+1EnTZoHmN4V+44b7SeW1u3XK1ED c/gRQWMxYxj62kBRLo2/GIECRJdcEW2lfjRp4hn5zbcSzd99SQfbVqEXMNZPl+O5 pAWaQaeNvdUIsfPGyepAqHtJKrQ+hneF8P+LZO4DswkZu3xAag6G49qE1mYrr4nM T8BxA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefgedrtddtgddujeejheeiucetufdoteggodetrf dotffvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfurfetoffkrfgpnffqhgenuceu rghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujf gurhepfffhvfevuffkgggtugfgjgesthekredttddtjeenucfhrhhomheplmhlvhgrrhho ucfjvghrrhgvrhgruceorghlvhhhvghrrhgvsehkuhhrihhlvghmuhdruggvqeenucggtf frrghtthgvrhhnpeetuedvheffkeevgfeuheevteevkefggedttdeufeeuheduuddthfef fffhjeefffenucffohhmrghinhepvghnthgvrhhprhhishgvuggsrdgtohhmnecuvehluh hsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomheprghlvhhhvghrrhgv sehkuhhrihhlvghmuhdruggvpdhnsggprhgtphhtthhopedvpdhmohguvgepshhmthhpoh huthdprhgtphhtthhopehlihdrvghvrghnrdgthhgrohesghhmrghilhdrtghomhdprhgt phhtthhopehpghhsqhhlqdhhrggtkhgvrhhssehlihhsthhsrdhpohhsthhgrhgvshhqlh drohhrgh X-ME-Proxy: Feedback-ID: ie3de48e3:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 2 Feb 2026 06:50:52 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kurilemu.de; s=schmee; t=1770033050; bh=XRSyTuyHfNnRU8H7Mo2GabIzO0L9C6390UgRcPibECI=; h=Date:From:To:Cc:Subject:In-Reply-To:From; b=DSG51M2I7wEUWmry825mYyIRtZnRnHeYjbCic4tlDwdtDRhRB8o337lz5AelvoN+d kyc4z+yTg2o5f7YV542m9NEf6tKUnsXn63c0J8FnJyqhlFDIq/KVqS8Hr9wPvu22Tw HNFx4/+w8MyRdsPXsS7CbVV5tZLbhgXkviZu/G2Mf/GkOl+ScvMAhikLI3nk65q9NH rJQ2T4hsRmoymJeiq+KyvCnuZ08IApR+9ul1/IPWyy5xGFiRLlVd4zCWyOhJnZ6n87 CY2E/U87RqsZHpCm8rn5gNOcFQOLH5eMuBrifiL9PlHXKcJovKGFSJsFyVbnnISand T3Ayr8O4xwJXg== Received: by schmee.kurilemu.internal (Postfix, from userid 1000) id 5198874; Mon, 02 Feb 2026 12:50:50 +0100 (CET) Date: Mon, 2 Feb 2026 12:50:50 +0100 From: =?utf-8?Q?=C3=81lvaro?= Herrera To: Chao Li Cc: Pg Hackers Subject: Re: splitting pg_resetwal output strings Message-ID: <202602021142.4zhge2fn4xt7@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hello Evan, On 2026-Feb-02, Chao Li wrote: > I don't think we necessarily need to add a simple_int_list. Since OIDs > are not globally unique across all object types, we can reasonably > treat ControlData items as "objects" and assign them OIDs within this > context. > > If we take that approach, the enum could be named ControlDataOid: > ``` > /* Define the string enums */ > #define CONTROLDATA_LINE(symbol, description, fmt, ...) \ > symbol, > enum { > #include "entries.h” > } ControlDataOid; > #undef CONTROLDATA_LINE > ``` > > This makes reusing simple_oid_list feel appropriate. True, but that's a bit cheating with the naming. Really, type Oid is related to identifying database objects, that is, what is used in each catalog row. Someday we may want to decide to enlarge that to 64 bits, and if that happens and yet the C compiler continues to use 32-bit integers to implement C-level enums, which is what this patch uses, what then? If I go with just simple_int_list, then that's always (by definition) going to be a C integer, which is (presumably) always going to be what the C compiler uses to implement a C enum. (I think in reality we're unlikely to change Oid to be 64-bit, because there's no reason to do so since it's quite unusual to have such very many database objects. I think it's more likely that we'd change the type that underlies TOAST pointers, which is where the real problem with Oid resides. Even so, it seems ... dangerous? ... to me to do what you propose.) > If you aren't fond of that idea, I’d suggest naming the enum > ControlDataSymbol rather than ControlDataStrings, as the former better > reflects what the members actually are. Yeah, this is probably a good idea anyway, given that these objects are not strings anymore. Thanks for the review! -- Álvaro Herrera Breisgau, Deutschland — https://www.EnterpriseDB.com/