OLD | NEW |
1 # Copyright 2002-2003, 2007-2012 Free Software Foundation, Inc. | 1 # Copyright 2002-2003, 2007-2012 Free Software Foundation, Inc. |
2 | 2 |
3 # This program is free software; you can redistribute it and/or modify | 3 # This program is free software; you can redistribute it and/or modify |
4 # it under the terms of the GNU General Public License as published by | 4 # it under the terms of the GNU General Public License as published by |
5 # the Free Software Foundation; either version 3 of the License, or | 5 # the Free Software Foundation; either version 3 of the License, or |
6 # (at your option) any later version. | 6 # (at your option) any later version. |
7 # | 7 # |
8 # This program is distributed in the hope that it will be useful, | 8 # This program is distributed in the hope that it will be useful, |
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of | 9 # but WITHOUT ANY WARRANTY; without even the implied warranty of |
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
11 # GNU General Public License for more details. | 11 # GNU General Public License for more details. |
12 # | 12 # |
13 # You should have received a copy of the GNU General Public License | 13 # You should have received a copy of the GNU General Public License |
14 # along with this program. If not, see <http://www.gnu.org/licenses/>. | 14 # along with this program. If not, see <http://www.gnu.org/licenses/>. |
15 | 15 |
16 # | 16 # |
17 # test gdb/792 | 17 # test gdb/792 |
18 # | 18 # |
19 | 19 |
20 if { [skip_cplus_tests] } { continue } | 20 if { [skip_cplus_tests] } { continue } |
21 | 21 |
22 load_lib mi-support.exp | 22 load_lib mi-support.exp |
23 set MIFLAGS "-i=mi" | 23 set MIFLAGS "-i=mi" |
24 | 24 |
25 gdb_exit | 25 gdb_exit |
26 if [mi_gdb_start] { | 26 if [mi_gdb_start] { |
27 continue | 27 continue |
28 } | 28 } |
29 | 29 |
30 set testfile gdb792 | 30 standard_testfile .cc |
31 set srcfile "$testfile.cc" | |
32 set binfile $objdir/$subdir/$testfile | |
33 | 31 |
34 if [get_compiler_info ${binfile} "c++"] { | 32 if [get_compiler_info "c++"] { |
35 return -1; | 33 return -1; |
36 } | 34 } |
37 | 35 |
38 if {[gdb_compile $srcdir/$subdir/$srcfile $binfile executable {debug c++}] != ""
} { | 36 if {[gdb_compile $srcdir/$subdir/$srcfile $binfile executable {debug c++}] != ""
} { |
39 untested gdb792.exp | 37 untested gdb792.exp |
40 return -1 | 38 return -1 |
41 } | 39 } |
42 | 40 |
43 # Test that children of classes are properly reported | 41 # Test that children of classes are properly reported |
44 | 42 |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
85 mi_create_varobj "var2" "c" "create var for class C which has baseclass A" | 83 mi_create_varobj "var2" "c" "create var for class C which has baseclass A" |
86 | 84 |
87 mi_list_varobj_children "var2" { | 85 mi_list_varobj_children "var2" { |
88 {var2.A A 3 A} | 86 {var2.A A 3 A} |
89 {var2.public public 1} | 87 {var2.public public 1} |
90 {var2.private private 1} | 88 {var2.private private 1} |
91 } "list children of class C" | 89 } "list children of class C" |
92 | 90 |
93 mi_gdb_exit | 91 mi_gdb_exit |
94 return 0 | 92 return 0 |
OLD | NEW |