I tried to sync with the gnulib lib/reg* code which now spans several files. All went well except for one thing. Using CVS grep of 2007-11-25:

--
% echo '-' | src/grep -E -e 'a[b-a]' ; echo $?
1
--

Return code of 1 for and invalid range in a character class is exactly what Spenser test#37 expects. However, once the regex code is pulled in from gnulib, I get:

--
% echo '-' | src/grep -E -e 'a[b-a]' ; echo $? ;
src/grep: Invalid range end
2
--

The return code of 2 causes Spenser test#37 to fail. I am thinking that one of the following needs to be done (in order of my preference):

1) Correct Spenser test#37 to expect 2 as the return code.
2) Correct src/grep.c to always return 1 on error
3) Report a bug to gnulib that "Invalid range end" is misbehaving

Any return code experts out there?

Cheers,

TAA

--
Tony Abou-Assaleh
Email:    [EMAIL PROTECTED]
Web site: http://tony.abou-assaleh.net


Reply via email to