Somewhat sanitize watchpoints with conditions on local expressions

Eli Zaretskii eliz@gnu.org
Thu Mar 4 07:55:00 GMT 2010


> From: Pedro Alves <pedro@codesourcery.com>
> Date: Thu, 4 Mar 2010 03:50:34 +0000
> 
> The patch below that implements what sounded least
> surprising to me (evaluate condition in correct frame
> if possible, and warn if not possible, without trying
> and doing undefined things), and adds tests
> for this, and other variants involving global
> expressions, and local conditions.
> 
> 
> Comments?

I like it.  One question:

> +static int
> +is_watchpoint (struct breakpoint *bpt)
> +{
> +  return (is_hardware_watchpoint (bpt)
> +	  || bpt->type == bp_watchpoint);
> +}

Does this catch read and access watchpoints?  Should it?

Thanks.



More information about the Gdb-patches mailing list