in reply to constants in an RE

Using Unicode Character names (Creating Unicode) avoids your problem. It has the further advantage that it eliminates confusion between similar looking characters.
use strict; use warnings; use utf8; use Test::More tests=>1; my $string = "wjzw’xl cowuxze."; my $required = "wjzw\N{APOSTROPHE}xl cowuxze."; #"wjzw'xl cowuxze. +"; $string =~ s/\N{RIGHT SINGLE QUOTATION MARK}/'/ ; is( $string, $required, 'APOSTROPHE' );

UPDATE: Added link

Bill