This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Reenabling Ada by default


On Sep 9, 2004, at 2:28 PM, Laurent GUERBY wrote:
On Thu, 2004-09-09 at 23:18, Mike Stump wrote:

Curious, does an infinite loop take more than a minute or two?  If it
does, I expect [yes, that was a pun] the timeout is wrong.

:) If any dejagnu/expect expert is willing to provide a GCC-fashionable harness for Ada that would add some kind of timeout handling.

This is trivial... which is why I mentioned it...


#!/usr/bin/expect -f

set dest [spawn sleep 500]

set timeout 180

expect $dest {
        -re "Bus Error" {
                exit 1
        }
        timeout {
                warning "Program timed out."
                exit 1
        }
}

You can interpose this between the thing that runs the testcases and the testcase. If you need I/O, that would be just a little bit trickier, but not all that hard.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]