This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH v5 11/15] test: cover subranges with present DW_AT_count attribute
- 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, 28 Feb 2014 09:51:58 -0800
- Subject: Re: [PATCH v5 11/15] test: cover subranges with present DW_AT_count attribute
- Authentication-results: sourceware.org; auth=none
- References: <1391704056-25246-1-git-send-email-sanimir dot agovic at intel dot com> <1391704056-25246-12-git-send-email-sanimir dot agovic at intel dot com>
On Thu, Feb 06, 2014 at 05:27:32PM +0100, Sanimir Agovic wrote:
> The dwarf attribute DW_AT_count specifies the elements of a subrange.
> This test covers subranges with present count but absent upper bound
> attribute, both with static and dynamic attribute values.
>
> 2013-11-26 Sanimir Agovic <sanimir.agovic@intel.com>
> Keven Boell <keven.boell@intel.com>
>
> testsuite:
> * gdb.dwarf2/count.exp: New test.
One small comment. Pre-approved with those changes made.
> +gdb_test "ptype array" "type = char \\\[5\\\]" "ptype array"
> +gdb_test "whatis array" "type = char \\\[5\\\]" "whatis array"
> +gdb_test "print array" "\"hello\"" "print array"
> +gdb_test "print sizeof array" "5" "print sizeof array"
> +
> +gdb_test "ptype static_array" "type = char \\\[5\\\]" "ptype static_array"
> +gdb_test "whatis static_array" "type = char \\\[5\\\]" "whatis static_array"
> +gdb_test "print static_array" "\"world\"" "print static_array"
> +gdb_test "print sizeof static_array" "5" "print sizeof static_array"
In the 4 "print" tests, can you start the expected output by
" = "? In particular for the sizeof tests, it'll make sure that
you don't match a bogus return value that happens to contain
a 5 in it.
--
Joel