diff options
author | Nick Ing-Simmons <nik@tiuk.ti.com> | 2001-03-19 19:27:57 +0000 |
---|---|---|
committer | Nick Ing-Simmons <nik@tiuk.ti.com> | 2001-03-19 19:27:57 +0000 |
commit | c4d5f83add3e03ac76c328ed8a29701d939174ce (patch) | |
tree | 10e9eac6978b40c3c26b5eff7d3142003a73190a /doop.c | |
parent | 63cd067459124b5dc1d2ae98453df4ffdff11607 (diff) | |
download | perl-c4d5f83add3e03ac76c328ed8a29701d939174ce.tar.gz |
More EBCDIC fixes.
p4raw-id: //depot/perlio@9246
Diffstat (limited to 'doop.c')
-rw-r--r-- | doop.c | 18 |
1 files changed, 12 insertions, 6 deletions
@@ -316,9 +316,11 @@ S_do_trans_simple_utf8(pTHX_ SV *sv)/* SPC - OK */ isutf8 = SvUTF8(sv); if (!isutf8) { U8 *t = s, *e = s + len; - while (t < e) - if ((hibit = !UTF8_IS_INVARIANT(*t++))) + while (t < e) { + U8 ch = *t++; + if ((hibit = !NATIVE_IS_INVARIANT(ch))) break; + } if (hibit) s = bytes_to_utf8(s, &len); } @@ -408,9 +410,11 @@ S_do_trans_count_utf8(pTHX_ SV *sv)/* SPC - OK */ s = (U8*)SvPV(sv, len); if (!SvUTF8(sv)) { U8 *t = s, *e = s + len; - while (t < e) - if ((hibit = !UTF8_IS_INVARIANT(*t++))) + while (t < e) { + U8 ch = *t++; + if ((hibit = !NATIVE_IS_INVARIANT(ch))) break; + } if (hibit) start = s = bytes_to_utf8(s, &len); } @@ -453,9 +457,11 @@ S_do_trans_complex_utf8(pTHX_ SV *sv) /* SPC - NOT OK */ isutf8 = SvUTF8(sv); if (!isutf8) { U8 *t = s, *e = s + len; - while (t < e) - if ((hibit = !UTF8_IS_INVARIANT(*t++))) + while (t < e) { + U8 ch = *t++; + if ((hibit = !NATIVE_IS_INVARIANT(ch))) break; + } if (hibit) s = bytes_to_utf8(s, &len); } |