Date: Sun, 26 Jan 2014 21:10:34 +0000 From: Mark Blackman <mark@exonetric.com> To: rank1seeker@gmail.com Cc: hackers@freebsd.org Subject: Re: Is this a regex bug? Message-ID: <E927C3DA-9EBB-42D0-84FB-0009BC5CB0B6@exonetric.com> In-Reply-To: <20140126.210430.622.1@DOMY-PC> References: <20140126.210430.622.1@DOMY-PC>
next in thread | previous in thread | raw e-mail | index | archive | help
On 26 Jan 2014, at 21:04, rank1seeker@gmail.com wrote: > Or am I crazy? >=20 > echo '-m' | egrep '^\-[[:alnum:]]+$' > echo '-n' | egrep '^\-[[:alnum:]]+$' > echo '-o' | egrep '^\-[[:alnum:]]+$' >=20 > Guess what? > Only middle one, '-n' doesn't match it. > Is this an RE bug or I clearly ain't seeing obvious?! >=20 > echo '-n' | egrep '^\-[0-9A-Za-z]+$' > Doesn't work either >=20 > 9.2-RELEASE-p3 i386 -n is being interpreted as an option to =91echo=92 and being swallowed = before it gets to egrep. - Mark=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E927C3DA-9EBB-42D0-84FB-0009BC5CB0B6>