in reply to Hash key/value

FireBird34: As mentioned above, you don't say how  ' and  ! fail to behave as you 'expect'! Can you give some examples?

Remember, the strings in your OP are single-quoted strings, and the  \ (backslash) has very limited function when used as an escape in a single-quoted string. In essence,  \ only escapes itself and  ' in such a string.

See the discussion of  '' and  q{} in the Quote and Quote like Operators section (and in Quote Like Operators) of perlop.

Replies are listed 'Best First'.
Re^2: Hash key/value
by ikegami (Patriarch) on Nov 26, 2009 at 18:47 UTC

    For example,

    print 'that\'s it', "\n"; print 'that\'s it\!', "\n"; print 'that\'s it\\!', "\n";
    that's it \ escapes the delimiter (') that's it\! \ wasn't followed by the delimiter (') or \ that's it\! \ escapes \

    Contrast with double-quotes:

    print "\"that's it!\"\n"; print "\"that's it\!\"\n"; print "\"that's it\\!\"\n";
    "that's it!" \ escapes " "that's it!" \ escapes ! "that's it\!" \ escapes \
Re^2: Hash key/value
by FireBird34 (Pilgrim) on Nov 26, 2009 at 19:53 UTC
    Problem was resolved. Problem turned out to be me. I didn't properly take into account the extra '. Stupid mistake :) Thank you for the help.