| OLD | NEW |
| 1 # Copyright 2007-2012 Free Software Foundation, Inc. | 1 # Copyright 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 |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 | 21 |
| 22 | 22 |
| 23 load_lib mi-support.exp | 23 load_lib mi-support.exp |
| 24 set MIFLAGS "-i=mi" | 24 set MIFLAGS "-i=mi" |
| 25 | 25 |
| 26 gdb_exit | 26 gdb_exit |
| 27 if [mi_gdb_start] { | 27 if [mi_gdb_start] { |
| 28 continue | 28 continue |
| 29 } | 29 } |
| 30 | 30 |
| 31 set testfile "var-cmd" | 31 standard_testfile var-cmd.c |
| 32 set srcfile ${testfile}.c | 32 |
| 33 set binfile ${objdir}/${subdir}/mi-var-invalidate | 33 if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb
ug}] != "" } { |
| 34 if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb
ug additional_flags=-DFAKEARGV}] != "" } { | |
| 35 untested mi-var-invalidate.exp | 34 untested mi-var-invalidate.exp |
| 36 return -1 | 35 return -1 |
| 37 } | 36 } |
| 38 # Just change the output binary. | 37 # Just change the output binary. |
| 39 set binfile_bis ${objdir}/${subdir}/mi-var-invalidate_bis | 38 set binfile_bis [standard_output_file mi-var-invalidate_bis] |
| 40 if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile_bis}" executable
{debug additional_flags=-DFAKEARGV}] != "" } { | 39 if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile_bis}" executable
{debug}] != "" } { |
| 41 untested mi-var-invalidate.exp | 40 untested mi-var-invalidate.exp |
| 42 return -1 | 41 return -1 |
| 43 } | 42 } |
| 44 | 43 |
| 45 set testfile2 "basics" | 44 set testfile2 "basics" |
| 46 set srcfile2 ${testfile2}.c | 45 set srcfile2 ${testfile2}.c |
| 47 set binfile2 ${objdir}/${subdir}/${testfile2} | 46 set binfile2 [standard_output_file ${testfile2}] |
| 48 if { [gdb_compile "${srcdir}/${subdir}/${srcfile2}" "${binfile2}" executable {d
ebug additional_flags=-DFAKEARGV}] != "" } { | 47 if { [gdb_compile "${srcdir}/${subdir}/${srcfile2}" "${binfile2}" executable {d
ebug}] != "" } { |
| 49 untested mi-var-invalidate.exp | 48 untested mi-var-invalidate.exp |
| 50 return -1 | 49 return -1 |
| 51 } | 50 } |
| 52 | 51 |
| 53 mi_delete_breakpoints | 52 mi_delete_breakpoints |
| 54 mi_gdb_reinitialize_dir $srcdir/$subdir | 53 mi_gdb_reinitialize_dir $srcdir/$subdir |
| 55 mi_gdb_load ${binfile} | 54 mi_gdb_load ${binfile} |
| 56 | 55 |
| 57 # Desc: Create global variable. | 56 # Desc: Create global variable. |
| 58 mi_create_varobj global_simple global_simple "create global variable" | 57 mi_create_varobj global_simple global_simple "create global variable" |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 108 mi_gdb_test "-var-update global_simple" \ | 107 mi_gdb_test "-var-update global_simple" \ |
| 109 "\\^done,changelist=\\\[\{name=\"global_simple\",in_scope=\"invalid\",ha
s_more=\"0\"\}\\\]" \ | 108 "\\^done,changelist=\\\[\{name=\"global_simple\",in_scope=\"invalid\",ha
s_more=\"0\"\}\\\]" \ |
| 110 "global_simple not anymore in scope due to binary changes" | 109 "global_simple not anymore in scope due to binary changes" |
| 111 | 110 |
| 112 mi_gdb_test "-var-info-type global_simple" \ | 111 mi_gdb_test "-var-info-type global_simple" \ |
| 113 "\\^done,type=\"\"" \ | 112 "\\^done,type=\"\"" \ |
| 114 "no type for invalid variable global_simple" | 113 "no type for invalid variable global_simple" |
| 115 | 114 |
| 116 mi_gdb_exit | 115 mi_gdb_exit |
| 117 return 0 | 116 return 0 |
| OLD | NEW |