aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite
diff options
context:
space:
mode:
authorJason Molenda <jmolenda@apple.com>1999-12-14 01:06:04 +0000
committerJason Molenda <jmolenda@apple.com>1999-12-14 01:06:04 +0000
commitc4093a6ab3c9ba5f830ca18d91d8b4db5b1d28ee (patch)
tree273969a6c8a28b0f0128edd803506abf025371b1 /gdb/testsuite
parenta3a8c91d411abe91720a2ac92b8140e1bdb41282 (diff)
downloadgdb-c4093a6ab3c9ba5f830ca18d91d8b4db5b1d28ee.zip
gdb-c4093a6ab3c9ba5f830ca18d91d8b4db5b1d28ee.tar.gz
gdb-c4093a6ab3c9ba5f830ca18d91d8b4db5b1d28ee.tar.bz2
import gdb-1999-12-13 snapshot
Diffstat (limited to 'gdb/testsuite')
-rw-r--r--gdb/testsuite/ChangeLog19
-rw-r--r--gdb/testsuite/gdb.base/break.exp2
-rw-r--r--gdb/testsuite/gdb.base/setvar.exp34
-rw-r--r--gdb/testsuite/gdb.base/watchpoint.exp4
4 files changed, 41 insertions, 18 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index 30308c8..47d33a2 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -1,3 +1,22 @@
+1999-12-13n Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * gdb.base/watchpoint.exp: Add missing "(timeout)" to test message.
+
+1999-12-13n Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * gdb.base/break.exp: Add missing anchor to reg exp on "finish from
+ outermost frame disallowed".
+
+1999-12-09 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * gdb.base/setvar.exp: New tests for setting the value of a struct
+ with a constant list.
+
+1999-12-08 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * gdb.base/setvar.exp: Remove pair os tests that expected gdb to
+ require the user to type a cast before setting the value of a struct.
+
1999-12-06 Jim Blandy <jimb@cygnus.com>
* gdb.base/default.exp: Expect the new 'info float' command on
diff --git a/gdb/testsuite/gdb.base/break.exp b/gdb/testsuite/gdb.base/break.exp
index a3d54ed..a076b53 100644
--- a/gdb/testsuite/gdb.base/break.exp
+++ b/gdb/testsuite/gdb.base/break.exp
@@ -619,7 +619,7 @@ send_gdb "finish\n"
gdb_expect {
-re "\"finish\" not meaningful in the outermost frame.\r\n$gdb_prompt $"\
{pass "finish from outermost frame disallowed"}
- -re "Run till exit from.*" {
+ -re "Run till exit from.*\r\n$gdb_prompt $" {
pass "finish from outermost frame disallowed"
}
-re "$gdb_prompt $"\
diff --git a/gdb/testsuite/gdb.base/setvar.exp b/gdb/testsuite/gdb.base/setvar.exp
index 2c9b416..f321c9f 100644
--- a/gdb/testsuite/gdb.base/setvar.exp
+++ b/gdb/testsuite/gdb.base/setvar.exp
@@ -385,29 +385,33 @@ gdb_test "print v_struct1" \
v_long_member = 3,.*v_float_member = 4,.*v_double_member = 5.*\}" \
"set print structure #1"
-# This should be an error. GCC extensions for structure constants require
-# the type of the structure to be specified, as in
+# Some believe that the following should be an error. GCC extensions for
+# structure constants require the type of the structure to be specified, as in
# v_struct1 = (struct t_struct) {32, 33, 34, 35, 36, 37}
-# GDB should do the same if it wants to provide this feature.
-# However, for HP's aCC this is OK, so we skip the tests for aCC
-if {! $hp_aCC_compiler} {
-if [target_info exists gdb,cannot_call_functions] {
- setup_xfail "*-*-*" 2416
- fail "set variable v_struct1 = {32, 33, 34, 35, 36, 37}"
- continue
-}
+# The argument is that GDB should do the same if it wants to provide this
+# feature, i.e., require the cast.
+# We decided that we don't want the debugger to be as picky as a
+# compiler and make us type complex casts.
+
# We need to up this because this can be really slow on some boards.
# (malloc() is called as part of the test).
set timeout 60;
-gdb_test "set variable v_struct1 = {32, 33, 34, 35, 36, 37}" "Invalid.*"
-# And after the error the structure should be unchanged.
-gdb_test "print v_struct1" \
+# Change the values
+test_set "set variable v_struct1 = {32, 33, 34, 35, 36, 37}" \
+ "print v_struct1" \
+ ".*.\[0-9\]* = \{.*v_char_member = 32 \' \',.*v_short_member = 33,\
+.*v_int_member = 34,.*\
+v_long_member = 35,.*v_float_member = 36,.*v_double_member = 37.*\}" \
+ "set print structure #2"
+
+# Change them back
+test_set "set variable v_struct1 = {'h', 1, 2, 3, 4.0, 5.0}" \
+ "print v_struct1" \
".*.\[0-9\]* = \{.*v_char_member = 104 \'h\',.*v_short_member = 1,\
.*v_int_member = 2,.*\
v_long_member = 3,.*v_float_member = 4,.*v_double_member = 5.*\}" \
- "set print structure #2"
-}
+ "set print structure #3"
# Test printing of enumeration bitfields.
# GNU C supports them, some other compilers don't.
diff --git a/gdb/testsuite/gdb.base/watchpoint.exp b/gdb/testsuite/gdb.base/watchpoint.exp
index 6be4e34..39c388e 100644
--- a/gdb/testsuite/gdb.base/watchpoint.exp
+++ b/gdb/testsuite/gdb.base/watchpoint.exp
@@ -420,7 +420,7 @@ proc test_stepping {} {
-re ".*$gdb_prompt $" {
fail "finish from marker1"
}
- default { fail "finish from marker1" ; return }
+ default { fail "finish from marker1 (timeout)" ; return }
}
gdb_test "next" "for \\(count = 0.*" "next to `for' in watchpoint.exp"
@@ -448,7 +448,7 @@ proc test_stepping {} {
-re ".*$gdb_prompt $" {
fail "until out of loop"
}
- default { fail "until out of loop" ; return }
+ default { fail "until out of loop (timeout)" ; return }
}
gdb_test "step" "ival2 = count.*" "step to ival2 assignment"