aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.dwarf2/implref-const.exp
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/testsuite/gdb.dwarf2/implref-const.exp')
-rw-r--r--gdb/testsuite/gdb.dwarf2/implref-const.exp40
1 files changed, 21 insertions, 19 deletions
diff --git a/gdb/testsuite/gdb.dwarf2/implref-const.exp b/gdb/testsuite/gdb.dwarf2/implref-const.exp
index 57ccfcd..bebc3b6 100644
--- a/gdb/testsuite/gdb.dwarf2/implref-const.exp
+++ b/gdb/testsuite/gdb.dwarf2/implref-const.exp
@@ -36,7 +36,7 @@ set asm_file [standard_output_file ${srcfile2}]
# For that, we ask GDB by debugging our implref-const program.
# Any program would do, but since we already have implref-const
# specifically for this testcase, might as well use that.
-if [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] {
+if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} {
return -1
}
@@ -45,7 +45,7 @@ if [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] {
Dwarf::assemble ${asm_file} {
cu {} {
DW_TAG_compile_unit {
- {DW_AT_language @DW_LANG_C_plus_plus}
+ DW_AT_language @DW_LANG_C_plus_plus
} {
declare_labels int_label const_label variable_label ref_label
set int_size [get_sizeof "int" -1]
@@ -55,47 +55,49 @@ Dwarf::assemble ${asm_file} {
set var_value 42
int_label: DW_TAG_base_type {
- {DW_AT_byte_size ${int_size} DW_FORM_udata}
- {DW_AT_encoding @DW_ATE_signed}
- {DW_AT_name "int"}
+ DW_AT_byte_size ${int_size} DW_FORM_udata
+ DW_AT_encoding @DW_ATE_signed
+ DW_AT_name "int"
}
ref_label: DW_TAG_reference_type {
- {DW_AT_byte_size ${addr_size} DW_FORM_udata}
- {DW_AT_type :${int_label}}
+ DW_AT_byte_size ${addr_size} DW_FORM_udata
+ DW_AT_type :${int_label}
}
const_label: DW_TAG_const_type {
- {DW_AT_type :${ref_label}}
+ DW_AT_type :${ref_label}
}
DW_TAG_subprogram {
- {MACRO_AT_func { "main" }}
- {DW_AT_type :${int_label}}
- {DW_AT_external 1 DW_FORM_flag}
+ MACRO_AT_func { "main" }
+ DW_AT_type :${int_label}
+ DW_AT_external 1 DW_FORM_flag
} {
variable_label: DW_TAG_variable {
- {DW_AT_name "var"}
- {DW_AT_type :${int_label}}
- {DW_AT_const_value ${var_value} DW_FORM_udata}
+ DW_AT_name "var"
+ DW_AT_type :${int_label}
+ DW_AT_const_value ${var_value} DW_FORM_udata
}
DW_TAG_variable {
- {DW_AT_name "ref"}
- {DW_AT_type :${const_label}}
- {DW_AT_location {DW_OP_GNU_implicit_pointer ${variable_label} 0} SPECIAL_expr}
+ DW_AT_name "ref"
+ DW_AT_type :${const_label}
+ DW_AT_location {
+ DW_OP_GNU_implicit_pointer ${variable_label} 0
+ } SPECIAL_expr
}
}
}
}
}
-if [prepare_for_testing "failed to prepare" ${executable} [list ${asm_file} ${srcfile}] {}] {
+if {[prepare_for_testing "failed to prepare" ${executable} [list ${asm_file} ${srcfile}] {}]} {
return -1
}
# DW_OP_GNU_implicit_pointer implementation requires a valid frame.
-if ![runto_main] {
+if {![runto_main]} {
return -1
}