Skip to content

Commit 2e79379

Browse files
committed
WS Cleanup Stage #10 - reflow C comments (2)
1 parent edbd2dd commit 2e79379

18 files changed

+623
-374
lines changed

cop.h

+25-19
Original file line numberDiff line numberDiff line change
@@ -440,11 +440,12 @@ struct cop {
440440
#endif
441441
U32 cop_hints; /* hints bits from pragmata */
442442
U32 cop_seq; /* parse sequence number */
443-
char *cop_warnings; /* Lexical warnings bitmask vector. Refcounted
444-
shared copy of ${^WARNING_BITS}. This
445-
pointer either points at one of the magic
446-
values for warnings, or it points at a
447-
buffer constructed with rcpv_new(). Use the
443+
char *cop_warnings; /* Lexical warnings bitmask vector.
444+
Refcounted shared copy of
445+
${^WARNING_BITS}. This pointer either
446+
points at one of the magic values for
447+
warnings, or it points at a buffer
448+
constructed with rcpv_new(). Use the
448449
RCPV_LEN() macro to get its length.
449450
*/
450451
/* compile time state of %^H. See the comment in op.c for how
@@ -551,8 +552,8 @@ typedef struct rcpv RCPV;
551552
#define RCPVx(pv_arg) \
552553
((RCPV *)((pv_arg) - STRUCT_OFFSET(struct rcpv, pv)))
553554
#define RCPV_REFCOUNT(pv) (RCPVx(pv)->refcount)
554-
#define RCPV_LEN(pv) (RCPVx(pv)->len-1) /* len always includes space
555-
for a null */
555+
#define RCPV_LEN(pv) (RCPVx(pv)->len-1) /* len always includes
556+
space for a null */
556557

557558
#ifdef USE_ITHREADS
558559

@@ -895,7 +896,8 @@ struct block_eval {
895896

896897
/* loop context */
897898
struct block_loop {
898-
LOOP *my_op; /* My op, that contains redo, next and last ops. */
899+
LOOP *my_op; /* My op, that contains redo,
900+
next and last ops. */
899901
union { /* different ways of locating the iteration variable */
900902
SV **svp; /* for lexicals: address of pad slot */
901903
GV *gv; /* for package vars */
@@ -920,7 +922,8 @@ struct block_loop {
920922
} lazysv;
921923
} state_u;
922924
#ifdef USE_ITHREADS
923-
PAD *oldcomppad; /* needed to map itervar_u.svp during thread clone */
925+
PAD *oldcomppad; /* needed to map itervar_u.svp
926+
during thread clone */
924927
#endif
925928
};
926929

@@ -1175,28 +1178,31 @@ struct context {
11751178

11761179
/* extra flags for Perl_call_* routines */
11771180
#define G_DISCARD 0x4 /* Call FREETMPS. Don't change this
1178-
without consulting the hash
1179-
actions codes defined in hv.h */
1180-
#define G_EVAL 0x8 /* Assume eval {} around subroutine call. */
1181+
without consulting the hash
1182+
actions codes defined in hv.h */
1183+
#define G_EVAL 0x8 /* Assume eval {} around
1184+
subroutine call. */
11811185
#define G_NOARGS 0x10 /* Don't construct a @_ array. */
11821186
#define G_KEEPERR 0x20 /* Warn for errors, don't overwrite $@ */
11831187
#define G_NODEBUG 0x40 /* Disable debugging at toplevel. */
11841188
#define G_METHOD 0x80 /* Calling method. */
11851189
#define G_FAKINGEVAL 0x100 /* Faking an eval context for call_sv
1186-
or fold_constants. */
1190+
or fold_constants. */
11871191
#define G_UNDEF_FILL 0x200 /* Fill the stack with &PL_sv_undef
1188-
A special case for UNSHIFT in
1189-
Perl_magic_methcall(). */
1192+
A special case for UNSHIFT in
1193+
Perl_magic_methcall(). */
11901194
#define G_WRITING_TO_STDERR 0x400 /* Perl_write_to_stderr() is calling
1191-
Perl_magic_methcall(). */
1195+
Perl_magic_methcall(). */
11921196
#define G_RE_REPARSING 0x800 /* compiling a run-time /(?{..})/ */
1193-
#define G_METHOD_NAMED 0x1000 /* calling named method, eg without :: or ' */
1197+
#define G_METHOD_NAMED 0x1000 /* calling named method, eg
1198+
without :: or ' */
11941199
#define G_RETHROW 0x2000 /* eval_sv(): re-throw any error */
11951200

11961201
/* flag bits for PL_in_eval */
11971202
#define EVAL_NULL 0 /* not in an eval */
11981203
#define EVAL_INEVAL 1 /* some enclosing scope is an eval */
1199-
#define EVAL_WARNONLY 2 /* used by yywarn() when calling yyerror() */
1204+
#define EVAL_WARNONLY 2 /* used by yywarn() when
1205+
calling yyerror() */
12001206
#define EVAL_KEEPERR 4 /* set by Perl_call_sv if G_KEEPERR */
12011207
#define EVAL_INREQUIRE 8 /* The code is being required. */
12021208
#define EVAL_RE_REPARSING 0x10 /* eval_sv() called with G_RE_REPARSING */
@@ -1237,7 +1243,7 @@ struct stackinfo {
12371243
* #ifdef-ed for bincompat */
12381244
#if defined DEBUGGING && !defined DEBUGGING_RE_ONLY
12391245
/* high water mark: for checking if the stack was correctly
1240-
* extended / tested for extension by each pp function */
1246+
* extended / tested for extension by each pp function */
12411247
SSize_t si_stack_hwm;
12421248
#endif
12431249

cv.h

+10-7
Original file line numberDiff line numberDiff line change
@@ -118,30 +118,33 @@ L<perlguts/Autoloading with XSUBs>.
118118
* but is renamed to avoid collision with an upcoming feature */
119119
#define CVf_NOWARN_AMBIGUOUS 0x0001
120120

121-
#define CVf_LVALUE 0x0002 /* CV return value can be used as lvalue */
121+
#define CVf_LVALUE 0x0002 /* CV return value can be
122+
used as lvalue */
122123
#define CVf_CONST 0x0004 /* inlinable sub */
123124
#define CVf_ISXSUB 0x0008 /* CV is an XSUB, not pure perl. */
124125

125126
#define CVf_WEAKOUTSIDE 0x0010 /* CvOUTSIDE isn't ref counted */
126127
#define CVf_CLONE 0x0020 /* anon CV uses external lexicals */
127128
#define CVf_CLONED 0x0040 /* a clone of one of those */
128129
#define CVf_ANON 0x0080 /* CV is not pointed to by a GV */
129-
#define CVf_UNIQUE 0x0100 /* sub is only called once (eg PL_main_cv,
130-
require, eval). */
131-
#define CVf_NODEBUG 0x0200 /* no DB::sub indirection for this CV (esp.
132-
useful for special XSUBs) */
130+
#define CVf_UNIQUE 0x0100 /* sub is only called once (eg
131+
PL_main_cv, require, eval). */
132+
#define CVf_NODEBUG 0x0200 /* no DB::sub indirection for this CV
133+
(esp. useful for special XSUBs) */
133134
#define CVf_CVGV_RC 0x0400 /* CvGV is reference counted */
134135
#if defined(PERL_CORE) || defined(PERL_EXT)
135136
# define CVf_SLABBED 0x0800 /* Holds refcount on op slab */
136137
#endif
137138
#define CVf_DYNFILE 0x1000 /* The filename is malloced */
138-
#define CVf_AUTOLOAD 0x2000 /* SvPVX contains AUTOLOADed sub name */
139+
#define CVf_AUTOLOAD 0x2000 /* SvPVX contains AUTOLOADed
140+
sub name */
139141
#define CVf_HASEVAL 0x4000 /* contains string eval */
140142
#define CVf_NAMED 0x8000 /* Has a name HEK */
141143
#define CVf_LEXICAL 0x10000 /* Omit package from name */
142144
#define CVf_ANONCONST 0x20000 /* :const - create anonconst op */
143145
#define CVf_SIGNATURE 0x40000 /* CV uses a signature */
144-
#define CVf_REFCOUNTED_ANYSV 0x80000 /* CvXSUBANY().any_sv is refcounted */
146+
#define CVf_REFCOUNTED_ANYSV 0x80000 /* CvXSUBANY().any_sv
147+
is refcounted */
145148

146149
/* This symbol for optimised communication between toke.c and op.c: */
147150
#define CVf_BUILTIN_ATTRS (CVf_NOWARN_AMBIGUOUS|CVf_LVALUE|CVf_ANONCONST)

dosish.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
# define PERL_SYS_INIT_BODY(c,v) \
2323
MALLOC_CHECK_TAINT2(*c,*v); PERLIO_INIT
2424
# define BIT_BUCKET "\\dev\\nul" /* "wanna be like, umm, Newlined,
25-
or somethin?" */
25+
or somethin?" */
2626
#endif
2727

2828
/* Generally add things last-in first-terminated. IO and memory

form.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@
1313
#define FF_SKIP 3 /* skip <arg> chars in format */
1414
#define FF_FETCH 4 /* get next item and set field size to <arg> */
1515
#define FF_CHECKNL 5 /* find max len of item (up to
16-
\n) that fits field */
16+
\n) that fits field */
1717
#define FF_CHECKCHOP 6 /* like CHECKNL, but up to highest split point */
1818
#define FF_SPACE 7 /* append padding space (diff
19-
of field, item size) */
19+
of field, item size) */
2020
#define FF_HALFSPACE 8 /* like FF_SPACE, but only append half as many */
2121
#define FF_ITEM 9 /* append a text item, while blanking ctrl chars */
2222
#define FF_CHOP 10 /* (for ^*) chop the current item */

