This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] Forbid watchpoint on a constant value
- From: Joel Brobecker <brobecker at adacore dot com>
- To: Sergio Durigan Junior <sergiodj at redhat dot com>
- Cc: gdb-patches at sourceware dot org, Jan Kratochvil <jan dot kratochvil at redhat dot com>
- Date: Thu, 20 May 2010 16:13:08 -0700
- Subject: Re: [PATCH] Forbid watchpoint on a constant value
- References: <201005181418.24324.sergiodj@redhat.com>
Hi Sergio,
> Joel mentioned this patch yesterday, so here it is. This patch forbids
> the user to create a watchpoint on a constant value. The idea is pretty
> trivial:
>
> (gdb) watch 5
> Cannot watch constant value 5.
Without looking at the specifics of the patch for now, I am wondering
what other people think of the idea itself. For myself, I can see how
a warning might be useful, but forbidding it might be viewed as
a little excessive, particularly if there is a bug in GDB (or in
the debugging info!!!) that makes it think it's constant when in fact
it's not.
--
Joel