autoconf-patches
[Top][All Lists]
Advanced

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

Re: [PATCH] Use expr where possible


From: Paul Eggert
Subject: Re: [PATCH] Use expr where possible
Date: Wed, 15 Jun 2005 01:42:21 -0700
User-agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.4 (gnu/linux)

"Peter O'Gorman" <address@hidden> writes:

> % expr "Xpowerpc-apple-darwin8.1.0" : 'X[^--]*-[^--]*-\(.*\)'

How about the following instead?  I'd rather use a simpler regexp if
it works.  Can you please verify that this works on the broken
implementation?  Thanks.

$ expr 'Xpowerpc-apple-darwin8.1.0' : '.*-\(.*\)'
darwin8.1.0
$ expr 'Xpowerpc-apple-darwin8.1.0' : '.*-\(.*\)-.*'
apple
$ expr 'Xpowerpc-apple-darwin8.1.0' : 'X\(.*\)-.*-'
powerpc




reply via email to

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