autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Success (mostly) with the testsuite


From: David Morgan
Subject: Re: Success (mostly) with the testsuite
Date: Wed, 25 Oct 2000 09:31:07 -0700

Hi Akim,

This gets weirder

Akim Demaille wrote:
> 
> >>>>> "David" == David Morgan <address@hidden> writes:
> 
> David> Akim Demaille wrote:
> >> | The script results are: | | .  | 1
> >>
> >> Does it *always* fail, or it's just the operator | which does not
> >> erase failures?
> >>
> >> expr 'a' : '\(a\)'; echo $?
> >>
> >> expr 'a' : '\(b\)' '|' 'a' : '\(a\)'; echo $?
> 
> David> It always fails
> 
> David> Both cases return 'a' and an exit code of 1.
> 
> David> Looks like a buggy OS at this point as I tried the failure case
> David> of just
> 
> David> expr 'a' : '\(b\)' ; echo $?
> 
> David> And I get a 0 with no output.
> 
> Nia?  Are you saying `expr' is always exiting the negation of the
> expected answer?
> 
> expr 'a' : '\(a\)' || echo failure

Gives:
a
failure

> expr 'a' : '\(b\)' && echo failure

Gives:
0
> 
> gives twice failure?  How does the following behave?
> 
> expr 'a' : 'a' || echo failure

Gives:
1
> expr 'a' : 'b' && echo failure

Gives
0

I'd take a guess and say that the expr command doesn't return the right
results for the regular expressions at all.  Please note when I say gives
above this REALLY is the output not exit codes as it may appear.

Regards
 David



reply via email to

[Prev in Thread] Current Thread [Next in Thread]