moriyoshi Thu Mar 4 16:50:21 2004 EDT Modified files: /php-src/ext/mbstring/oniguruma HISTORY oniguruma.h regcomp.c regenc.c regenc.h regex.c regexec.c regint.h regparse.c regposix.c /php-src/ext/mbstring/oniguruma/enc euc_jp.c sjis.c utf8.c Log: - Fix compiler warnings. (Patch by K.Kosako <[EMAIL PROTECTED]>)
http://cvs.php.net/diff.php/php-src/ext/mbstring/oniguruma/HISTORY?r1=1.2&r2=1.3&ty=u Index: php-src/ext/mbstring/oniguruma/HISTORY diff -u php-src/ext/mbstring/oniguruma/HISTORY:1.2 php-src/ext/mbstring/oniguruma/HISTORY:1.3 --- php-src/ext/mbstring/oniguruma/HISTORY:1.2 Sat Feb 28 15:45:24 2004 +++ php-src/ext/mbstring/oniguruma/HISTORY Thu Mar 4 16:50:20 2004 @@ -1,5 +1,20 @@ History +2004/03/04: Version 2.2.4 + +2004/03/04: [impl] (thanks Moriyoshi Koizumi) + fix many warning in Win32 VC++ with /W3 option. + +2004/03/02: Version 2.2.3 + +2004/03/02: [bug] (thanks Isao Sonobe) + return invalid capture region value if capture history + is used. (OP_MEMORY_END_PUSH_REC bug) + ex. /\\g<p>(?@<p>\\(\\g<s>\\)){0}(?<s>(?:\\g<p>)*|){0}/ + .match("((())())") +2004/03/02: [impl] add :nodoc: to onig_stat_print() for RDoc. +2004/03/02: [impl] don't use ONIG_SOURCE_IS_WRAPPED. + 2004/02/27: Version 2.2.2 2004/02/27: [impl] fix the position of onig_stat_print(). @@ -8,7 +23,8 @@ 2004/02/26: Version 2.2.1 -2004/02/26: [bug] invalid definition at onig_error_code_to_str() +2004/02/26: [bug] [bugs.php.net:#26677] (thanks behrens) + invalid definition at onig_error_code_to_str() in the case of NOT HAVE_STDARG_PROTOTYPES. 2004/02/25: Version 2.2.0 http://cvs.php.net/diff.php/php-src/ext/mbstring/oniguruma/oniguruma.h?r1=1.2&r2=1.3&ty=u Index: php-src/ext/mbstring/oniguruma/oniguruma.h diff -u php-src/ext/mbstring/oniguruma/oniguruma.h:1.2 php-src/ext/mbstring/oniguruma/oniguruma.h:1.3 --- php-src/ext/mbstring/oniguruma/oniguruma.h:1.2 Sat Feb 28 15:45:24 2004 +++ php-src/ext/mbstring/oniguruma/oniguruma.h Thu Mar 4 16:50:20 2004 @@ -13,7 +13,7 @@ #define ONIGURUMA #define ONIGURUMA_VERSION_MAJOR 2 #define ONIGURUMA_VERSION_MINOR 2 -#define ONIGURUMA_VERSION_TEENY 2 +#define ONIGURUMA_VERSION_TEENY 4 #ifndef P_ #if defined(__STDC__) || defined(_WIN32) http://cvs.php.net/diff.php/php-src/ext/mbstring/oniguruma/regcomp.c?r1=1.2&r2=1.3&ty=u Index: php-src/ext/mbstring/oniguruma/regcomp.c diff -u php-src/ext/mbstring/oniguruma/regcomp.c:1.2 php-src/ext/mbstring/oniguruma/regcomp.c:1.3 --- php-src/ext/mbstring/oniguruma/regcomp.c:1.2 Sat Feb 28 15:45:24 2004 +++ php-src/ext/mbstring/oniguruma/regcomp.c Thu Mar 4 16:50:20 2004 @@ -830,7 +830,7 @@ r = compile_tree_empty_check(qn->target, reg, empty_info); if (r) return r; r = add_opcode_rel_addr(reg, OP_JUMP, - -(mod_tlen + SIZE_OP_JUMP + SIZE_OP_PUSH_OR_JUMP_EXACT1)); + -(mod_tlen + (int )SIZE_OP_JUMP + (int )SIZE_OP_PUSH_OR_JUMP_EXACT1)); } else if (IS_NOT_NULL(qn->next_head_exact)) { r = add_opcode_rel_addr(reg, OP_PUSH_IF_PEEK_NEXT, @@ -840,7 +840,7 @@ r = compile_tree_empty_check(qn->target, reg, empty_info); if (r) return r; r = add_opcode_rel_addr(reg, OP_JUMP, - -(mod_tlen + SIZE_OP_JUMP + SIZE_OP_PUSH_IF_PEEK_NEXT)); + -(mod_tlen + (int )SIZE_OP_JUMP + (int )SIZE_OP_PUSH_IF_PEEK_NEXT)); } else { r = add_opcode_rel_addr(reg, OP_PUSH, mod_tlen + SIZE_OP_JUMP); @@ -848,7 +848,7 @@ r = compile_tree_empty_check(qn->target, reg, empty_info); if (r) return r; r = add_opcode_rel_addr(reg, OP_JUMP, - -(mod_tlen + SIZE_OP_JUMP + SIZE_OP_PUSH)); + -(mod_tlen + (int )SIZE_OP_JUMP + (int )SIZE_OP_PUSH)); } } else { @@ -856,7 +856,7 @@ if (r) return r; r = compile_tree_empty_check(qn->target, reg, empty_info); if (r) return r; - r = add_opcode_rel_addr(reg, OP_PUSH, -(mod_tlen + SIZE_OP_PUSH)); + r = add_opcode_rel_addr(reg, OP_PUSH, -(mod_tlen + (int )SIZE_OP_PUSH)); } } else if (qn->upper == 0 && qn->is_refered != 0) { /* /(?<n>..){0}/ */ @@ -1088,7 +1088,7 @@ r = add_opcode(reg, OP_POP); if (r) return r; r = add_opcode_rel_addr(reg, OP_JUMP, - -(SIZE_OP_PUSH + len + SIZE_OP_POP + SIZE_OP_JUMP)); + -((int )SIZE_OP_PUSH + len + (int )SIZE_OP_POP + (int )SIZE_OP_JUMP)); } else { r = add_opcode(reg, OP_PUSH_STOP_BT); @@ -3803,7 +3803,7 @@ if (to->expr.len > 0) { if (add->len.max > 0) { - if (to->expr.len > add->len.max) + if (to->expr.len > (int )add->len.max) to->expr.len = add->len.max; if (to->expr.mmd.max == 0) http://cvs.php.net/diff.php/php-src/ext/mbstring/oniguruma/regenc.c?r1=1.1&r2=1.2&ty=u Index: php-src/ext/mbstring/oniguruma/regenc.c diff -u php-src/ext/mbstring/oniguruma/regenc.c:1.1 php-src/ext/mbstring/oniguruma/regenc.c:1.2 --- php-src/ext/mbstring/oniguruma/regenc.c:1.1 Sat Feb 28 15:45:24 2004 +++ php-src/ext/mbstring/oniguruma/regenc.c Thu Mar 4 16:50:20 2004 @@ -233,7 +233,7 @@ extern int onigenc_single_byte_code_to_mbc(OnigCodePoint code, UChar *buf) { - *buf = (code & 0xff); + *buf = (UChar )(code & 0xff); return 1; } @@ -355,9 +355,9 @@ UChar *p = buf; if ((code & 0xff00) != 0) { - *p++ = ((code >> 8) & 0xff); + *p++ = (UChar )((code >> 8) & 0xff); } - *p++ = (code & 0xff); + *p++ = (UChar )(code & 0xff); #if 1 if (enc_len(enc, buf[0]) != (p - buf)) @@ -372,15 +372,15 @@ UChar *p = buf; if ((code & 0xff000000) != 0) { - *p++ = ((code >> 24) & 0xff); + *p++ = (UChar )((code >> 24) & 0xff); } if ((code & 0xff0000) != 0) { - *p++ = ((code >> 16) & 0xff); + *p++ = (UChar )((code >> 16) & 0xff); } if ((code & 0xff00) != 0) { - *p++ = ((code >> 8) & 0xff); + *p++ = (UChar )((code >> 8) & 0xff); } - *p++ = (code & 0xff); + *p++ = (UChar )(code & 0xff); #if 1 if (enc_len(enc, buf[0]) != (p - buf)) http://cvs.php.net/diff.php/php-src/ext/mbstring/oniguruma/regenc.h?r1=1.1&r2=1.2&ty=u Index: php-src/ext/mbstring/oniguruma/regenc.h diff -u php-src/ext/mbstring/oniguruma/regenc.h:1.1 php-src/ext/mbstring/oniguruma/regenc.h:1.2 --- php-src/ext/mbstring/oniguruma/regenc.h:1.1 Sat Feb 28 15:45:24 2004 +++ php-src/ext/mbstring/oniguruma/regenc.h Thu Mar 4 16:50:20 2004 @@ -8,10 +8,9 @@ #ifndef REGENC_H #define REGENC_H -#ifndef ONIG_SOURCE_IS_WRAPPED +#ifndef RUBY_PLATFORM #include "config.h" #endif - #include "oniguruma.h" #ifndef NULL http://cvs.php.net/diff.php/php-src/ext/mbstring/oniguruma/regex.c?r1=1.2&r2=1.3&ty=u Index: php-src/ext/mbstring/oniguruma/regex.c diff -u php-src/ext/mbstring/oniguruma/regex.c:1.2 php-src/ext/mbstring/oniguruma/regex.c:1.3 --- php-src/ext/mbstring/oniguruma/regex.c:1.2 Sat Feb 28 15:45:24 2004 +++ php-src/ext/mbstring/oniguruma/regex.c Thu Mar 4 16:50:20 2004 @@ -8,8 +8,6 @@ /* * Source wrapper for Ruby. */ -#define ONIG_SOURCE_IS_WRAPPED - #include "regint.h" #include "regex.h" http://cvs.php.net/diff.php/php-src/ext/mbstring/oniguruma/regexec.c?r1=1.2&r2=1.3&ty=u Index: php-src/ext/mbstring/oniguruma/regexec.c diff -u php-src/ext/mbstring/oniguruma/regexec.c:1.2 php-src/ext/mbstring/oniguruma/regexec.c:1.3 --- php-src/ext/mbstring/oniguruma/regexec.c:1.2 Sat Feb 28 15:45:24 2004 +++ php-src/ext/mbstring/oniguruma/regexec.c Thu Mar 4 16:50:20 2004 @@ -935,6 +935,9 @@ } while (0) #ifdef RUBY_PLATFORM +/* + * :nodoc: + */ static VALUE onig_stat_print() { onig_print_statistics(stderr); @@ -951,7 +954,7 @@ MaxStackDepth = 0; #ifdef RUBY_PLATFORM - ONIG_RUBY_DEFINE_GLOBAL_FUNCTION("onig_stat_print", onig_stat_print, 0); + rb_define_global_function("onig_stat_print", onig_stat_print, 0); #endif } @@ -984,7 +987,7 @@ onig_is_in_code_range(UChar* p, OnigCodePoint code) { OnigCodePoint n, *data; - int low, high, x; + OnigCodePoint low, high, x; GET_CODE_POINT(n, p); data = (OnigCodePoint* )p; @@ -1779,8 +1782,8 @@ #ifdef USE_SUBEXP_CALL case OP_MEMORY_END_PUSH_REC: STAT_OP_IN(OP_MEMORY_END_PUSH_REC); GET_MEMNUM_INC(mem, p); + STACK_GET_MEM_START(mem, stkp); /* should be before push mem-end. */ STACK_PUSH_MEM_END(mem, s); - STACK_GET_MEM_START(mem, stkp); mem_start_stk[mem] = GET_STACK_INDEX(stkp); STAT_OP_OUT; continue; @@ -1790,7 +1793,12 @@ GET_MEMNUM_INC(mem, p); mem_end_stk[mem] = (StackIndex )((void* )s); STACK_GET_MEM_START(mem, stkp); - mem_start_stk[mem] = GET_STACK_INDEX(stkp); + + if (BIT_STATUS_AT(reg->bt_mem_start, mem)) + mem_start_stk[mem] = GET_STACK_INDEX(stkp); + else + mem_start_stk[mem] = (StackIndex )((void* )stkp->u.mem.pstr); + STACK_PUSH_MEM_END_MARK(mem); STAT_OP_OUT; continue; @@ -3044,11 +3052,11 @@ semi_end = end; end_buf: - if (semi_end - str < reg->anchor_dmin) + if ((OnigDistance )(semi_end - str) < reg->anchor_dmin) goto mismatch_no_msa; if (range > start) { - if (semi_end - start > reg->anchor_dmax) { + if ((OnigDistance )(semi_end - start) > reg->anchor_dmax) { start = semi_end - reg->anchor_dmax; if (start < end) start = onigenc_get_right_adjust_char_head(reg->enc, str, start); @@ -3056,17 +3064,17 @@ start = onigenc_get_prev_char_head(reg->enc, str, end); } } - if (semi_end - (range - 1) < reg->anchor_dmin) { + if ((OnigDistance )(semi_end - (range - 1)) < reg->anchor_dmin) { range = semi_end - reg->anchor_dmin + 1; } if (start >= range) goto mismatch_no_msa; } else { - if (semi_end - range > reg->anchor_dmax) { + if ((OnigDistance )(semi_end - range) > reg->anchor_dmax) { range = semi_end - reg->anchor_dmax; } - if (semi_end - start < reg->anchor_dmin) { + if ((OnigDistance )(semi_end - start) < reg->anchor_dmin) { start = semi_end - reg->anchor_dmin; start = ONIGENC_LEFT_ADJUST_CHAR_HEAD(reg->enc, str, start); if (range > start) goto mismatch_no_msa; http://cvs.php.net/diff.php/php-src/ext/mbstring/oniguruma/regint.h?r1=1.2&r2=1.3&ty=u Index: php-src/ext/mbstring/oniguruma/regint.h diff -u php-src/ext/mbstring/oniguruma/regint.h:1.2 php-src/ext/mbstring/oniguruma/regint.h:1.3 --- php-src/ext/mbstring/oniguruma/regint.h:1.2 Sat Feb 28 15:45:24 2004 +++ php-src/ext/mbstring/oniguruma/regint.h Thu Mar 4 16:50:20 2004 @@ -79,8 +79,6 @@ #endif #endif -#define ONIG_RUBY_DEFINE_GLOBAL_FUNCTION(s,f,n) \ - rb_define_global_function(s, f, n) #endif /* else NOT_RUBY */ #define THREAD_PASS_LIMIT_COUNT 10 @@ -340,14 +338,14 @@ } while (0) #define BBUF_EXPAND(buf,low) do{\ - do { (buf)->alloc *= 2; } while ((buf)->alloc < low);\ + do { (buf)->alloc *= 2; } while ((buf)->alloc < (unsigned int )low);\ (buf)->p = (UChar* )xrealloc((buf)->p, (buf)->alloc);\ if (IS_NULL((buf)->p)) return(ONIGERR_MEMORY);\ } while (0) #define BBUF_ENSURE_SIZE(buf,size) do{\ - int new_alloc = (buf)->alloc;\ - while (new_alloc < (size)) { new_alloc *= 2; }\ + unsigned int new_alloc = (buf)->alloc;\ + while (new_alloc < (unsigned int )(size)) { new_alloc *= 2; }\ if ((buf)->alloc != new_alloc) {\ (buf)->p = (UChar* )xrealloc((buf)->p, new_alloc);\ if (IS_NULL((buf)->p)) return(ONIGERR_MEMORY);\ @@ -357,16 +355,16 @@ #define BBUF_WRITE(buf,pos,bytes,n) do{\ int used = (pos) + (n);\ - if ((buf)->alloc < used) BBUF_EXPAND((buf),used);\ + if ((buf)->alloc < (unsigned int )used) BBUF_EXPAND((buf),used);\ xmemcpy((buf)->p + (pos), (bytes), (n));\ - if ((buf)->used < used) (buf)->used = used;\ + if ((buf)->used < (unsigned int )used) (buf)->used = used;\ } while (0) #define BBUF_WRITE1(buf,pos,byte) do{\ int used = (pos) + 1;\ - if ((buf)->alloc < used) BBUF_EXPAND((buf),used);\ + if ((buf)->alloc < (unsigned int )used) BBUF_EXPAND((buf),used);\ (buf)->p[(pos)] = (byte);\ - if ((buf)->used < used) (buf)->used = used;\ + if ((buf)->used < (unsigned int )used) (buf)->used = used;\ } while (0) #define BBUF_ADD(buf,bytes,n) BBUF_WRITE((buf),(buf)->used,(bytes),(n)) @@ -376,9 +374,9 @@ /* from < to */ #define BBUF_MOVE_RIGHT(buf,from,to,n) do {\ - if ((to) + (n) > (buf)->alloc) BBUF_EXPAND((buf),(to) + (n));\ + if ((unsigned int )((to)+(n)) > (buf)->alloc) BBUF_EXPAND((buf),(to) + (n));\ xmemmove((buf)->p + (to), (buf)->p + (from), (n));\ - if ((to) + (n) > (buf)->used) (buf)->used = (to) + (n);\ + if ((unsigned int )((to)+(n)) > (buf)->used) (buf)->used = (to) + (n);\ } while (0) /* from > to */ @@ -639,12 +637,12 @@ typedef struct { - OnigCodePoint esc; - OnigCodePoint anychar; - OnigCodePoint anytime; - OnigCodePoint zero_or_one_time; - OnigCodePoint one_or_more_time; - OnigCodePoint anychar_anytime; + UChar esc; + UChar anychar; + UChar anytime; + UChar zero_or_one_time; + UChar one_or_more_time; + UChar anychar_anytime; } OnigMetaCharTableType; extern OnigMetaCharTableType OnigMetaCharTable; http://cvs.php.net/diff.php/php-src/ext/mbstring/oniguruma/regparse.c?r1=1.2&r2=1.3&ty=u Index: php-src/ext/mbstring/oniguruma/regparse.c diff -u php-src/ext/mbstring/oniguruma/regparse.c:1.2 php-src/ext/mbstring/oniguruma/regparse.c:1.3 --- php-src/ext/mbstring/oniguruma/regparse.c:1.2 Sat Feb 28 15:45:24 2004 +++ php-src/ext/mbstring/oniguruma/regparse.c Thu Mar 4 16:50:20 2004 @@ -1585,7 +1585,7 @@ to = data[(high - 1)*2 + 1]; } - if (inc_n != 0 && high < n) { + if (inc_n != 0 && (OnigCodePoint )high < n) { int from_pos = SIZE_CODE_POINT * (1 + high * 2); int to_pos = SIZE_CODE_POINT * (1 + (low + 1) * 2); int size = (n - high) * 2 * SIZE_CODE_POINT; @@ -1666,8 +1666,8 @@ static int or_code_range_buf(BBuf* bbuf1, int not1, BBuf* bbuf2, int not2, BBuf** pbuf) { - int i, r; - OnigCodePoint n1, *data1; + int r; + OnigCodePoint i, n1, *data1; OnigCodePoint from, to; *pbuf = (BBuf* )NULL; @@ -1762,8 +1762,8 @@ static int and_code_range_buf(BBuf* bbuf1, int not1, BBuf* bbuf2, int not2, BBuf** pbuf) { - int i, j, r; - OnigCodePoint n1, n2, *data1, *data2; + int r; + OnigCodePoint i, j, n1, n2, *data1, *data2; OnigCodePoint from, to, from1, to1, from2, to2; *pbuf = (BBuf* )NULL; @@ -3212,8 +3212,9 @@ add_ctype_to_cc_by_list(CClassNode* cc, int ctype, int not, OnigEncoding enc) { - int i, j, r, nsb, nmb; + int i, r, nsb, nmb; OnigCodePointRange *sbr, *mbr; + OnigCodePoint j; r = ONIGENC_GET_CTYPE_CODE_RANGE(enc, ctype, &nsb, &nmb, &sbr, &mbr); if (r != 0) return r; http://cvs.php.net/diff.php/php-src/ext/mbstring/oniguruma/regposix.c?r1=1.2&r2=1.3&ty=u Index: php-src/ext/mbstring/oniguruma/regposix.c diff -u php-src/ext/mbstring/oniguruma/regposix.c:1.2 php-src/ext/mbstring/oniguruma/regposix.c:1.3 --- php-src/ext/mbstring/oniguruma/regposix.c:1.2 Sat Feb 28 15:45:24 2004 +++ php-src/ext/mbstring/oniguruma/regposix.c Thu Mar 4 16:50:20 2004 @@ -166,7 +166,7 @@ } else if (r == ONIG_MISMATCH) { r = REG_NOMATCH; - for (i = 0; i < nmatch; i++) + for (i = 0; i < (int )nmatch; i++) pmatch[i].rm_so = pmatch[i].rm_eo = ONIG_REGION_NOTPOS; } else { http://cvs.php.net/diff.php/php-src/ext/mbstring/oniguruma/enc/euc_jp.c?r1=1.1&r2=1.2&ty=u Index: php-src/ext/mbstring/oniguruma/enc/euc_jp.c diff -u php-src/ext/mbstring/oniguruma/enc/euc_jp.c:1.1 php-src/ext/mbstring/oniguruma/enc/euc_jp.c:1.2 --- php-src/ext/mbstring/oniguruma/enc/euc_jp.c:1.1 Sat Feb 28 15:46:06 2004 +++ php-src/ext/mbstring/oniguruma/enc/euc_jp.c Thu Mar 4 16:50:21 2004 @@ -70,9 +70,9 @@ { UChar *p = buf; - if ((code & 0xff0000) != 0) *p++ = ((code >> 16) & 0xff); - if ((code & 0xff00) != 0) *p++ = ((code >> 8) & 0xff); - *p++ = (code & 0xff); + if ((code & 0xff0000) != 0) *p++ = (UChar )(((code >> 16) & 0xff)); + if ((code & 0xff00) != 0) *p++ = (UChar )(((code >> 8) & 0xff)); + *p++ = (UChar )(code & 0xff); #if 1 if (enc_len(ONIG_ENCODING_EUC_JP, buf[0]) != (p - buf)) http://cvs.php.net/diff.php/php-src/ext/mbstring/oniguruma/enc/sjis.c?r1=1.1&r2=1.2&ty=u Index: php-src/ext/mbstring/oniguruma/enc/sjis.c diff -u php-src/ext/mbstring/oniguruma/enc/sjis.c:1.1 php-src/ext/mbstring/oniguruma/enc/sjis.c:1.2 --- php-src/ext/mbstring/oniguruma/enc/sjis.c:1.1 Sat Feb 28 15:46:06 2004 +++ php-src/ext/mbstring/oniguruma/enc/sjis.c Thu Mar 4 16:50:21 2004 @@ -53,8 +53,8 @@ { UChar *p = buf; - if ((code & 0xff00) != 0) *p++ = ((code >> 8) & 0xff); - *p++ = (code & 0xff); + if ((code & 0xff00) != 0) *p++ = (UChar )(((code >> 8) & 0xff)); + *p++ = (UChar )(code & 0xff); #if 0 if (enc_len(ONIG_ENCODING_SJIS, buf[0]) != (p - buf)) http://cvs.php.net/diff.php/php-src/ext/mbstring/oniguruma/enc/utf8.c?r1=1.1&r2=1.2&ty=u Index: php-src/ext/mbstring/oniguruma/enc/utf8.c diff -u php-src/ext/mbstring/oniguruma/enc/utf8.c:1.1 php-src/ext/mbstring/oniguruma/enc/utf8.c:1.2 --- php-src/ext/mbstring/oniguruma/enc/utf8.c:1.1 Sat Feb 28 15:46:06 2004 +++ php-src/ext/mbstring/oniguruma/enc/utf8.c Thu Mar 4 16:50:21 2004 @@ -112,36 +112,36 @@ static int utf8_code_to_mbc(OnigCodePoint code, UChar *buf) { -#define UTF8_TRAILS(code, shift) ((((code) >> (shift)) & 0x3f) | 0x80) -#define UTF8_TRAIL0(code) (((code) & 0x3f) | 0x80) +#define UTF8_TRAILS(code, shift) (UChar )((((code) >> (shift)) & 0x3f) | 0x80) +#define UTF8_TRAIL0(code) (UChar )(((code) & 0x3f) | 0x80) if ((code & 0xffffff80) == 0) { - *buf = code; + *buf = (UChar )code; return 1; } else { UChar *p = buf; if ((code & 0xfffff800) == 0) { - *p++ = ((code>>6)& 0x1f) | 0xc0; + *p++ = (UChar )(((code>>6)& 0x1f) | 0xc0); } else if ((code & 0xffff0000) == 0) { - *p++ = ((code>>12) & 0x0f) | 0xe0; + *p++ = (UChar )(((code>>12) & 0x0f) | 0xe0); *p++ = UTF8_TRAILS(code, 6); } else if ((code & 0xffe00000) == 0) { - *p++ = ((code>>18) & 0x07) | 0xf0; + *p++ = (UChar )(((code>>18) & 0x07) | 0xf0); *p++ = UTF8_TRAILS(code, 12); *p++ = UTF8_TRAILS(code, 6); } else if ((code & 0xfc000000) == 0) { - *p++ = ((code>>24) & 0x03) | 0xf8; + *p++ = (UChar )(((code>>24) & 0x03) | 0xf8); *p++ = UTF8_TRAILS(code, 18); *p++ = UTF8_TRAILS(code, 12); *p++ = UTF8_TRAILS(code, 6); } else if ((code & 0x80000000) == 0) { - *p++ = ((code>>30) & 0x01) | 0xfc; + *p++ = (UChar )(((code>>30) & 0x01) | 0xfc); *p++ = UTF8_TRAILS(code, 24); *p++ = UTF8_TRAILS(code, 18); *p++ = UTF8_TRAILS(code, 12);
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php