Cool, this appears to work with BSD/Mac sed just as well. Out of curiosity what sed version/OS are you on?