[commit] gdb.cp/converts.exp FAIL on gcc-4.1 [Re: Testsuite regression gdb.cp/converts.exp [Re: [RFA] gdb/13483]]

Jan Kratochvil jan.kratochvil@redhat.com
Sun Sep 16 17:32:00 GMT 2012


On Thu, 13 Sep 2012 01:29:20 +0200, Keith Seitz wrote:
> Sure. For the record, here is what I committed:
> 
> 2012-09-12  Keith Seitz  <keiths@redhat.com>
> 
> 	* gdb.cp/converts.cc (main): Comment out the pointer to boolean
> 	conversion statement.

It compiles OK now but it FAILs on:
	p foo1_7(MY_A)^M
	No symbol "MY_A" in current context.^M
	(gdb) FAIL: gdb.cp/converts.exp: p foo1_7(MY_A)

Checked in.


Thanks,
Jan


http://sourceware.org/ml/gdb-cvs/2012-09/msg00074.html

--- src/gdb/testsuite/ChangeLog	2012/09/14 21:23:45	1.3373
+++ src/gdb/testsuite/ChangeLog	2012/09/16 17:30:47	1.3374
@@ -1,3 +1,8 @@
+2012-09-16  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+	Fix compatibility with old GCC (~4.1).
+	* gdb.cp/converts.cc (my_enum_var): New variable.
+
 2012-09-14  Andrew Burgess  <aburgess@broadcom.com>
 
 	* gdb.xml/tdesc-regs.exp: Update expected output for new
--- src/gdb/testsuite/gdb.cp/converts.cc	2012/09/12 23:29:05	1.6
+++ src/gdb/testsuite/gdb.cp/converts.cc	2012/09/16 17:30:48	1.7
@@ -12,6 +12,10 @@
 
 enum my_enum {MY_A, MY_B, MY_C, MY_D};
 
+/* Without this variable older 'enum my_enum' incl. its 'MY_A' would be omitted
+   by older versions of GCC (~4.1) failing the testcase using it below.  */
+enum my_enum my_enum_var;
+
 int foo0_1 (TA1)  { return 1; }
 int foo0_2 (TA3)  { return 2; }
 int foo0_3 (A***) { return 3; }



More information about the Gdb-patches mailing list