From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id 0T7WAcKx4GoiXy8AWB0awg (envelope-from ) for ; Tue, 27 Oct 2026 10:14:26 -0400 Authentication-Results: simark.ca; dkim=fail reason="signature verification failed" (768-bit key; unprotected) header.d=tromey.com header.i=@tromey.com header.a=rsa-sha256 header.s=default header.b=l/B5UF8D; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id 0319D378002; Tue, 27 Oct 2026 10:14:26 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-3.8 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, DKIM_INVALID,DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_BL_SPAMCOP_NET, RCVD_IN_DNSWL_MED autolearn=ham autolearn_force=no version=4.0.1 Received: from vm01.sourceware.org (vm01.sourceware.org [38.145.34.32]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id 5B234378002 for ; Tue, 27 Oct 2026 10:14:25 -0400 (EDT) Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 95B524BA7998 for ; Tue, 27 Oct 2026 14:14:24 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 95B524BA7998 Authentication-Results: sourceware.org; dkim=fail reason="signature verification failed" (768-bit key, unprotected) header.d=tromey.com header.i=@tromey.com header.a=rsa-sha256 header.s=default header.b=l/B5UF8D Received: from omta040.useast.a.cloudfilter.net (omta040.useast.a.cloudfilter.net [44.202.169.39]) by sourceware.org (Postfix) with ESMTPS id 2B78C4BA798C for ; Tue, 27 Oct 2026 14:13:49 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 2B78C4BA798C Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=tromey.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=tromey.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 2B78C4BA798C Authentication-Results: sourceware.org; arc=none smtp.remote-ip=44.202.169.39 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1793110429; cv=none; b=In5nbiVrInQvMDHwJlWqaopOXwwpb1CODQxC3yvbuh2LKNJQFD/dwatnFVFKtdoiRZnrBmNbylXhzFcNdxxNo4pTJ0E3iCmqqmPDb2slrAJpBe2gzGlXpmvnFaJHrh7TmmurfoQlcIAg1hznx+S7s+WYvG6nPZTrQwJjLYUFJW0= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1793110429; c=relaxed/simple; bh=R+fB9IHsQi9J6YsugsYgO42sHJLfXmtE14DNfKZXGFw=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=TmL/GasplBTG6mQ0QzZmumbtQ9Kg8KekEI6176y9nsNK/Zk5t+xvP40i0lxuKVtD/Hc6ZfFg7BENknjkgf46wHsbAYHsbyYoicNeoK0TcHYWOXqlCVGJj7/dbDR5Oz3BdpPk7E6DDmtdYD/vqyeGeu3pz0bsbABdf2ROzmp4mjo= ARC-Authentication-Results: i=1; sourceware.org; dkim=policy (768-bit key, unprotected) header.d=tromey.com header.i=@tromey.com header.a=rsa-sha256 header.s=default header.b=l/B5UF8D reason="signing key too small" DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 2B78C4BA798C Received: from eig-obgw-5003b.ext.cloudfilter.net ([10.0.29.155]) by cmsmtp with ESMTPS id LfZyxzbnIMylkLhvwxAi1T; Tue, 27 Oct 2026 14:13:48 +0000 Received: from box5379.bluehost.com ([162.241.216.53]) by cmsmtp with ESMTPS id LhvuxU9ODf4wOLhvvx12Al; Tue, 27 Oct 2026 14:13:47 +0000 X-Authority-Analysis: v=2.4 cv=db2A3WXe c=1 sm=1 tr=0 ts=6ae0b19c a=ApxJNpeYhEAb1aAlGBBbmA==:117 a=ApxJNpeYhEAb1aAlGBBbmA==:17 a=660iZSQnnn4A:10 a=ItBw4LHWJt0A:10 a=7d_E57ReAAAA:8 a=wMIeW3GtmWWYCi0fi9wA:9 a=jhqOcbufqs7Y1TYCrUUU:22 a=DCx65vhANUyCzuf5D8fC:22 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; h=Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To :Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Unsubscribe-Post: List-Subscribe:List-Post:List-Owner:List-Archive; bh=Cq8oqqSZM8/qjMSVjJCyrQCxHYb84Ef2aCIkTjgChOY=; b=l/B5UF8DlspNHSbkfsCfPmZK3M mGecaZCceYZWF6K2HZAWxvC2B+arzojsNFTyA4iAoQgP+bdMPn3q8KbkNuF8SZYRXkw7Qmy1WqucF vhngr3E1bMZ3E8Dw+FbLYlYt/; Received: from 97-122-110-129.hlrn.qwest.net ([97.122.110.129]:32878 helo=bapiya) by box5379.bluehost.com with esmtpsa (TLS1.3) tls TLS_AES_256_GCM_SHA384 (Exim 4.100.1) (envelope-from ) id 1xLhvu-00000001MyD-2OHo; Tue, 27 Oct 2026 08:13:46 -0600 From: Tom Tromey To: Simon Marchi Cc: gcc-patches@sourceware.org, gdb-patches@sourceware.org Subject: Re: [PATCH 5/6] gdbsupport/selftest: print operand values when a SELF_CHECK fails In-Reply-To: <20261019165929.792697-6-simon.marchi@efficios.com> (Simon Marchi's message of "Mon, 19 Oct 2026 12:58:21 -0400") References: <20261019165929.792697-1-simon.marchi@efficios.com> <20261019165929.792697-6-simon.marchi@efficios.com> X-Attribution: Tom Date: Tue, 27 Oct 2026 08:13:45 -0600 Message-ID: <87qzhbp6xy.fsf@tromey.com> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - box5379.bluehost.com X-AntiAbuse: Original Domain - sourceware.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - tromey.com X-BWhitelist: no X-Source-IP: 97.122.110.129 X-Source-L: No X-Exim-ID: 1xLhvu-00000001MyD-2OHo X-Source: X-Source-Args: X-Source-Dir: X-Source-Sender: 97-122-110-129.hlrn.qwest.net (bapiya) [97.122.110.129]:32878 X-Source-Auth: tom+tromey.com X-Email-Count: 6 X-Org: HG=bhshared;ORG=bluehost; X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTM3OS5ibHVlaG9zdC5jb20= X-Local-Domain: yes X-CMAE-Envelope: MS4xfEepyA3cgAbWifJOVH24HCLCZMCCb0fxcu3MM8Zu32vfdt30iu9xyUL9rtllU8QmFu9VQEX9Uop9w3iHvxOX7KJIDoQzUqwXyuMd8o64eBHqsQyGrDqy SptPYDmFRAllUN373AA1YAXad/W4Znkek/B+h1qHjpGWagfErop+PG1/58UatEChUBs4UkLTVDUVWq0LyxO9wRg3DEREf/2Hn+Q= X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~public-inbox=simark.ca@sourceware.org >>>>> "Simon" == Simon Marchi writes: Simon> Some previously used constructs are now rejected at compile time, and Simon> require a few changes in the tests: Simon> - A top-level && or ||. I think this approach is very clever but I'm not really a fan of the result. It seems completely reasonable to me to want to write || or && in a test. Simon> - A lone non-bool value, like SELF_CHECK (ptr). This isn't really that weird either. Simon> Operands are printed using a value_to_string function that is a long Simon> series of "if constexpr" to print various types of operands. It ends Simon> with an always-false static_assert, such that trying to print an Simon> unsupported type will cause a build failure, and will require telling Simon> the function how to print said type. Why this way and not overloads? It seems to me that the drawback of this approach is that now the test framework has to have visibility on every possible thing that could be printed. Tom