Hello all :)

    I'm using coreutils 5.2.1 and I've noticed a weird behaviour of
'expr'. I don't know if it's my fault, but a command like:

    $ expr "x" : "[:alpha:]"

    returns 0 instead of 1, but a command like:

    $ expr "x" : "[[:alpha:]]"

    returns 1, correctly. That is, 'expr' understands character
classes but it needs that double bracket :( This is non portable
AFAIK, at least is not SUSv3 compliant regarding basic regular
expressions, and other binaries like 'tr' or 'grep' correctly use the
single bracket character classes.

    Am I doing something wrong?

    Thanks a lot in advance :)

    Ra�l N��ez de Arenas Coronado

-- 
Linux Registered User 88736
http://www.pleyades.net & http://raul.pleyades.net/


_______________________________________________
Bug-coreutils mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/bug-coreutils

Reply via email to