in reply to Slightly OT - Matching a strange character

Thanks EdwardG for the pun, and Waswas for the direction. The character in question is \222, and it is now neutralized. As are a couple of others I didn't see which had also sneaked in uninvited. Thanks for your help.

Pax vobiscum,

NovMonk

Update: Here's my code that worked:

while (<FILE>){ s/\222/'/g; s/\226/-/g; <do more stuff>; }

The character in question is an octal, which I found in an escaped character table once I used Waswas's idea to see what it really was. Thanks again everyone.

Replies are listed 'Best First'.
Re: Re: Slightly OT - Matching a strange character
by Roy Johnson (Monsignor) on May 19, 2004 at 17:38 UTC
    May I recommend
    tr/\222\226/'-/;
    instead of your two s///'s?

    The PerlMonk tr/// Advocate
      You may indeed. You are a God. Or well, ok, only a Bishop. Regardless, thanks!

      NovMonk