comparison src/mule-coding.c @ 3695:42e4605ef1de

[xemacs-hg @ 2006-11-23 13:43:17 by aidan] Handle bytes in the range 0x80-0xC0 better when dealing with ISO-IR 196.
author aidan
date Thu, 23 Nov 2006 13:43:29 +0000
parents d1754e7f0cea
children 1abf84db2c7f
comparison
equal deleted inserted replaced
3694:a30f3a38c4ae 3695:42e4605ef1de
1947 { 1947 {
1948 ch = c & 0x1f; 1948 ch = c & 0x1f;
1949 counter = 1; 1949 counter = 1;
1950 } 1950 }
1951 else 1951 else
1952 /* ASCII, or the lower control characters. */ 1952 /* ASCII, or the lower control characters.
1953 Dynarr_add (dst, c); 1953
1954 Perhaps we should signal an error if the character is in
1955 the range 0x80-0xc0; this is illegal UTF-8. */
1956 Dynarr_add (dst, (c & 0x7f));
1954 1957
1955 break; 1958 break;
1956 case 1: 1959 case 1:
1957 ch = (ch << 6) | (c & 0x3f); 1960 ch = (ch << 6) | (c & 0x3f);
1958 chr = Funicode_to_char(make_int(ch), Qnil); 1961 chr = Funicode_to_char(make_int(ch), Qnil);