summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ext/XS-APItest/APItest.xs25
1 files changed, 13 insertions, 12 deletions
diff --git a/ext/XS-APItest/APItest.xs b/ext/XS-APItest/APItest.xs
index f1766c795e..232a309a97 100644
--- a/ext/XS-APItest/APItest.xs
+++ b/ext/XS-APItest/APItest.xs
@@ -2400,21 +2400,22 @@ void
test_coplabel()
PREINIT:
COP *cop;
- char *label;
- int len, utf8;
+ const char *label;
+ STRLEN len;
+ U32 utf8;
CODE:
cop = &PL_compiling;
- Perl_store_cop_label(aTHX_ cop, "foo", 3, 0);
- label = Perl_fetch_cop_label(aTHX_ cop, &len, &utf8);
- if (strcmp(label,"foo")) croak("fail # fetch_cop_label label");
- if (len != 3) croak("fail # fetch_cop_label len");
- if (utf8) croak("fail # fetch_cop_label utf8");
+ Perl_cop_store_label(aTHX_ cop, "foo", 3, 0);
+ label = Perl_cop_fetch_label(aTHX_ cop, &len, &utf8);
+ if (strcmp(label,"foo")) croak("fail # cop_fetch_label label");
+ if (len != 3) croak("fail # cop_fetch_label len");
+ if (utf8) croak("fail # cop_fetch_label utf8");
/* SMALL GERMAN UMLAUT A */
- Perl_store_cop_label(aTHX_ cop, "foä", 4, SVf_UTF8);
- label = Perl_fetch_cop_label(aTHX_ cop, &len, &utf8);
- if (strcmp(label,"foä")) croak("fail # fetch_cop_label label");
- if (len != 3) croak("fail # fetch_cop_label len");
- if (!utf8) croak("fail # fetch_cop_label utf8");
+ Perl_cop_store_label(aTHX_ cop, "foä", 4, SVf_UTF8);
+ label = Perl_cop_fetch_label(aTHX_ cop, &len, &utf8);
+ if (strcmp(label,"foä")) croak("fail # cop_fetch_label label");
+ if (len != 3) croak("fail # cop_fetch_label len");
+ if (!utf8) croak("fail # cop_fetch_label utf8");
HV *