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 1wEaIC-004Anp-0L for pgsql-hackers@arkaria.postgresql.org; Sun, 19 Apr 2026 22:07:04 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1wEaIB-00GZ2H-0n for pgsql-hackers@arkaria.postgresql.org; Sun, 19 Apr 2026 22:07:03 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1wEaIA-00GZ29-32 for pgsql-hackers@lists.postgresql.org; Sun, 19 Apr 2026 22:07:02 +0000 Received: from mail-wr1-x42c.google.com ([2a00:1450:4864:20::42c]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1wEaI8-0000000225p-1w99 for pgsql-hackers@lists.postgresql.org; Sun, 19 Apr 2026 22:07:02 +0000 Received: by mail-wr1-x42c.google.com with SMTP id ffacd0b85a97d-43d64313c39so1894737f8f.3 for ; Sun, 19 Apr 2026 15:07:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1776636419; cv=none; d=google.com; s=arc-20240605; b=SEPkBoIkdS4CirIpeUDbV81Q4rFA43DJldXatYA1SjplfarGFQge/477WicqjkO1hp Pik98eEcdynPJ+hELAFqg2M2UP61EXi3aKzWTTD0cqR/JatwYwbDIyk+5XopKHJEaWc8 P+oAY8FIAPVrbSMquFPutp8ZBdGmArix/d0ZlfZSchnCnFJqz3fVdhxk6d0EjXrZRyBr lanH1F72yFvLkezpUkQ/sf74jkUibozSQiAC1X5AUmZ5W+1MVuqy6vVOsyJnIdGv76cD NNA17yzNh2Fhj9zuUqgsDLLaoPKG3yT76YlPMP+2JxTCUM3jQMQgSfn8wkY9pzMNAR/k +jQw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:dkim-signature; bh=Trmn/OWWi1pqoOJ0zxevZ+i+EidWaBv+Y8qTeXF59ew=; fh=SAutw8fA4hTnj5MS+93ERYizvcTPrUW/oE6j6OXDIe0=; b=lXtXCyHYU/3HA/yiFYmDj9tXoGcDVp+4kMqEvgGQxQCnvy6yFOtCvUHWHKebOvmNKv TndO9wGGBOUBlW3GZ1B2cmBKHhZIAIFt1FtOssOMarTY5wJPgNUlT0F7zwhJQgLhmVNS zWjQsvD/HJMW1ocnKXxImNLNRz8piHXlMRMWylCv/9P8eW5LyeRtPq8pFn13ZyoaCEB8 z2bYEVcXfSegWKjWSz48gyQ6AONRtRDpyYuFSVG9Dnw3hEOs3CJNgL2aiS+jugBOZ15+ vjSAu95cZPBf3Etp7yw/6j7s/kw7qj6oFd3SSP5z6pYZyzlNfthQgZa+k4os1u6jlOR4 Wzdg==; darn=lists.postgresql.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1776636419; x=1777241219; darn=lists.postgresql.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=Trmn/OWWi1pqoOJ0zxevZ+i+EidWaBv+Y8qTeXF59ew=; b=CjPPCciGtgRS6PQrr/oWQz8679WdEKLgmTvQPiQMkUp8XFzzefOM1HH+CqueYmmmMd x1XD/wqe64SRIiU08732ngcoFC7kCMmYPd3HCJCFfzGRXdWM1TIXb1kvqfeOfn1AoQrN YFau/dBfU043C1lYA4097QmJLyz4z1q3JkGtO9Pb3KoSvVER1oSoZsujWeTIyuDwM2XM ANeXzYG8/rVt3zXsFOVf6zc0P9+cEi3GGPYEdOk7yJ/CkZq0AGbdpGIMq+K0v/oKn4v4 dtfJ/tR/KX2OGleSe9BlDrTRIGHkUnTaOvoSnDjmoloXCz2wV61I5fv4yWWe3pMyJJDX o1Fw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1776636419; x=1777241219; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=Trmn/OWWi1pqoOJ0zxevZ+i+EidWaBv+Y8qTeXF59ew=; b=i9DO/ABr94U4I4w4vcZzv0xX3/jmrCF9PgahRkljw0cpgUnB8XaNHEiNnZ2iFVFgrn 9UVSfELAstaLbQH90WqRluuXcuhsGrgypJfz4x5AGq4AUG96YM7l+ONWbMNp4/8U6qzr GdqbnfyFyfvw4x/AD/19Jdxh5ZMx1E2TchomdcrPmT4JQoM3b58k3c7191m7ihMmJU2T 4/SSR0RKaY58UEgWgMUnG/sFwpKG+87sSxVrHZh1wS4mm1beUkvi2kBjgFcoYsWjFZ8Y gzv8y6tWazHb7bgYmuaNdthBeKCXL/GG2mFhoDqkhQZ0k+iE+qQQWKyW9yczuCA2nJXe KDMw== X-Forwarded-Encrypted: i=1; AFNElJ/rJJYrtxEGF3BpdPRE+WFeymQDCfcpuiJmI7iThvNOTUWWpTpt/NoRnlIr6vfg8q6Ms8dwF6XIMcoBYwge@lists.postgresql.org X-Gm-Message-State: AOJu0YxJkXYqGpFS0iFozrkNCOKzwdn/YC++hJZLA53MJFZEQXox9Nux 2p6Yq5H2tgJIxUGROE3WOZQMYsSBKPnGOyaxhldJPUADj249UCO3VgUKQ4MP9B1Y9YC19DM7tbt Ng8rffrf3k88CEStYWVasERsj+T2L3SA= X-Gm-Gg: AeBDiesf5EGkPhVGUF1tdl+GNjza/VMqinl3A1kqJ3cnUagAdBR3go8t4KGSC6bJeYJ hr5D2QyeVQ7RoyeKW1cS30scqQHS9bpJ9lTXedlxmukER0B+vVOemFrEwW/fxROAGS3fe6GnP55 k7tyOZJgsG3btfG9G70peNIfhi0PWvx6SZNXQGipjlA3iKybtEnBn59DmhpwDjPfB3+zZD8A/cS T8C1yC4pOLXgIQAG/vRaQRITLLS7dGZ34IwWfVCGt5oM5pfVVL+KrM+cSesO0tnVohsZVHYftCK /JmotoSBX2vzRPMTzhZ/bWlfW27ZyrRoQOtDTx/LK01XJ7G0VvO46KBMayd6WN5NK5XGa3v/FSs 4Lm0aJmSp X-Received: by 2002:adf:f40d:0:b0:43f:e840:eaff with SMTP id ffacd0b85a97d-43fe840eb3cmr9469717f8f.46.1776636418941; Sun, 19 Apr 2026 15:06:58 -0700 (PDT) MIME-Version: 1.0 References: <2D90FFB0-C80A-4189-A5BF-C37F05E271D7@greg.burd.me> In-Reply-To: From: David Rowley Date: Mon, 20 Apr 2026 10:06:46 +1200 X-Gm-Features: AQROBzCrHcayjkmk_tnLR3O21ceWn7bZRNRqo9TWjejFqfizOW5VRqH8AzEEiqM Message-ID: Subject: Re: [PATCH] Add tests for Bitmapset To: Michael Paquier Cc: Greg Burd , Ranier Vilela , Daniel Gustafsson , PostgreSQL Hackers Content-Type: text/plain; charset="UTF-8" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Mon, 20 Apr 2026 at 09:38, Michael Paquier wrote: > > On Sat, Apr 18, 2026 at 09:06:02PM +1200, David Rowley wrote: > > 2. Doing #1 means the function can't be STRICT. I do think it's wrong > > that the function is marked as strict. That's normally reserved for > > functions that we needn't call because NULL input(s) yield a NULL > > output. That's not the case for this function. > > Using the existing HEAD approach where STRICT avoids these extra NULL > checks, or adding explicit NULL checks without STRICT does not strike > me as a big difference in this context. I had to remove STRICT to allow NULL to be passed for the seed. When I first modified test_bitmapset.c to only choose a random seed when it received NULL, I thought it was strange that the function appeared to return NULL. It took me a minute to realise I was getting the STRICT NULL short-circuiting. > > I felt it was worth fixing these now as the function I plan to add > > there does #1, #2, #3 and #4. If I add the new function for v20, the > > discrepancy seems questionable. > > It is a test module, it would be a big issue if new pieces are > backpatched in this area. In short I'm fine with these. Thanks for > asking. Did you mean "wouldn't"? Thanks for looking. I pushed before I saw your reply. David