gv.h

+7-5
Original file line numberDiff line numberDiff line change
@@ -232,9 +232,11 @@ Return the CV from the GV.
232232
time, so don't try to free what's there. */
233233
#define GV_ADDMULTI 0x02 /* add, pretending it has been added already;
234234
used also by gv_init_* */
235-
#define GV_ADDWARN 0x04 /* add, but warn if symbol wasn't already there */
236-
/* 0x08 UNUSED */
237-
#define GV_NOINIT 0x10 /* add, but don't init symbol, if type != PVGV */
235+
#define GV_ADDWARN 0x04 /* add, but warn if symbol wasn't
236+
already there */
237+
/* 0x08 UNUSED */
238+
#define GV_NOINIT 0x10 /* add, but don't init symbol,
239+
if type != PVGV */
238240
/* This is used by toke.c to avoid turing placeholder constants in the symbol
239241
table into full PVGVs with attached constant subroutines. */
240242
#define GV_NOADD_NOINIT 0x20 /* Don't add the symbol if it's not there.
@@ -258,8 +260,8 @@ Return the CV from the GV.
258260
/* Flags for gv_autoload_ */
259261
#define GV_AUTOLOAD_ISMETHOD 1 /* autoloading a method? */
260262

261-
/* SVf_UTF8 (more accurately the return value from SvUTF8) is also valid as
262-
a flag to various gv_* functions, so ensure it lies outside this range.
263+
/* SVf_UTF8 (more accurately the return value from SvUTF8) is also valid as
264+
a flag to various gv_* functions, so ensure it lies outside this range.
263265
*/
264266

