From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id l5sZBuy9nmUnyjcAWB0awg (envelope-from ) for ; Wed, 10 Jan 2024 10:55:24 -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=doqf00or; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id 0808F1E0C3; Wed, 10 Jan 2024 10:55:24 -0500 (EST) Received: from server2.sourceware.org (server2.sourceware.org [8.43.85.97]) (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 DD9D31E092 for ; Wed, 10 Jan 2024 10:55:21 -0500 (EST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 76360385E453 for ; Wed, 10 Jan 2024 15:55:21 +0000 (GMT) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by sourceware.org (Postfix) with ESMTPS id A326D3858407 for ; Wed, 10 Jan 2024 15:54:52 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org A326D3858407 Authentication-Results: sourceware.org; dmarc=pass (p=none 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 A326D3858407 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.129.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1704902094; cv=none; b=g8fMfqMOcMXZKhrcE/gqFgt6X6ZvBKP789DDwD4irzGEwnh7ZFA05yTtgmBthIG3+f46RiE78U7OExpm3SC5wGhH1Pp2jPVE+QUMV6VGw/mhgDXbW6vp/y5fZT3xB9cGK6Ga/gam1q1MzwpHeB36Dq/izsFjGusUrTICRxJFUiY= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1704902094; c=relaxed/simple; bh=N03bsLmIUluMVB7fRNPfmIc04L+7I10zQ7cdV17etC0=; h=DKIM-Signature:From:To:Subject:Date:Message-Id:MIME-Version; b=pAqwwAkqO5BCIYrX6HQPIURpb6ZBLUj12H6omiX7ED9up303VweGJxiWVNSVsngbCuuVghPOJCwakK23pt1O1vIWugzFB+3GsYpo5MXjFX1LcaHnhvdmkwxkXpG2kdSG/qlBOWO5/vpGF53O1h0d0MHhmhIHdO3BOLfCtH7meT0= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1704902092; 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=uV4EOiiD1D1IaH8QER7jJiePefi8rfPOfqodOmPziFU=; b=doqf00ormB1VoydZzfp0qgQGZX+M3aO7Fpp+jy/oEhvNbZMV8DrY0JT2Yun9vVSYBvwmyD Yqht5Zle9AQaM5KV+zCD0mggha6bMW01uRsCvuP64awmMOiSxJTW8swSZHja9zn89fuTzi 3hy3Nt6mxjSmPqullEk8mFoO9R3U0CA= Received: from mail-wm1-f69.google.com (mail-wm1-f69.google.com [209.85.128.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-211-u8lKgF1gMXqVUbRVmYuzIg-1; Wed, 10 Jan 2024 10:54:51 -0500 X-MC-Unique: u8lKgF1gMXqVUbRVmYuzIg-1 Received: by mail-wm1-f69.google.com with SMTP id 5b1f17b1804b1-40e54346672so7533155e9.1 for ; Wed, 10 Jan 2024 07:54:50 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704902089; x=1705506889; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=uV4EOiiD1D1IaH8QER7jJiePefi8rfPOfqodOmPziFU=; b=CsnramEc991wCyTF5JV/hoe+zUWBWxDqnOSW/NQNTt8S01Qci5S96EYtZmVzkPF19m vI6VC2n26z1iZoZZuQavwUrx4S16wBjqImqWQ4wpnPAWxgYGNcjSh7h/tgr30RbfWXfI 0aPN0Lpi/xAiFYeLj0nvHVbOOTpb/ORLMI23KebRIxlQ8eALNFLJi3K2s1Svryj5QN2J T+9mvioq1mG4qE/q1UuY67SJBMw0m+aiKEyaFF2rLdJsBOtx6wEZCJay/n2R0kbhf1WT nmzpw9+0ochgUA2ClFzv786e7w1oj6DX93y/KjLf/lnAOnfEQDb6h9Lhn1wOfuj6Yt3j m5Ng== X-Gm-Message-State: AOJu0YygttJQpw+i595FqksHDOLd4r4xFWtpWYHhUeCgnLvC07pFzBYB 5fAkdC0mp8AG9akGTAxN3hPpV/dUYWk5XEdAy81752Kxc+B2y+95EPTsqdD11siW4jBUvYNfBLL W3zxbdJDCUFOQOVUgr8u0xwus+sB+F68tl0DBtucTpYDRW4GU+KJAJEsLTLTv6/VlBU0Xi9I7RI V01cszVMzxSljPJw== X-Received: by 2002:a05:600c:4b18:b0:40d:72db:eac0 with SMTP id i24-20020a05600c4b1800b0040d72dbeac0mr732809wmp.47.1704902089627; Wed, 10 Jan 2024 07:54:49 -0800 (PST) X-Google-Smtp-Source: AGHT+IGpaVYGICWxiUZk+MuXaEUazeaifiNnlbVfYEbGEiw6P7VQ7ZU3Voh21snclYKS3Q7M7DiPag== X-Received: by 2002:a05:600c:4b18:b0:40d:72db:eac0 with SMTP id i24-20020a05600c4b1800b0040d72dbeac0mr732800wmp.47.1704902089189; Wed, 10 Jan 2024 07:54:49 -0800 (PST) Received: from localhost (185.223.159.143.dyn.plus.net. [143.159.223.185]) by smtp.gmail.com with ESMTPSA id je3-20020a05600c1f8300b0040d87100733sm2612794wmb.39.2024.01.10.07.54.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 Jan 2024 07:54:48 -0800 (PST) From: Andrew Burgess To: gdb-patches@sourceware.org Cc: Andrew Burgess Subject: [PATCHv2 0/8] Python __repr__() methods and new __dict__ attributes Date: Wed, 10 Jan 2024 15:54:36 +0000 Message-Id: X-Mailer: git-send-email 2.25.4 In-Reply-To: References: MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII"; x-default=true X-Spam-Status: No, score=-7.0 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H4, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_NONE, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org 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 In V2: - Fixed problems in thpy_dealloc that Tom pointed out, - Used @group...@end group in the docs as suggested by Eli, - Added patches #7 and #8, which are both docs only patches. The first adds advice for naming attributes as Tom suggested, the second is just some doc updates that I noticed in passing. -- This series is a bit of a mixed bag of Python API related changes. Patches #2 and #3 do depend on #1, but #4, #5, and #6 are really quite separate. However, they're all pretty small, and are all just extending existing functionality to cover more cases, so I've thrown them all in together for now. -- Andrew Burgess (8): gdb/python: hoist common invalid object repr code into py-utils.c gdb/python: add gdb.InferiorThread.__repr__() method gdb/python: add gdb.Frame.__repr__() method gdb/python: remove users ability to create gdb.Progspace objects gdb/python: Add gdb.Inferior.__dict__ attribute gdb/python: Add gdb.InferiorThread.__dict__ attribute gdb/doc: add some notes on selecting suitable attribute names gdb/doc: update examples in gdb.Progspace and gdb.Objfile docs gdb/NEWS | 13 +++ gdb/doc/python.texi | 111 ++++++++++++++++++++-- gdb/python/py-arch.c | 2 +- gdb/python/py-block.c | 2 +- gdb/python/py-breakpoint.c | 4 +- gdb/python/py-connection.c | 2 +- gdb/python/py-frame.c | 19 +++- gdb/python/py-inferior.c | 15 ++- gdb/python/py-infthread.c | 34 ++++++- gdb/python/py-objfile.c | 2 +- gdb/python/py-progspace.c | 16 +--- gdb/python/py-symbol.c | 2 +- gdb/python/py-type.c | 3 +- gdb/python/py-unwind.c | 2 +- gdb/python/py-utils.c | 8 ++ gdb/python/python-internal.h | 13 +++ gdb/testsuite/gdb.python/py-frame.exp | 8 ++ gdb/testsuite/gdb.python/py-inferior.exp | 52 +++++++++- gdb/testsuite/gdb.python/py-infthread.exp | 3 +- gdb/testsuite/gdb.python/py-progspace.exp | 6 ++ 20 files changed, 277 insertions(+), 40 deletions(-) base-commit: b7a5722ebdd24a0d15d56e96d30a649ea1d7b0ee -- 2.25.4