This is the mail archive of the gdb-cvs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb] Generalize enum regexp in gdb.cp/classes.exp.


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=9720e656055e5b906649c9f506a6de5a31337d07

commit 9720e656055e5b906649c9f506a6de5a31337d07
Author: Sandra Loosemore <sandra@codesourcery.com>
Date:   Thu Sep 24 18:22:57 2015 -0700

    Generalize enum regexp in gdb.cp/classes.exp.
    
    2015-09-24 Sandra Loosemore <sandra@codesourcery.com>
    
    	gdb/testsuite/
    	* gdb.cp/classes.exp (test_enums): Generalize regexp to allow
    	short or char as base type.

Diff:
---
 gdb/testsuite/ChangeLog          | 5 +++++
 gdb/testsuite/gdb.cp/classes.exp | 2 +-
 2 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index 2c75cea..85b6126 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2015-09-24 Sandra Loosemore <sandra@codesourcery.com>
+
+	* gdb.cp/classes.exp (test_enums): Generalize regexp to allow
+	short or char as base type.
+
 2015-09-23 Sandra Loosemore <sandra@codesourcery.com>
 
 	* gdb.cp/var-tag.exp (do_global_tests): Generalize opt_underlying
diff --git a/gdb/testsuite/gdb.cp/classes.exp b/gdb/testsuite/gdb.cp/classes.exp
index 1d714d3..00f16fc 100644
--- a/gdb/testsuite/gdb.cp/classes.exp
+++ b/gdb/testsuite/gdb.cp/classes.exp
@@ -419,7 +419,7 @@ proc test_enums {} {
     # ptype on the enum member
 
     gdb_test_multiple "ptype obj_with_enum.priv_enum" "ptype obj_with_enum.priv_enum" {
-        -re "type = enum ClassWithEnum::PrivEnum (: unsigned int )?\{ ?(ClassWithEnum::)?red, (ClassWithEnum::)?green, (ClassWithEnum::)?blue, (ClassWithEnum::)?yellow = 42 ?\}$nl$gdb_prompt $" {
+        -re "type = enum ClassWithEnum::PrivEnum (: unsigned (int|short|char) )?\{ ?(ClassWithEnum::)?red, (ClassWithEnum::)?green, (ClassWithEnum::)?blue, (ClassWithEnum::)?yellow = 42 ?\}$nl$gdb_prompt $" {
 	    pass "ptype obj_with_enum.priv_enum"
         }
 	-re "type = enum PrivEnum \{ ?(ClassWithEnum::)?red, (ClassWithEnum::)?green, (ClassWithEnum::)?blue, (ClassWithEnum::)?yellow = 42 ?\}$nl$gdb_prompt $" {


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]