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 1vkJqt-00DasB-1j for pgsql-hackers@arkaria.postgresql.org; Mon, 26 Jan 2026 10:29:48 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1vkJqs-007Qw6-1x for pgsql-hackers@arkaria.postgresql.org; Mon, 26 Jan 2026 10:29:46 +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 1vkJqs-007Qvy-10 for pgsql-hackers@lists.postgresql.org; Mon, 26 Jan 2026 10:29:46 +0000 Received: from fhigh-b2-smtp.messagingengine.com ([202.12.124.153]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1vkJqq-002NUs-0R for pgsql-hackers@lists.postgresql.org; Mon, 26 Jan 2026 10:29:45 +0000 Received: from phl-compute-08.internal (phl-compute-08.internal [10.202.2.48]) by mailfhigh.stl.internal (Postfix) with ESMTP id 4EFA67A0128; Mon, 26 Jan 2026 05:29:44 -0500 (EST) Received: from phl-frontend-04 ([10.202.2.163]) by phl-compute-08.internal (MEProxy); Mon, 26 Jan 2026 05:29:44 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eisentraut.org; h=cc:cc:content-transfer-encoding:content-type:content-type :date:date:from:from:in-reply-to:in-reply-to:message-id :mime-version:references:reply-to:subject:subject:to:to; s=fm1; t=1769423384; x=1769509784; bh=3WofpqLE4GZHul/GWpynyjTuuoYECDeB 8ZweVuQO4HQ=; b=LiSlurYPC1zSoBB0SwERit5Q73MXgahqAYc1UPFZ89ZtFvuA zh5xz9THZLbbkLVrtfee1+l1wMI+G3mCuFjMb1KhQV3OUU5/uudLsyKp4rYCubDx z9lys9ziacTQJEUKp4vUbJHuknWhOA5qNz5KSTRnpQ0IbpItPzAvDsA5klw7eOfg Pcyi505jBPXTNLoCRGA47dI8kvzBcw1gRs/+iy+WwVNgGbS8/4r5qEWjVKrI/1Z+ UwUZ0PeSRfpJ7LqvP5uaCwvHjTMR4aUtzRyyn4JKpHbLA7lCuU6zn0BgukcPON36 GKSp6OEZjefzGDVCNwWL71JdfEiWRTbqEgzJ4A== 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 :references:reply-to:subject:subject:to:to:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm2; t=1769423384; x= 1769509784; bh=3WofpqLE4GZHul/GWpynyjTuuoYECDeB8ZweVuQO4HQ=; b=C 7GkT+DAwHALnsGrTPSyUfKrBTnphBsPniilHOukrOc7lmOvJmR/HN6KwVtKFNB2l q3Q93IZ4dx4VjF09ebNm/3HeD4OKwlnHLUywYmHSc64ZuRQqbgsepWlT1vND/lGy mefD3O0ERmTfSG9QAclhzj3usrwRyEna8aS2pWCMuchKHGRirE/GEhzqyhqVKW6W r1U9xWcpxrZEzW/2eP4SvrhK3HPAWVeOLLutsqX0NuEvuwvVpp4X4rSb61XrFkZ0 rtoASJdN03phmmq5brQKyvUO1I43+Fz1T0FcjVGSsMpK71zrrQG2FKKMbu+6vlId sLXPhdB22YFK1xlZxNC8A== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefgedrtddtgdduheejgeefucetufdoteggodetrf dotffvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfurfetoffkrfgpnffqhgenuceu rghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujf gurhepkfffgggfuffvvehfhfgjtgfgsehtjeertddtvdejnecuhfhrohhmpefrvghtvghr ucfgihhsvghnthhrrghuthcuoehpvghtvghrsegvihhsvghnthhrrghuthdrohhrgheqne cuggftrfgrthhtvghrnhepgfejtdfhkeeftdeugfeileehteeljeeghfeuledthfeutedv ffdukeefjefhgeehnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilh hfrhhomhepphgvthgvrhesvghishgvnhhtrhgruhhtrdhorhhgpdhnsggprhgtphhtthho peegpdhmohguvgepshhmthhpohhuthdprhgtphhtthhopehpohhsthhgrhgvshesjhgvlh htvghfrdhnlhdprhgtphhtthhopegrnhgurhgvshesrghnrghrrgiivghlrdguvgdprhgt phhtthhopehpghhsqhhlqdhhrggtkhgvrhhssehlihhsthhsrdhpohhsthhgrhgvshhqlh drohhrghdprhgtphhtthhopehthhhomhgrshdrmhhunhhrohesghhmrghilhdrtghomh X-ME-Proxy: Feedback-ID: ie0a040ee:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 26 Jan 2026 05:29:43 -0500 (EST) Message-ID: Date: Mon, 26 Jan 2026 11:29:42 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: Make copyObject work in C++ To: Jelte Fennema-Nio , Andres Freund Cc: PostgreSQL Hackers , Thomas Munro References: <4d8b9e53-3f37-43f0-a4aa-5bda9c7961b3@eisentraut.org> <4e82f77b-acad-4356-94f6-8255135fb36b@eisentraut.org> Content-Language: en-US From: Peter Eisentraut In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 25.01.26 18:52, Jelte Fennema-Nio wrote: > On Sun Jan 25, 2026 at 5:50 PM CET, Andres Freund wrote: >> I'm pretty sceptical this is the right direction. > > The only other option I can think of is not supporting C++ extension on > MSVC unless they are compiled with C++20 (or later). I don't > particularly care about Windows C++ extensions myself, so I personally > would be fine with that choice. It seems a bit harsh, though. Maybe it would be enough to only support PG_MODULE_MAGIC (without arguments) in C++ for now. That would still require removing the named initializers inside PG_MODULE_MAGIC_DATA(), but that's only an internal change, and it would not affect C-language users of PG_MODULE_MAGIC_EXT, and we wouldn't lock ourselves into a particular style in C++. Then, maybe in a couple of years, when C++20 is more widely available, we could enable PG_MODULE_MAGIC_EXT for C++, or design an alternative construct for C++.