Skip to content

Commit ba37dad

Browse files
committed
S_scan_ident: Add a mnemonic instead of using -1
This makes things clearer.
1 parent e8be3b6 commit ba37dad

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

toke.c

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10773,7 +10773,10 @@ S_scan_ident(pTHX_ char *s, char *dest, char *dest_end, U32 flags)
1077310773
PERL_ARGS_ASSERT_SCAN_IDENT;
1077410774

1077510775
I32 herelines = PL_parser->herelines;
10776-
SSize_t bracket = -1;
10776+
10777+
#define NO_BRACE -1
10778+
SSize_t bracket = NO_BRACE;
10779+
1077710780
char funny = *s++;
1077810781
char *d = dest;
1077910782
char * const e = dest_end - 3; /* two-character token, ending NUL */
@@ -10905,7 +10908,7 @@ S_scan_ident(pTHX_ char *s, char *dest, char *dest_end, U32 flags)
1090510908
* 4) *d is NUL for anything else.
1090610909
*/
1090710910

10908-
if (bracket != -1) { /* Found a '{' */
10911+
if (bracket != NO_BRACE) { /* Found a '{' */
1090910912
bool skip;
1091010913
char *s2;
1091110914

0 commit comments

Comments
 (0)