Can anybody explain this?
With my default locales (LANG=en_US.UTF-8
) i get this:
echo 'ab' | sed 's/[A-B]/!/' # a!
echo 'ab' | sed 's/[B-C]/!/' # ab
echo 'ab' | sed 's/[B]/!/' # ab
But when I set export LANG=C
, everything is fine.
Tested with GNU sed version 4.2.1 on cygwin.