in reply to substituting constants within regex?
People who see this problem are likely using some form of Unix. You likely have a program called dos2unix on your system. Use that on your files.
Barring that, here's a perl one-liner from the Unix prompt that will do the same thing.
% perl -pi~ -e 's/\r//' *.txt
If you really need to do this in your own code, the bit between the single quotes is useful to you.
Update: From above replies, it looks like you do know the difference between '^M' and '\r', but I hope the information is still useful for yourself or others.
--
[ e d @ h a l l e y . c c ]
|
|---|