This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH v5 09/15] vla: resolve dynamic bounds if value contents is a constant byte-sequence
- From: Joel Brobecker <brobecker at adacore dot com>
- To: Sanimir Agovic <sanimir dot agovic at intel dot com>
- Cc: tromey at redhat dot com, keven dot boell at intel dot com, gdb-patches at sourceware dot org
- Date: Fri, 7 Feb 2014 14:27:15 +0400
- Subject: Re: [PATCH v5 09/15] vla: resolve dynamic bounds if value contents is a constant byte-sequence
- Authentication-results: sourceware.org; auth=none
- References: <1391704056-25246-1-git-send-email-sanimir dot agovic at intel dot com> <1391704056-25246-10-git-send-email-sanimir dot agovic at intel dot com>
Hello!
> 2013-11-26 Sanimir Agovic <sanimir.agovic@intel.com>
> Keven Boell <keven.boell@intel.com>
>
> * findvar.c (default_read_var_value): Resolve dynamic bounds if location
> points to a constant blob.
Small trivial comment....
> case LOC_CONST_BYTES:
> + if (is_dynamic_type (type))
> + /* Value is a constant byte-sequence and needs no memory access. */
> + type = resolve_dynamic_type (type, /* Unused address. */ 0);
Although not required by C, we prefer in the GDB project to still
use curly braces around the if block. The reason is that the comment
visually looks like a statement, so it looks like the if block as
more than one statement, hence the use of curly braces...
Thank you!
--
Joel