chr() and character set

Discussion in 'Perl Misc' started by Peter Michael, Nov 4, 2004.

  1. Hi,

    perlfunc(1) says about chr()

    Returns the character represented by that NUMBER in the
    character set.

    Which character set is this exactly and how can it be
    controlled programmatically (in particular for arguments in
    the range 128..255)?

    Thanks for any hints.

    Peter
    Peter Michael, Nov 4, 2004
    #1
    1. Advertising

  2. Peter Michael wrote:

    > perlfunc(1) says about chr()
    >
    > Returns the character represented by that NUMBER in the
    > character set.
    >
    > Which character set is this exactly and how can it be
    > controlled programmatically (in particular for arguments in
    > the range 128..255)?


    The short answer is Unicode. Which IIRC is the same as ISO-Latin1 for
    that range.

    But for details read the rest of the entry where it goes on to explain
    all this.

    If it doesn't then your version of Perl is old and doesn't understand
    character sets. In that case strings are simply strings of bytes and
    the concept of "which character set" does not apply.
    Brian McCauley, Nov 4, 2004
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. crjunk
    Replies:
    2
    Views:
    16,821
    crjunk
    Aug 8, 2003
  2. Andi Twine
    Replies:
    3
    Views:
    540
    Natty Gur
    Jan 13, 2004
  3. =?Utf-8?B?RGFuIE5hc2g=?=

    C# equiv of Chr(13)

    =?Utf-8?B?RGFuIE5hc2g=?=, Nov 1, 2004, in forum: ASP .Net
    Replies:
    12
    Views:
    74,220
    Dudeman3000
    Feb 22, 2010
  4. ProJee
    Replies:
    3
    Views:
    428
    ProJee
    Nov 17, 2004
  5. MattB
    Replies:
    3
    Views:
    542
    =?Utf-8?B?Q293Ym95IChHcmVnb3J5IEEuIEJlYW1lcikgLSBN
    Nov 19, 2004
Loading...

Share This Page