can't read "target_info(target,ldflags)": no such element in array

Tom de Vries <[email protected]>
Newsgroups gmane.comp.sysutils.dejagnu.general
Message-ID <[email protected]>
The current failure in target.test is:
...
can't read "target_info(target,ldflags)": no such element in array
     while executing
"if { $target_info(target,ldflags) == "-Tidp.ld" } {
     incr matches
}"
     (file "../src/testsuite/runtest.all/target.test" line 76)
...

The test fails here:
...
push_config target idp
set matches 0
if { $target_info(target,name) == "idp" } {
     incr matches
}
if { $target_info(target,ldflags) == "-Tidp.ld" } {
     incr matches
}
...

It seems that the test assumes that "push_config target idp" sets 
$target_info(target,ldflags).

But looking at the implementation, it seems we just set 
target_info(target,name):
...
proc push_config { type name } {
     global target_info

     verbose "pushing config for $type, name is $name"
     if {[info exists target_info($type,name)]} {
	if { $target_info($type,name) == $name } {
             error "pushing config for $type, '$name' twice"
         }
     }
     set target_info($type,name) $name
}
...

I'm not sure if the test is incorrect, or the proc.

Thanks,
- Tom
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.