summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>2002-01-23 18:30:18 +0000
committerJarkko Hietaniemi <jhi@iki.fi>2002-01-23 18:30:18 +0000
commit753ec01cd1a343383d22b11f4db9f53b07aa2e34 (patch)
treefefcb315a0b85f14af117a5d3645c55c8357d7cf
parent6df78d398528fa2d8ab918761591357e39069e40 (diff)
downloadperl-753ec01cd1a343383d22b11f4db9f53b07aa2e34.tar.gz
Unused (the only occurrence of USE_BYTES_DOWNGRADES) and
therefore quite probably also obsolete code. p4raw-id: //depot/perl@14390
-rw-r--r--sv.c22
1 files changed, 0 insertions, 22 deletions
diff --git a/sv.c b/sv.c
index 2fbabb0214..b9a64381d4 100644
--- a/sv.c
+++ b/sv.c
@@ -3372,28 +3372,6 @@ Perl_sv_utf8_downgrade(pTHX_ register SV* sv, bool fail_ok)
if (!utf8_to_bytes(s, &len)) {
if (fail_ok)
return FALSE;
-#ifdef USE_BYTES_DOWNGRADES
- else if (IN_BYTES) {
- U8 *d = s;
- U8 *e = (U8 *) SvEND(sv);
- int first = 1;
- while (s < e) {
- UV ch = utf8n_to_uvchr(s,(e-s),&len,0);
- if (first && ch > 255) {
- if (PL_op)
- Perl_warner(aTHX_ WARN_UTF8, "Wide character in byte %s",
- OP_DESC(PL_op);
- else
- Perl_warner(aTHX_ WARN_UTF8, "Wide character in byte");
- first = 0;
- }
- *d++ = ch;
- s += len;
- }
- *d = '\0';
- len = (d - (U8 *) SvPVX(sv));
- }
-#endif
else {
if (PL_op)
Perl_croak(aTHX_ "Wide character in %s",