summaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.c++/ref-types.cc
diff options
context:
space:
mode:
authorStan Shebs <shebs@apple.com>1999-04-16 01:33:56 +0000
committerStan Shebs <shebs@apple.com>1999-04-16 01:33:56 +0000
commit838ae13dc4ab603f1efdf1da653e2ca1b7b009e1 (patch)
tree8d3c114b0ba9d2a1f0dcadd192ba2aaeeafe7175 /gdb/testsuite/gdb.c++/ref-types.cc
downloadgdb-838ae13dc4ab603f1efdf1da653e2ca1b7b009e1.tar.gz
Initial revision
Diffstat (limited to 'gdb/testsuite/gdb.c++/ref-types.cc')
-rw-r--r--gdb/testsuite/gdb.c++/ref-types.cc30
1 files changed, 30 insertions, 0 deletions
diff --git a/gdb/testsuite/gdb.c++/ref-types.cc b/gdb/testsuite/gdb.c++/ref-types.cc
new file mode 100644
index 00000000000..8ee5c405d87
--- /dev/null
+++ b/gdb/testsuite/gdb.c++/ref-types.cc
@@ -0,0 +1,30 @@
+void marker1 (void)
+{
+
+}
+
+
+
+int main(void)
+{
+ short s;
+ short &rs = s;
+ short *ps;
+ short *&rps = ps;
+ short as[4];
+ short (&ras)[4] = as;
+ s = -1;
+ ps = &s;
+ as[0] = 0;
+ as[1] = 1;
+ as[2] = 2;
+ as[3] = 3;
+
+ #ifdef usestubs
+ set_debug_traps();
+ breakpoint();
+ #endif
+ marker1();
+
+ return 0;
+}