summaryrefslogtreecommitdiff
path: root/doop.c
diff options
context:
space:
mode:
authorNick Ing-Simmons <nik@tiuk.ti.com>2001-03-19 19:27:57 +0000
committerNick Ing-Simmons <nik@tiuk.ti.com>2001-03-19 19:27:57 +0000
commitc4d5f83add3e03ac76c328ed8a29701d939174ce (patch)
tree10e9eac6978b40c3c26b5eff7d3142003a73190a /doop.c
parent63cd067459124b5dc1d2ae98453df4ffdff11607 (diff)
downloadperl-c4d5f83add3e03ac76c328ed8a29701d939174ce.tar.gz
More EBCDIC fixes.
p4raw-id: //depot/perlio@9246
Diffstat (limited to 'doop.c')
-rw-r--r--doop.c18
1 files changed, 12 insertions, 6 deletions
diff --git a/doop.c b/doop.c
index e4a516a1a3..f2bda8b08d 100644
--- a/doop.c
+++ b/doop.c
@@ -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);
}