aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoel Brobecker <brobecker@gnat.com>2004-04-01 00:58:00 +0000
committerJoel Brobecker <brobecker@gnat.com>2004-04-01 00:58:00 +0000
commitf0aaee494035335e128a3fe73bd3eaa91bec686d (patch)
tree62dc743b183bb5315bbce76731e7d55a2001c094
parentac81cb5421e98617d7832cc755f7322db4340cd7 (diff)
downloadgdb-f0aaee494035335e128a3fe73bd3eaa91bec686d.zip
gdb-f0aaee494035335e128a3fe73bd3eaa91bec686d.tar.gz
gdb-f0aaee494035335e128a3fe73bd3eaa91bec686d.tar.bz2
* gdb.ada (bar.ads, bar.adb, null_record.adb): New files.
* gdb.ada (null_record.exp): New testcase.
-rw-r--r--gdb/testsuite/ChangeLog5
-rw-r--r--gdb/testsuite/gdb.ada/bar.adb8
-rw-r--r--gdb/testsuite/gdb.ada/bar.ads8
-rw-r--r--gdb/testsuite/gdb.ada/null_record.adb7
-rw-r--r--gdb/testsuite/gdb.ada/null_record.exp26
5 files changed, 54 insertions, 0 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index bec4baf..a5664a3 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -1,5 +1,10 @@
2004-03-31 Joel Brobecker <brobecker@gnat.com>
+ * gdb.ada (bar.ads, bar.adb, null_record.adb): New files.
+ * gdb.ada (null_record.exp): New testcase.
+
+2004-03-31 Joel Brobecker <brobecker@gnat.com>
+
* Makefile.in (ALL_SUBDIRS) Add gdb.ada.
2004-03-31 Joel Brobecker <brobecker@gnat.com>
diff --git a/gdb/testsuite/gdb.ada/bar.adb b/gdb/testsuite/gdb.ada/bar.adb
new file mode 100644
index 0000000..a150b75
--- /dev/null
+++ b/gdb/testsuite/gdb.ada/bar.adb
@@ -0,0 +1,8 @@
+package body Bar is
+
+ procedure Do_Nothing is
+ begin
+ null;
+ end Do_Nothing;
+
+end Bar;
diff --git a/gdb/testsuite/gdb.ada/bar.ads b/gdb/testsuite/gdb.ada/bar.ads
new file mode 100644
index 0000000..80d56f6
--- /dev/null
+++ b/gdb/testsuite/gdb.ada/bar.ads
@@ -0,0 +1,8 @@
+
+package Bar is
+
+ type Empty is null record;
+
+ procedure Do_Nothing;
+
+end Bar;
diff --git a/gdb/testsuite/gdb.ada/null_record.adb b/gdb/testsuite/gdb.ada/null_record.adb
new file mode 100644
index 0000000..171ad77
--- /dev/null
+++ b/gdb/testsuite/gdb.ada/null_record.adb
@@ -0,0 +1,7 @@
+with Bar; use Bar;
+
+procedure Null_Record is
+begin
+ Do_Nothing;
+end Null_Record;
+
diff --git a/gdb/testsuite/gdb.ada/null_record.exp b/gdb/testsuite/gdb.ada/null_record.exp
new file mode 100644
index 0000000..f9afcf7
--- /dev/null
+++ b/gdb/testsuite/gdb.ada/null_record.exp
@@ -0,0 +1,26 @@
+if $tracelevel then {
+ strace $tracelevel
+}
+
+load_lib "ada.exp"
+
+set testfile "null_record"
+set srcfile ${testfile}.adb
+set binfile ${objdir}/${subdir}/${testfile}
+
+if {[gdb_compile_ada "${srcfile}" "${binfile}" executable [list debug ]] != "" } {
+ return -1
+}
+
+gdb_exit
+gdb_start
+gdb_reinitialize_dir $srcdir/$subdir
+gdb_load ${binfile}
+
+gdb_test "begin" \
+ "Breakpoint \[0-9\]+ at .*null_record.adb.*" \
+ "begin"
+
+gdb_test "ptype empty" \
+ "type = record null; end record" \
+ "ptype on null record"