From ee9f418e9fe4517f9ee955619a6d69ab669060ac Mon Sep 17 00:00:00 2001 From: Wolfgang Laun Date: Sat, 3 Feb 2007 17:23:48 +0100 Subject: [PATCH] perlop.pod - proposal to add an explanation of \c From: "Wolfgang Laun" Message-ID: <17de7ee80702030723m4265bbfkc83644d55a24aa0@mail.gmail.com> p4raw-id: //depot/perl@30150 --- pod/perlop.pod | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/pod/perlop.pod b/pod/perlop.pod index 7b84a68..f4ee795 100644 --- a/pod/perlop.pod +++ b/pod/perlop.pod @@ -962,14 +962,22 @@ X<\t> X<\n> X<\r> X<\f> X<\b> X<\a> X<\e> X<\x> X<\0> X<\c> X<\N> \b backspace (BS) \a alarm (bell) (BEL) \e escape (ESC) - \033 octal char (ESC) - \x1b hex char (ESC) - \x{263a} wide hex char (SMILEY) - \c[ control char (ESC) + \033 octal char (example: ESC) + \x1b hex char (example: ESC) + \x{263a} wide hex char (example: SMILEY) + \c[ control char (example: ESC) \N{name} named Unicode character +The character following C<\c> is mapped to some other character by +converting letters to upper case and then (on ASCII systems) by inverting +the 7th bit (0x40). The most interesting range is from '@' to '_' +(0x40 through 0x5F), resulting in a control character from 0x00 +through 0x1F. A '?' maps to the DEL character. On EBCDIC systems only +'@', the letters, '[', '\', ']', '^', '_' and '?' will work, resulting +in 0x00 through 0x1F and 0x7F. + B: Unlike C and other languages, Perl has no \v escape sequence for -the vertical tab (VT - ASCII 11). +the vertical tab (VT - ASCII 11), but you may use C<\ck> or C<\x0b>. The following escape sequences are available in constructs that interpolate but not in transliterations. -- 2.7.4