From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id k4s5OKG3d2kPdBYAWB0awg (envelope-from ) for ; Mon, 26 Jan 2026 13:51:13 -0500 Authentication-Results: simark.ca; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=SZQUA1gX; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id D6AFA1E08D; Mon, 26 Jan 2026 13:51:13 -0500 (EST) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-3.4 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED,RCVD_IN_VALIDITY_CERTIFIED_BLOCKED, RCVD_IN_VALIDITY_RPBL_BLOCKED,RCVD_IN_VALIDITY_SAFE_BLOCKED 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 675071E08D for ; Mon, 26 Jan 2026 13:51:13 -0500 (EST) Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id CE7CF4BC8974 for ; Mon, 26 Jan 2026 18:51:12 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org CE7CF4BC8974 Authentication-Results: sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=SZQUA1gX Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTP id 2C2EB4BA9021 for ; Mon, 26 Jan 2026 18:50:47 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 2C2EB4BA9021 Authentication-Results: sourceware.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 2C2EB4BA9021 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.133.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1769453447; cv=none; b=R+5lXh0qXpHlRhUE3A6b2WIQjFoBXJ5L9Zw47wka99bqqtWoYhlePePDkDeQd2VQl9zRBxqEMp+oipaSnAXEnmNArf66Kr+1dRh1Zv8LLrTQ5wPW3EnaVh+qoffA83h+NoKzmykI5Lc6vaCtwPXyEBA5jaW8affbnZIJedQCMAQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1769453447; c=relaxed/simple; bh=A7AIEX2D5xJurgp1Vyu8TbjHh5YIq/mz6gqHWNVvgCk=; h=DKIM-Signature:Message-ID:Date:MIME-Version:Subject:To:From; b=cXDgd6+4bm6mK3qN1WkgaBVz+6vH/YJibPXUS77OURUttc6JM2ZsHz4ELXyKtvzF5dY0ztsx72lO/XDJArDXTgHUXLZzVCmODxbHjTiPGK1EnTA+U1GWgu9qQo9biOE5gT/IvTqHPszGbMOfNzMY9BjHvPOFdAG7WxwKwKudBHY= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 2C2EB4BA9021 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1769453446; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=eLz7ogzx0bgf0V6P97y0RwQT+hbiEhbyDOf7Kmns7Ds=; b=SZQUA1gXTajO8F2gBz7uES7KLv0T/Fy4fx2vySVQHOUOFFd1GFwOryKhLizFh9ewR4Q5Vf lxv0XnFCvofRuRnYUlyJok6vHxVE0Iia6KGrYd+vlO4AOKCG6+NPX2tem1Oy6y/D7g4y61 vCAjENBted+FTEGLCz6dYmlwp0IzSN0= Received: from mail-dy1-f197.google.com (mail-dy1-f197.google.com [74.125.82.197]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-58-xwwpbBblOlqxN0aQVM2apw-1; Mon, 26 Jan 2026 13:50:45 -0500 X-MC-Unique: xwwpbBblOlqxN0aQVM2apw-1 X-Mimecast-MFC-AGG-ID: xwwpbBblOlqxN0aQVM2apw_1769453444 Received: by mail-dy1-f197.google.com with SMTP id 5a478bee46e88-2b72dc38111so2899173eec.0 for ; Mon, 26 Jan 2026 10:50:45 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1769453444; x=1770058244; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=eLz7ogzx0bgf0V6P97y0RwQT+hbiEhbyDOf7Kmns7Ds=; b=ee7PgaVhBz9aQLYy+HDFDKvO/K+n+5sTm5EP14Rs9P1TspKdmpkLvpAETcL2eA5lTg 9zWDuTTJ7CQiElb7EDRAR50U4RF696r5XwVxzMDNqzlGPlOLB+rFXntueJ2uYLE/wTDE gRvSxzx1IvHJ2Igtn9TcF2P2xcNrdTebYC1OYfwI2V1elhvl9sB7fe2qzbiaZKlNqyUu CEcivSTZCfB0qAlnNnMH1Vg6Bp65e1bJADspGhm73nq6pxqkt3ihlQyo12iIKVAcw+r1 O7QhUKiv9ug2yhvNRQ8gZx9QsXuDLNm4+sliz2CnjuAhSOCVM3v922GM013x6cdbHxyX LJBA== X-Gm-Message-State: AOJu0YzQ40Fz3QNkebRMl6gZ4/+ee3XtJi1QFMWMg1iR91ZzVVnP6uFb FXr8Iqp14gnsNvv9bKKCO2JWkAde26f/iaumlpLn2WokOOGHneB8YY4txGVnygh6FlHSnV/jwEI mrhrjUprTvGsHSCYCju475Ehjmea/p0tOXud0YWMZuCsvyAndgdfIg5+IgPMzFXXy6DK94Ks= X-Gm-Gg: AZuq6aJ/yPiucIy2N3yP9KTWDg7t9Eeb2t0PG+C2S5tagkk8gKDwlOb7m+K/Juw9Ov7 UNizsVQh1REks7CHjUBxcs6TXxND1TGa7znwiz/a+fR2XxfjF3/cn7CzfmHkIlXxg/4SRv8XBm+ TY3qRlXe2PEuIbq6A2H0Hf1v8M42tnxCxZom6yjozkJIwbJ6EFX6LWpjPldtbPcvR4p6h6m7NWb dDJndeQIUmsmCxPfOURjZcfk6dp28kjAe08Kcgcf86PMwtXwD06nQpwntboA1wCUKsx7NUGTo2x Yu3ndm3Ms7YNVjul6fsRHgqgZTpkIX8IrWgC+3Y5QrhzA+Gtbl320eyT2W8IHQmsyRmNyUuIhiz oxowRYLe9cyrbLbBGI6jIxg== X-Received: by 2002:a05:693c:630b:b0:2b0:487c:7aba with SMTP id 5a478bee46e88-2b7639e1a67mr2453338eec.21.1769453443785; Mon, 26 Jan 2026 10:50:43 -0800 (PST) X-Received: by 2002:a05:693c:630b:b0:2b0:487c:7aba with SMTP id 5a478bee46e88-2b7639e1a67mr2453325eec.21.1769453443199; Mon, 26 Jan 2026 10:50:43 -0800 (PST) Received: from ?IPV6:2804:14d:8084:a5b1::1002? ([2804:14d:8084:a5b1::1002]) by smtp.gmail.com with ESMTPSA id 5a478bee46e88-2b73a6f5d2asm14345742eec.14.2026.01.26.10.50.41 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 26 Jan 2026 10:50:42 -0800 (PST) Message-ID: <9cb9a2da-fc1e-422e-b7f6-8513246366e4@redhat.com> Date: Mon, 26 Jan 2026 15:50:39 -0300 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v2] gdb: add tutorial command To: Andrew Burgess , Eli Zaretskii Cc: gdb-patches@sourceware.org References: <20260122202834.393095-1-guinevere@redhat.com> <86o6mkiz1o.fsf@gnu.org> <19c407af-d5a8-49a0-9413-1d41d23c7fbf@redhat.com> <864iocietp.fsf@gnu.org> <87zf60fmqx.fsf@redhat.com> From: Guinevere Larsen In-Reply-To: <87zf60fmqx.fsf@redhat.com> X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: e5M4kzV-gVPXsi-g69Cu2-hnSilC82JykYpZF58oZOg_1769453444 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit 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 On 1/26/26 11:54 AM, Andrew Burgess wrote: > Eli Zaretskii writes: > >>> Date: Fri, 23 Jan 2026 11:14:20 -0300 >>> Cc: gdb-patches@sourceware.org >>> From: Guinevere Larsen >>> >>>> Isn't it strange to teach newbies that to assign a value to a >>>> variable, one must use the 'print' command? Why not "set variable"? >>> It is a bit strange, I suppose, but "set" (like "call") are not things I use personally, when print can do the same >>> and is one fewer command to remember >>> >>> And this doubles as a warning that if the user calls a function that has side-effects, those will also happen, >>> and they aren't necessarily always desired by the user... >>> >>> I can change it if you feel strongly that we should use "set" instead, but I find the side-effect explanation to >>> be worth the unintuitiveness >> I think the tutorial should teach the commands intended for their >> purposes. Some commands have side effects, but that's not newbie >> stuff, IMO. >> >> What do others think about this? > I agree Eli. I have always find it strange that some folk use print to > set variable. At least Guinevere did offer some explanation, which is > nice to know, but I do think that for beginner, using the intended > command would be a good idea. > > That doesn't mean there's not room for some kind of: > > Advanced hint: Some users use 'print' instead of 'set' for > setting inferior variables, this works because ... etc. > > within the tutorial text. > > Thanks, > Andrew > Seeing as everyone seems to be in agreement with using set, I'll update the text when I send a v3. -- Cheers, Guinevere Larsen It/she