265267
#define GV_NOADD_MASK \

handy.h

+6-4
Original file line numberDiff line numberDiff line change
@@ -1649,7 +1649,7 @@ END_EXTERN_C
16491649
# define isSPACE_A(c) generic_isCC_A_(c, CC_SPACE_)
16501650
# define isWORDCHAR_A(c) generic_isCC_A_(c, CC_WORDCHAR_)
16511651
# define isXDIGIT_A(c) generic_isCC_(c, CC_XDIGIT_) /* No non-ASCII
1652-
xdigits */
1652+
xdigits */
16531653
# define isIDFIRST_A(c) generic_isCC_A_(c, CC_IDFIRST_)
16541654
# define isALPHA_L1(c) generic_isCC_(c, CC_ALPHA_)
16551655
# define isALPHANUMERIC_L1(c) generic_isCC_(c, CC_ALPHANUMERIC_)
@@ -1896,7 +1896,8 @@ END_EXTERN_C
18961896
((! FITS_IN_8_BITS(c)) \
18971897
? (c) \
18981898
: PL_latin1_lc[ (U8) (c) ])
1899-
#define toLOWER_L1(c) toLOWER_LATIN1(c) /* Synonym for consistency */
1899+
#define toLOWER_L1(c) toLOWER_LATIN1(c) /* Synonym for
1900+
consistency */
19001901

19011902
/* Modified uc. Is correct uc except for three non-ascii chars
19021903
* which are all mapped to one of them, and these need special
@@ -2176,7 +2177,8 @@ END_EXTERN_C
21762177
#define isALPHANUMERIC_uvchr(c) generic_invlist_uvchr_(CC_ALPHANUMERIC_, c)
21772178
#define isASCII_uvchr(c) isASCII(c)
21782179
#define isBLANK_uvchr(c) generic_uvchr_(CC_BLANK_, is_HORIZWS_cp_high, c)
2179-
#define isCNTRL_uvchr(c) isCNTRL_L1(c) /* All controls are in Latin1 */
2180+
#define isCNTRL_uvchr(c) isCNTRL_L1(c) /* All controls are
2181+
in Latin1 */
21802182
#define isDIGIT_uvchr(c) generic_invlist_uvchr_(CC_DIGIT_, c)
21812183
#define isGRAPH_uvchr(c) generic_invlist_uvchr_(CC_GRAPH_, c)
21822184
#define isIDCONT_uvchr(c) \
@@ -2524,7 +2526,7 @@ END_EXTERN_C
25242526
#define isALNUM_LC_utf8(p,e) isWORDCHAR_LC_utf8(p,e)
25252527
#define isALNUM_LC_utf8_safe(p,e) isWORDCHAR_LC_utf8_safe(p,e)
25262528
#define isALNUMC_A(c) isALPHANUMERIC_A(c) /* Mnemonic: "C's
2527-
alnum" */
2529+
alnum" */
25282530
#define isALNUMC_L1(c) isALPHANUMERIC_L1(c)
25292531
#define isALNUMC(c) isALPHANUMERIC(c)
25302532
#define isALNUMC_LC(c) isALPHANUMERIC_LC(c)

0 commit comments

Comments
 (0)