For example you cannot force little-endianness on a type that
is inside a big-endian group.
+=item Can't use keyword '%s' as a label
+
+(F) You attempted to use a reserved keyword, such as C<print> or C<BEGIN>,
+as a statement label. This is disallowed since Perl 5.11.0.
+
=item Can't use "my %s" in sort comparison
(F) The global variables $a and $b are reserved for sort comparisons.
while (d < PL_bufend && isSPACE(*d))
d++; /* no comments skipped here, or s### is misparsed */
- /* Check for keywords */
- tmp = keyword(PL_tokenbuf, len, 0);
-
/* Is this a label? */
if (!tmp && PL_expect == XSTATE
&& d < PL_bufend && *d == ':' && *(d + 1) != ':') {
+ tmp = keyword(PL_tokenbuf, len, 0);
+ if (tmp)
+ Perl_croak(aTHX_ "Can't use keyword '%s' as a label", PL_tokenbuf);
s = d + 1;
pl_yylval.pval = CopLABEL_alloc(PL_tokenbuf);
CLINE;
TOKEN(LABEL);
}
+ else
+ /* Check for keywords */
+ tmp = keyword(PL_tokenbuf, len, 0);
/* Is this a word before a => operator? */
if (*d == '=' && d[1] == '>') {