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 1nPRy1-0001pq-PP for pgsql-hackers@arkaria.postgresql.org; Wed, 02 Mar 2022 16:36:45 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1nPRy0-0000zU-Ly for pgsql-hackers@arkaria.postgresql.org; Wed, 02 Mar 2022 16:36:44 +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 1nPRy0-0000zL-Av for pgsql-hackers@lists.postgresql.org; Wed, 02 Mar 2022 16:36:44 +0000 Received: from mail-pf1-x42b.google.com ([2607:f8b0:4864:20::42b]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1nPRxy-00047h-5S for pgsql-hackers@lists.postgresql.org; Wed, 02 Mar 2022 16:36:44 +0000 Received: by mail-pf1-x42b.google.com with SMTP id d187so2380879pfa.10 for ; Wed, 02 Mar 2022 08:36:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=6fYnvHRPdeHiHJvjRx5vKRTuO8b+p/Bw5sMRepRb+X8=; b=XCmhnuXNLOn8ICQdvi1GZhJ54abFw09mCgYTOb2vYbdnG4dQDcE1ZAxqy9vEWermCz DW8fMoR2TKj40lNJi10miRn16h8A0d8QMtlGBY+oUxqyHzMyN73/decTJ7xFmqPcPTW1 hatcP768nkmQ8wV+1uf+HG27IthPCxBSZTTq5ptANrEOrnSYwHpZLxITDQPff6ezZkCl dM6ylSH9Vu4K/PvxYHH8zIiFDd6qAEcb2mO7WFR6xffK7S2Gzi1tGg6F0U/u6NE3dXVy wMpatA+mmbUp6AlUkGlRUlJ/nioEl0REtkFyqe1suSrmrrd9RZPGwVDNoLaybzx59blR Hzxg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=6fYnvHRPdeHiHJvjRx5vKRTuO8b+p/Bw5sMRepRb+X8=; b=OSmlX+bfuI3eW72J1uViI5wb7jwZ0ELUQcO951yHFDPe+YUNgLjm5Y7/VkFgxb0JpI EcW92FOlm7kVP4zg95GbmbswxDmr6a8Bt+Q4lXydGthwELM8g8nnJ+MxOQ7ynqD59+pv WI01wftsUb9Nu/z6p2GB2jhWAcRpJlhjXx8RleePZIdEJgMPspa6FH4btap2+JvylyDJ uKuJ+rJxc0dO89vDCyP7EsiAHLbA8GNQrOFzHm80CiLeDXfYSIoM697vTjghi9HXOr1c UViGjtQQw8CMctOmyu5dO2JOeibh6xkfWpq1le4Yl3ASCG+adDS6lk9vmiGFlCpdCIXg BpCA== X-Gm-Message-State: AOAM5302mfPLq/lDg9D7v8bzQd6ltFfaQdWnWIpGDKji6QAqC6HmOV37 9wq6uLY34h0Mn84i+3gvbME= X-Google-Smtp-Source: ABdhPJwS/tX32/Seh4W0rhKEmea9tcr1CG3kYlg0YBVgL7U8kxvQBo/XtaDWnSV7Scf173ZY1UDfww== X-Received: by 2002:a05:6a00:244b:b0:4c9:319e:ecb7 with SMTP id d11-20020a056a00244b00b004c9319eecb7mr33752537pfj.58.1646238999984; Wed, 02 Mar 2022 08:36:39 -0800 (PST) Received: from jrouhaud (2001-b011-1005-3127-25f1-7473-0faa-af8a.dynamic-ip6.hinet.net. [2001:b011:1005:3127:25f1:7473:faa:af8a]) by smtp.gmail.com with ESMTPSA id m6-20020a62f206000000b004e152bc0527sm21253341pfh.153.2022.03.02.08.36.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 02 Mar 2022 08:36:39 -0800 (PST) Date: Thu, 3 Mar 2022 00:36:32 +0800 From: Julien Rouhaud To: Aleksander Alekseev Cc: Tom Lane , Robert Haas , Michael Paquier , Kyotaro Horiguchi , PostgreSQL Hackers Subject: Re: pg_stop_backup() v2 incorrectly marked as proretset Message-ID: <20220302163632.6ppfefpw4usen6z5@jrouhaud> References: <20220302.172235.1181597714315490061.horikyota.ntt@gmail.com> <2976202.1646231744@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Wed, Mar 02, 2022 at 05:40:00PM +0300, Aleksander Alekseev wrote: > Hi Tom. > > Yeah, there's plenty of precedent for that coding if you look around. > > I've not read the whole patch, but this snippet seems fine to me > > if there's also an #undef at the end of the function. > > No, there is no #undef. With #undef I don't mind it either. I don't see strong evidence for that pattern being wildly used with some naive grepping: #define for such use without undef: POSTGRES_FDW_GET_CONNECTIONS_COLS HEAP_TUPLE_INFOMASK_COLS CONNECTBY_NCOLS DBLINK_NOTIFY_COLS PG_STAT_STATEMENTS_COLS PG_STAT_STATEMENTS_INFO_COLS HEAPCHECK_RELATION_COLS PG_PARTITION_TREE_COLS PG_STAT_GET_ACTIVITY_COLS PG_STAT_GET_WAL_COLS PG_STAT_GET_SLRU_COLS PG_STAT_GET_REPLICATION_SLOT_COLS PG_STAT_GET_SUBSCRIPTION_STATS_COLS PG_GET_BACKEND_MEMORY_CONTEXTS_COLS PG_GET_SHMEM_SIZES_COLS PG_GET_REPLICATION_SLOTS_COLS READ_REPLICATION_SLOT_COLS PG_STAT_GET_WAL_SENDERS_COLS PG_STAT_GET_SUBSCRIPTION_COLS With an undef: REPLICATION_ORIGIN_PROGRESS_COLS