public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Phil Muldoon <pmuldoon@redhat.com>
To: Kevin Pouget <kevin.pouget@gmail.com>
Cc: Tom Tromey <tromey@redhat.com>,
	gdb-patches@sourceware.org,        Eli Zaretskii <eliz@gnu.org>
Subject: Re: [PATCH] Add bp_location to Python interface
Date: Tue, 03 Apr 2012 12:15:00 -0000	[thread overview]
Message-ID: <4F7AE9C6.7050708@redhat.com> (raw)
In-Reply-To: <CAPftXUJ4VqDsadmWYZ39qpyGd7UAV1G3iHkDkWkVKqyxGnSCqg@mail.gmail.com>

> On Fri, Mar 30, 2012 at 9:51 PM, Tom Tromey <tromey@redhat.com>
> wrote:

> On 04/03/2012 11:34 AM, Kevin Pouget wrote:

> the idea here was that a tuple is not mutable, whereas a list is --
>  () vs. []. I've removed the tuple, although although I'm not sure
>  when I'm supposed to use the List or the Tuple.

This was my comment way back when, so apologies for the conflicting
comments.  I prefer to return non-mutable objects when they reflect an
internal state of GDB; just to provide a hint that the data exchange
is one-way -- that changing the list won't change state back in GDB
(hence the immutable tuple).

Though I suspect it does not really matter -- the user can quite
easily turn a tuple into a list.  As for returning a tuple versus a
list, again, I guess it does not really matter; the tuple idiom
was just my convention (though with very large lists, the conversion
to a tuple might be expensive).


> 2012-03-04 Kevin Pouget <kevin.pouget@st.com>
>
> Add bp_location to Python interface
> * Makefile.in (SUBDIR_PYTHON_OBS): Add py-bploc.o
> (SUBDIR_PYTHON_SRCS): Add python/py-bploc.c
> Add build rule for this file.
> * breakpoint.h (struct bploc_object): Forward declaration.
> (struct bp_location): Add py_bploc_obj.
> * python/py-bploc.c: New file.
> * python/py-breakpoint.c (bppy_locations): New function.
> (breakpoint_object_methods): New method binding: locations().
> * python/python-internal.h (bploc_object): New typedef.
> (bplocation_to_bplocation_object): New prototype.
> (gdbpy_initialize_bplocation): Likewise.
>
> doc/
> Add bp_location to Python interface
> * gdb.texinfo (Breakpoints In Python): Document
> gdb.Breakpoint.locations and gdb.BpLocation.
>
>
> testsuite/
> Add bp_location to Python interface
> * gdb.python/py-breakpoint.exp: Test gdb.BpLocation.

Thanks for this,

Cheers

Phil

  reply	other threads:[~2012-04-03 12:15 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-08 10:17 Kevin Pouget
2011-12-08 13:39 ` Phil Muldoon
2011-12-08 14:28   ` Kevin Pouget
2011-12-08 14:56 ` Phil Muldoon
2011-12-09 13:49   ` Kevin Pouget
2011-12-09 14:15     ` Phil Muldoon
2011-12-13 15:55       ` Kevin Pouget
2012-01-09 11:47         ` Kevin Pouget
2012-01-09 17:23           ` Eli Zaretskii
2012-01-10 15:09             ` Kevin Pouget
2012-01-10 16:03               ` Kevin Pouget
2012-01-10 17:25               ` Eli Zaretskii
2012-01-11 10:16                 ` Kevin Pouget
2012-01-11 10:27                   ` Eli Zaretskii
2012-01-10 22:24               ` Doug Evans
2012-01-11  9:05                 ` Kevin Pouget
2012-01-11 19:45                   ` Doug Evans
2012-01-27 13:04                     ` Kevin Pouget
2012-03-30 19:51                       ` Tom Tromey
2012-04-03 10:35                         ` Kevin Pouget
2012-04-03 12:15                           ` Phil Muldoon [this message]
2012-04-03 14:43                             ` Paul_Koning
2012-04-04  8:36                               ` Kevin Pouget
2012-05-09  7:18                                 ` Kevin Pouget
2012-04-05 16:27                           ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4F7AE9C6.7050708@redhat.com \
    --to=pmuldoon@redhat.com \
    --cc=eliz@gnu.org \
    --cc=gdb-patches@sourceware.org \
    --cc=kevin.pouget@gmail.com \
    --cc=tromey@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).