p |int |magic_setarylen|SV* sv|MAGIC* mg
p |int |magic_setbm |SV* sv|MAGIC* mg
p |int |magic_setdbline|SV* sv|MAGIC* mg
-#if defined(USE_LOCALE_COLLATE)
-p |int |magic_setcollxfrm|SV* sv|MAGIC* mg
-#endif
p |int |magic_setdefelem|SV* sv|MAGIC* mg
p |int |magic_setenv |SV* sv|MAGIC* mg
p |int |magic_setfm |SV* sv|MAGIC* mg
p |void |magicname |const char* sym|const char* name|I32 namlen
Ap |void |markstack_grow
#if defined(USE_LOCALE_COLLATE)
+p |int |magic_setcollxfrm|SV* sv|MAGIC* mg
p |char* |mem_collxfrm |const char* s|STRLEN len|STRLEN* xlen
#endif
Afp |SV* |mess |const char* pat|...
ApdR |char* |sv_reftype |NN const SV* sv|int ob
Apd |void |sv_replace |NN SV* sv|NN SV* nsv
Apd |void |sv_report_used
-Apd |void |sv_reset |const char* s|HV* stash
+Apd |void |sv_reset |NN const char* s|HV* stash
Afpd |void |sv_setpvf |SV* sv|const char* pat|...
Apd |void |sv_vsetpvf |SV* sv|const char* pat|va_list* args
Apd |void |sv_setiv |SV* sv|IV num
-Apdb |void |sv_setpviv |SV* sv|IV num
+Apdb |void |sv_setpviv |NN SV* sv|IV num
Apd |void |sv_setuv |SV* sv|UV num
Apd |void |sv_setnv |SV* sv|NV num
Apd |SV* |sv_setref_iv |SV* rv|const char* classname|IV iv
Afpd |void |sv_setpvf_mg |SV *sv|const char* pat|...
Apd |void |sv_vsetpvf_mg |SV* sv|const char* pat|va_list* args
Apd |void |sv_setiv_mg |SV *sv|IV i
-Apdb |void |sv_setpviv_mg |SV *sv|IV iv
+Apdb |void |sv_setpviv_mg |NN SV *sv|IV iv
Apd |void |sv_setuv_mg |SV *sv|UV u
Apd |void |sv_setnv_mg |SV *sv|NV num
Apd |void |sv_setpv_mg |SV *sv|const char *ptr
Ap |MAGIC* |mg_dup |MAGIC* mg|CLONE_PARAMS* param
Ap |SV* |sv_dup |SV* sstr|CLONE_PARAMS* param
Ap |void |rvpv_dup |SV* dstr|SV *sstr|CLONE_PARAMS* param
-#if defined(HAVE_INTERP_INTERN)
-Ap |void |sys_intern_dup |struct interp_intern* src \
- |struct interp_intern* dst
-#endif
Ap |PTR_TBL_t*|ptr_table_new
Ap |void* |ptr_table_fetch|NN PTR_TBL_t *tbl|NN void *sv
Ap |void |ptr_table_store|NN PTR_TBL_t *tbl|void *oldsv|void *newsv
Ap |void |ptr_table_split|NN PTR_TBL_t *tbl
Ap |void |ptr_table_clear|PTR_TBL_t *tbl
Ap |void |ptr_table_free|PTR_TBL_t *tbl
-#endif
-#if defined(HAVE_INTERP_INTERN)
+# if defined(HAVE_INTERP_INTERN)
+Ap |void |sys_intern_dup |NN struct interp_intern* src|NN struct interp_intern* dst
Ap |void |sys_intern_clear
Ap |void |sys_intern_init
+# endif
#endif
Ap |char * |custom_op_name |NN const OP* op
#endif
#if defined(PERL_IN_MG_C) || defined(PERL_DECL_PROT)
-s |void |save_magic |I32 mgs_ix|SV *sv
-s |int |magic_methpack |SV *sv|const MAGIC *mg|const char *meth
-s |int |magic_methcall |SV *sv|const MAGIC *mg|const char *meth|I32 f \
+s |void |save_magic |I32 mgs_ix|NN SV *sv
+s |int |magic_methpack |NN SV *sv|NN const MAGIC *mg|NN const char *meth
+s |int |magic_methcall |NN SV *sv|NN const MAGIC *mg|NN const char *meth|I32 f \
|int n|SV *val
#endif
#if defined(PERL_IN_OP_C) || defined(PERL_DECL_PROT)
-s |I32 |list_assignment|const OP *o
-s |void |bad_type |I32 n|const char *t|const char *name|const OP *kid
-s |void |cop_free |COP *cop
+ApR |OP* |ck_anoncode |NN OP *o
+ApR |OP* |ck_bitop |NN OP *o
+ApR |OP* |ck_concat |NN OP *o
+ApR |OP* |ck_defined |NN OP *o
+ApR |OP* |ck_delete |NN OP *o
+ApR |OP* |ck_die |NN OP *o
+ApR |OP* |ck_eof |NN OP *o
+ApR |OP* |ck_eval |NN OP *o
+ApR |OP* |ck_exec |NN OP *o
+ApR |OP* |ck_exists |NN OP *o
+ApR |OP* |ck_exit |NN OP *o
+ApR |OP* |ck_ftst |NN OP *o
+ApR |OP* |ck_fun |NN OP *o
+ApR |OP* |ck_glob |NN OP *o
+ApR |OP* |ck_grep |NN OP *o
+ApR |OP* |ck_index |NN OP *o
+ApR |OP* |ck_join |NN OP *o
+ApR |OP* |ck_lengthconst |NN OP *o
+ApR |OP* |ck_lfun |NN OP *o
+ApR |OP* |ck_listiob |NN OP *o
+ApR |OP* |ck_match |NN OP *o
+ApR |OP* |ck_method |NN OP *o
+ApR |OP* |ck_null |NN OP *o
+ApR |OP* |ck_open |NN OP *o
+ApR |OP* |ck_repeat |NN OP *o
+ApR |OP* |ck_require |NN OP *o
+ApR |OP* |ck_retarget |NN OP *o
+ApR |OP* |ck_return |NN OP *o
+ApR |OP* |ck_rfun |NN OP *o
+ApR |OP* |ck_rvconst |NN OP *o
+ApR |OP* |ck_sassign |NN OP *o
+ApR |OP* |ck_select |NN OP *o
+ApR |OP* |ck_shift |NN OP *o
+ApR |OP* |ck_sort |NN OP *o
+ApR |OP* |ck_spair |NN OP *o
+ApR |OP* |ck_split |NN OP *o
+ApR |OP* |ck_subr |NN OP *o
+ApR |OP* |ck_substr |NN OP *o
+ApR |OP* |ck_svconst |NN OP *o
+ApR |OP* |ck_trunc |NN OP *o
+ApR |OP* |ck_unpack |NN OP *o
+sR |bool |is_handle_constructor|NN const OP *o|I32 numargs
+sR |I32 |is_list_assignment|const OP *o
+s |void |cop_free |NN COP *cop
s |OP* |modkids |OP *o|I32 type
-s |void |no_bareword_allowed|const OP *o
-s |OP* |no_fh_allowed |OP *o
-s |OP* |scalarboolean |OP *o
-s |OP* |too_few_arguments|OP *o|const char* name
-s |OP* |too_many_arguments|OP *o|const char* name
-s |OP* |newDEFSVOP
-s |OP* |new_logop |I32 type|I32 flags|OP **firstp|OP **otherp
-s |void |simplify_sort |OP *o
-s |bool |is_handle_constructor |const OP *o|I32 argnum
+s |OP* |scalarboolean |NN OP *o
+sR |OP* |newDEFSVOP
+sR |OP* |new_logop |I32 type|I32 flags|NN OP **firstp|NN OP **otherp
+s |void |simplify_sort |NN OP *o
s |char* |gv_ename |GV *gv
s |bool |scalar_mod_type|const OP *o|I32 type
s |OP * |my_kid |OP *o|OP *attrs|OP **imopsp
s |OP * |dup_attrlist |OP *o
s |void |apply_attrs |HV *stash|SV *target|OP *attrs|bool for_my
s |void |apply_attrs_my |HV *stash|OP *target|OP *attrs|OP **imopsp
+s |void |bad_type |I32 n|NN const char *t|NN const char *name|NN const OP *kid
+s |void |no_bareword_allowed|NN const OP *o
+sR |OP* |no_fh_allowed|NN OP *o
+sR |OP* |too_few_arguments|NN OP *o|NN const char* name
+sR |OP* |too_many_arguments|NN OP *o|NN const char* name
#endif
#if defined(PL_OP_SLAB_ALLOC)
-Ap |void* |Slab_Alloc |int m|size_t sz
+ApR |void* |Slab_Alloc |int m|size_t sz
Ap |void |Slab_Free |void *op
#endif
Es |void |reginsert |struct RExC_state_t*|U8|regnode *
Es |void |regoptail |struct RExC_state_t*|regnode *|regnode *
Es |void |regtail |struct RExC_state_t*|regnode *|regnode *
-Es |char*|regwhite |char *|char *
-Es |char*|nextchar |struct RExC_state_t*
+Es |char* |regwhite |char *p|const char *e
+Es |char* |nextchar |struct RExC_state_t*
# ifdef DEBUGGING
Es |regnode*|dumpuntil |regnode *start|regnode *node \
|regnode *last|SV* sv|I32 l
-Es |void |put_byte |SV* sv|int c
+Es |void |put_byte |NN SV* sv|int c
# endif
Es |void |scan_commit |struct RExC_state_t*|struct scan_data_t *data
Es |void |cl_anything |struct RExC_state_t*|struct regnode_charclass_class *cl
#define magic_setarylen Perl_magic_setarylen
#define magic_setbm Perl_magic_setbm
#define magic_setdbline Perl_magic_setdbline
-#endif
-#if defined(USE_LOCALE_COLLATE)
-#ifdef PERL_CORE
-#define magic_setcollxfrm Perl_magic_setcollxfrm
-#endif
-#endif
-#ifdef PERL_CORE
#define magic_setdefelem Perl_magic_setdefelem
#define magic_setenv Perl_magic_setenv
#define magic_setfm Perl_magic_setfm
#define markstack_grow Perl_markstack_grow
#if defined(USE_LOCALE_COLLATE)
#ifdef PERL_CORE
+#define magic_setcollxfrm Perl_magic_setcollxfrm
#define mem_collxfrm Perl_mem_collxfrm
#endif
#endif
#define mg_dup Perl_mg_dup
#define sv_dup Perl_sv_dup
#define rvpv_dup Perl_rvpv_dup
-#if defined(HAVE_INTERP_INTERN)
-#define sys_intern_dup Perl_sys_intern_dup
-#endif
#define ptr_table_new Perl_ptr_table_new
#define ptr_table_fetch Perl_ptr_table_fetch
#define ptr_table_store Perl_ptr_table_store
#define ptr_table_split Perl_ptr_table_split
#define ptr_table_clear Perl_ptr_table_clear
#define ptr_table_free Perl_ptr_table_free
-#endif
-#if defined(HAVE_INTERP_INTERN)
+# if defined(HAVE_INTERP_INTERN)
+#define sys_intern_dup Perl_sys_intern_dup
#define sys_intern_clear Perl_sys_intern_clear
#define sys_intern_init Perl_sys_intern_init
+# endif
#endif
#define custom_op_name Perl_custom_op_name
#define custom_op_desc Perl_custom_op_desc
#endif
#endif
#if defined(PERL_IN_OP_C) || defined(PERL_DECL_PROT)
+#define ck_anoncode Perl_ck_anoncode
+#define ck_bitop Perl_ck_bitop
+#define ck_concat Perl_ck_concat
+#define ck_defined Perl_ck_defined
+#define ck_delete Perl_ck_delete
+#define ck_die Perl_ck_die
+#define ck_eof Perl_ck_eof
+#define ck_eval Perl_ck_eval
+#define ck_exec Perl_ck_exec
+#define ck_exists Perl_ck_exists
+#define ck_exit Perl_ck_exit
+#define ck_ftst Perl_ck_ftst
+#define ck_fun Perl_ck_fun
+#define ck_glob Perl_ck_glob
+#define ck_grep Perl_ck_grep
+#define ck_index Perl_ck_index
+#define ck_join Perl_ck_join
+#define ck_lengthconst Perl_ck_lengthconst
+#define ck_lfun Perl_ck_lfun
+#define ck_listiob Perl_ck_listiob
+#define ck_match Perl_ck_match
+#define ck_method Perl_ck_method
+#define ck_null Perl_ck_null
+#define ck_open Perl_ck_open
+#define ck_repeat Perl_ck_repeat
+#define ck_require Perl_ck_require
+#define ck_retarget Perl_ck_retarget
+#define ck_return Perl_ck_return
+#define ck_rfun Perl_ck_rfun
+#define ck_rvconst Perl_ck_rvconst
+#define ck_sassign Perl_ck_sassign
+#define ck_select Perl_ck_select
+#define ck_shift Perl_ck_shift
+#define ck_sort Perl_ck_sort
+#define ck_spair Perl_ck_spair
+#define ck_split Perl_ck_split
+#define ck_subr Perl_ck_subr
+#define ck_substr Perl_ck_substr
+#define ck_svconst Perl_ck_svconst
+#define ck_trunc Perl_ck_trunc
+#define ck_unpack Perl_ck_unpack
#ifdef PERL_CORE
-#define list_assignment S_list_assignment
-#define bad_type S_bad_type
+#define is_handle_constructor S_is_handle_constructor
+#define is_list_assignment S_is_list_assignment
#define cop_free S_cop_free
#define modkids S_modkids
-#define no_bareword_allowed S_no_bareword_allowed
-#define no_fh_allowed S_no_fh_allowed
#define scalarboolean S_scalarboolean
-#define too_few_arguments S_too_few_arguments
-#define too_many_arguments S_too_many_arguments
#define newDEFSVOP S_newDEFSVOP
#define new_logop S_new_logop
#define simplify_sort S_simplify_sort
-#define is_handle_constructor S_is_handle_constructor
#define gv_ename S_gv_ename
#define scalar_mod_type S_scalar_mod_type
#define my_kid S_my_kid
#define dup_attrlist S_dup_attrlist
#define apply_attrs S_apply_attrs
#define apply_attrs_my S_apply_attrs_my
+#define bad_type S_bad_type
+#define no_bareword_allowed S_no_bareword_allowed
+#define no_fh_allowed S_no_fh_allowed
+#define too_few_arguments S_too_few_arguments
+#define too_many_arguments S_too_many_arguments
#endif
#endif
#if defined(PL_OP_SLAB_ALLOC)
#define magic_setarylen(a,b) Perl_magic_setarylen(aTHX_ a,b)
#define magic_setbm(a,b) Perl_magic_setbm(aTHX_ a,b)
#define magic_setdbline(a,b) Perl_magic_setdbline(aTHX_ a,b)
-#endif
-#if defined(USE_LOCALE_COLLATE)
-#ifdef PERL_CORE
-#define magic_setcollxfrm(a,b) Perl_magic_setcollxfrm(aTHX_ a,b)
-#endif
-#endif
-#ifdef PERL_CORE
#define magic_setdefelem(a,b) Perl_magic_setdefelem(aTHX_ a,b)
#define magic_setenv(a,b) Perl_magic_setenv(aTHX_ a,b)
#define magic_setfm(a,b) Perl_magic_setfm(aTHX_ a,b)
#define markstack_grow() Perl_markstack_grow(aTHX)
#if defined(USE_LOCALE_COLLATE)
#ifdef PERL_CORE
+#define magic_setcollxfrm(a,b) Perl_magic_setcollxfrm(aTHX_ a,b)
#define mem_collxfrm(a,b,c) Perl_mem_collxfrm(aTHX_ a,b,c)
#endif
#endif
#define mg_dup(a,b) Perl_mg_dup(aTHX_ a,b)
#define sv_dup(a,b) Perl_sv_dup(aTHX_ a,b)
#define rvpv_dup(a,b,c) Perl_rvpv_dup(aTHX_ a,b,c)
-#if defined(HAVE_INTERP_INTERN)
-#define sys_intern_dup(a,b) Perl_sys_intern_dup(aTHX_ a,b)
-#endif
#define ptr_table_new() Perl_ptr_table_new(aTHX)
#define ptr_table_fetch(a,b) Perl_ptr_table_fetch(aTHX_ a,b)
#define ptr_table_store(a,b,c) Perl_ptr_table_store(aTHX_ a,b,c)
#define ptr_table_split(a) Perl_ptr_table_split(aTHX_ a)
#define ptr_table_clear(a) Perl_ptr_table_clear(aTHX_ a)
#define ptr_table_free(a) Perl_ptr_table_free(aTHX_ a)
-#endif
-#if defined(HAVE_INTERP_INTERN)
+# if defined(HAVE_INTERP_INTERN)
+#define sys_intern_dup(a,b) Perl_sys_intern_dup(aTHX_ a,b)
#define sys_intern_clear() Perl_sys_intern_clear(aTHX)
#define sys_intern_init() Perl_sys_intern_init(aTHX)
+# endif
#endif
#define custom_op_name(a) Perl_custom_op_name(aTHX_ a)
#define custom_op_desc(a) Perl_custom_op_desc(aTHX_ a)
#endif
#endif
#if defined(PERL_IN_OP_C) || defined(PERL_DECL_PROT)
+#define ck_anoncode(a) Perl_ck_anoncode(aTHX_ a)
+#define ck_bitop(a) Perl_ck_bitop(aTHX_ a)
+#define ck_concat(a) Perl_ck_concat(aTHX_ a)
+#define ck_defined(a) Perl_ck_defined(aTHX_ a)
+#define ck_delete(a) Perl_ck_delete(aTHX_ a)
+#define ck_die(a) Perl_ck_die(aTHX_ a)
+#define ck_eof(a) Perl_ck_eof(aTHX_ a)
+#define ck_eval(a) Perl_ck_eval(aTHX_ a)
+#define ck_exec(a) Perl_ck_exec(aTHX_ a)
+#define ck_exists(a) Perl_ck_exists(aTHX_ a)
+#define ck_exit(a) Perl_ck_exit(aTHX_ a)
+#define ck_ftst(a) Perl_ck_ftst(aTHX_ a)
+#define ck_fun(a) Perl_ck_fun(aTHX_ a)
+#define ck_glob(a) Perl_ck_glob(aTHX_ a)
+#define ck_grep(a) Perl_ck_grep(aTHX_ a)
+#define ck_index(a) Perl_ck_index(aTHX_ a)
+#define ck_join(a) Perl_ck_join(aTHX_ a)
+#define ck_lengthconst(a) Perl_ck_lengthconst(aTHX_ a)
+#define ck_lfun(a) Perl_ck_lfun(aTHX_ a)
+#define ck_listiob(a) Perl_ck_listiob(aTHX_ a)
+#define ck_match(a) Perl_ck_match(aTHX_ a)
+#define ck_method(a) Perl_ck_method(aTHX_ a)
+#define ck_null(a) Perl_ck_null(aTHX_ a)
+#define ck_open(a) Perl_ck_open(aTHX_ a)
+#define ck_repeat(a) Perl_ck_repeat(aTHX_ a)
+#define ck_require(a) Perl_ck_require(aTHX_ a)
+#define ck_retarget(a) Perl_ck_retarget(aTHX_ a)
+#define ck_return(a) Perl_ck_return(aTHX_ a)
+#define ck_rfun(a) Perl_ck_rfun(aTHX_ a)
+#define ck_rvconst(a) Perl_ck_rvconst(aTHX_ a)
+#define ck_sassign(a) Perl_ck_sassign(aTHX_ a)
+#define ck_select(a) Perl_ck_select(aTHX_ a)
+#define ck_shift(a) Perl_ck_shift(aTHX_ a)
+#define ck_sort(a) Perl_ck_sort(aTHX_ a)
+#define ck_spair(a) Perl_ck_spair(aTHX_ a)
+#define ck_split(a) Perl_ck_split(aTHX_ a)
+#define ck_subr(a) Perl_ck_subr(aTHX_ a)
+#define ck_substr(a) Perl_ck_substr(aTHX_ a)
+#define ck_svconst(a) Perl_ck_svconst(aTHX_ a)
+#define ck_trunc(a) Perl_ck_trunc(aTHX_ a)
+#define ck_unpack(a) Perl_ck_unpack(aTHX_ a)
#ifdef PERL_CORE
-#define list_assignment(a) S_list_assignment(aTHX_ a)
-#define bad_type(a,b,c,d) S_bad_type(aTHX_ a,b,c,d)
+#define is_handle_constructor(a,b) S_is_handle_constructor(aTHX_ a,b)
+#define is_list_assignment(a) S_is_list_assignment(aTHX_ a)
#define cop_free(a) S_cop_free(aTHX_ a)
#define modkids(a,b) S_modkids(aTHX_ a,b)
-#define no_bareword_allowed(a) S_no_bareword_allowed(aTHX_ a)
-#define no_fh_allowed(a) S_no_fh_allowed(aTHX_ a)
#define scalarboolean(a) S_scalarboolean(aTHX_ a)
-#define too_few_arguments(a,b) S_too_few_arguments(aTHX_ a,b)
-#define too_many_arguments(a,b) S_too_many_arguments(aTHX_ a,b)
#define newDEFSVOP() S_newDEFSVOP(aTHX)
#define new_logop(a,b,c,d) S_new_logop(aTHX_ a,b,c,d)
#define simplify_sort(a) S_simplify_sort(aTHX_ a)
-#define is_handle_constructor(a,b) S_is_handle_constructor(aTHX_ a,b)
#define gv_ename(a) S_gv_ename(aTHX_ a)
#define scalar_mod_type(a,b) S_scalar_mod_type(aTHX_ a,b)
#define my_kid(a,b,c) S_my_kid(aTHX_ a,b,c)
#define dup_attrlist(a) S_dup_attrlist(aTHX_ a)
#define apply_attrs(a,b,c,d) S_apply_attrs(aTHX_ a,b,c,d)
#define apply_attrs_my(a,b,c,d) S_apply_attrs_my(aTHX_ a,b,c,d)
+#define bad_type(a,b,c,d) S_bad_type(aTHX_ a,b,c,d)
+#define no_bareword_allowed(a) S_no_bareword_allowed(aTHX_ a)
+#define no_fh_allowed(a) S_no_fh_allowed(aTHX_ a)
+#define too_few_arguments(a,b) S_too_few_arguments(aTHX_ a,b)
+#define too_many_arguments(a,b) S_too_many_arguments(aTHX_ a,b)
#endif
#endif
#if defined(PL_OP_SLAB_ALLOC)
Perl_mg_dup
Perl_sv_dup
Perl_rvpv_dup
-Perl_sys_intern_dup
Perl_ptr_table_new
Perl_ptr_table_fetch
Perl_ptr_table_store
Perl_ptr_table_split
Perl_ptr_table_clear
Perl_ptr_table_free
+Perl_sys_intern_dup
Perl_sys_intern_clear
Perl_sys_intern_init
Perl_custom_op_name
Perl_sv_nolocking
Perl_sv_nounlocking
Perl_nothreadhook
+Perl_ck_anoncode
+Perl_ck_bitop
+Perl_ck_concat
+Perl_ck_defined
+Perl_ck_delete
+Perl_ck_die
+Perl_ck_eof
+Perl_ck_eval
+Perl_ck_exec
+Perl_ck_exists
+Perl_ck_exit
+Perl_ck_ftst
+Perl_ck_fun
+Perl_ck_glob
+Perl_ck_grep
+Perl_ck_index
+Perl_ck_join
+Perl_ck_lengthconst
+Perl_ck_lfun
+Perl_ck_listiob
+Perl_ck_match
+Perl_ck_method
+Perl_ck_null
+Perl_ck_open
+Perl_ck_repeat
+Perl_ck_require
+Perl_ck_retarget
+Perl_ck_return
+Perl_ck_rfun
+Perl_ck_rvconst
+Perl_ck_sassign
+Perl_ck_select
+Perl_ck_shift
+Perl_ck_sort
+Perl_ck_spair
+Perl_ck_split
+Perl_ck_subr
+Perl_ck_substr
+Perl_ck_svconst
+Perl_ck_trunc
+Perl_ck_unpack
Perl_Slab_Alloc
Perl_Slab_Free
Perl_sv_setsv_flags
}
STATIC bool
-S_is_handle_constructor(pTHX_ const OP *o, I32 argnum)
+S_is_handle_constructor(pTHX_ const OP *o, I32 numargs)
{
switch (o->op_type) {
case OP_PIPE_OP:
case OP_SOCKPAIR:
- if (argnum == 2)
+ if (numargs == 2)
return TRUE;
/* FALL THROUGH */
case OP_SYSOPEN:
case OP_SOCKET:
case OP_OPEN_DIR:
case OP_ACCEPT:
- if (argnum == 1)
+ if (numargs == 1)
return TRUE;
/* FALL THROUGH */
default:
#define ATTRSMODULE_PM "attributes.pm"
if (for_my) {
- SV **svp;
/* Don't force the C<use> if we don't need it. */
- svp = hv_fetch(GvHVn(PL_incgv), ATTRSMODULE_PM,
+ SV **svp = hv_fetch(GvHVn(PL_incgv), ATTRSMODULE_PM,
sizeof(ATTRSMODULE_PM)-1, 0);
if (svp && *svp != &PL_sv_undef)
; /* already in %INC */
}
STATIC I32
-S_list_assignment(pTHX_ register const OP *o)
+S_is_list_assignment(pTHX_ register const OP *o)
{
if (!o)
return TRUE;
o = cUNOPo->op_first;
if (o->op_type == OP_COND_EXPR) {
- const I32 t = list_assignment(cLOGOPo->op_first->op_sibling);
- const I32 f = list_assignment(cLOGOPo->op_first->op_sibling->op_sibling);
+ const I32 t = is_list_assignment(cLOGOPo->op_first->op_sibling);
+ const I32 f = is_list_assignment(cLOGOPo->op_first->op_sibling->op_sibling);
if (t && f)
return TRUE;
}
}
- if (list_assignment(left)) {
+ if (is_list_assignment(left)) {
OP *curop;
PL_modcount = 0;
return o;
}
-#if 0
-OP *
-Perl_ck_gvconst(pTHX_ register OP *o)
-{
- o = fold_constants(o);
- if (o->op_type == OP_CONST)
- o->op_type = OP_GV;
- return o;
-}
-#endif
-
OP *
Perl_ck_rvconst(pTHX_ register OP *o)
{
if (kid->op_type == OP_CONST) {
int iscv;
GV *gv;
- SV *kidsv = kid->op_sv;
+ SV * const kidsv = kid->op_sv;
/* Is it a constant from cv_const_sv()? */
if (SvROK(kidsv) && SvREADONLY(kidsv)) {
SV *rsv = SvRV(kidsv);
- int svtype = SvTYPE(rsv);
+ const int svtype = SvTYPE(rsv);
const char *badtype = Nullch;
switch (o->op_type) {
AV *comppad = (AV*)AvARRAY(padlist)[1];
SV **curpad = AvARRAY(comppad);
for (ix = AvFILLp(comppad_name); ix > 0; ix--) {
- SV *namesv = namepad[ix];
+ SV * const namesv = namepad[ix];
if (namesv && namesv != &PL_sv_undef
&& *SvPVX_const(namesv) == '&')
{
PADOFFSET
Perl_pad_add_name(pTHX_ const char *name, HV* typestash, HV* ourstash, bool fake)
{
- PADOFFSET offset = pad_alloc(OP_PADSV, SVs_PADMY);
+ const PADOFFSET offset = pad_alloc(OP_PADSV, SVs_PADMY);
SV* namesv = NEWSV(1102, 0);
ASSERT_CURPAD_ACTIVE("pad_add_name");
Perl_pad_tidy(pTHX_ padtidy_type type)
{
dVAR;
- PADOFFSET ix;
ASSERT_CURPAD_ACTIVE("pad_tidy");
if (type == padtidy_SUBCLONE) {
SV **namep = AvARRAY(PL_comppad_name);
+ PADOFFSET ix;
for (ix = AvFILLp(PL_comppad); ix > 0; ix--) {
SV *namesv;
/* XXX DAPM rationalise these two similar branches */
if (type == padtidy_SUB) {
+ PADOFFSET ix;
for (ix = AvFILLp(PL_comppad); ix > 0; ix--) {
if (SvIMMORTAL(PL_curpad[ix]) || IS_PADGV(PL_curpad[ix]) || IS_PADCONST(PL_curpad[ix]))
continue;
}
}
else if (type == padtidy_FORMAT) {
+ PADOFFSET ix;
for (ix = AvFILLp(PL_comppad); ix > 0; ix--) {
if (!SvPADMY(PL_curpad[ix]) && !SvIMMORTAL(PL_curpad[ix]))
SvPADTMP_on(PL_curpad[ix]);
return win32_fdupopen(f);
#else
if (f) {
- int fd = PerlLIO_dup(PerlIO_fileno(f));
+ const int fd = PerlLIO_dup(PerlIO_fileno(f));
if (fd >= 0) {
char mode[8];
int omode = fcntl(fd, F_GETFL);
SAVEINT(PL_in_load_module);
if (cv) {
SAVEGENERICSV(PL_warnhook);
- SvREFCNT_inc(cv);
+ (void)SvREFCNT_inc(cv);
PL_warnhook = (SV *) cv;
}
PL_in_load_module++;
sv_catpvn(err, prefix, sizeof(prefix)-1);
sv_catpvn(err, message, msglen);
if (ckWARN(WARN_MISC)) {
- STRLEN start = SvCUR(err)-msglen-sizeof(prefix)+1;
+ const STRLEN start = SvCUR(err)-msglen-sizeof(prefix)+1;
Perl_warner(aTHX_ packWARN(WARN_MISC), SvPVX_const(err)+start);
}
}
STATIC void
S_save_lines(pTHX_ AV *array, SV *sv)
{
- register const char *s = SvPVX_const(sv);
- register const char *send = SvPVX_const(sv) + SvCUR(sv);
- register I32 line = 1;
+ const char *s = SvPVX_const(sv);
+ const char *send = SvPVX_const(sv) + SvCUR(sv);
+ I32 line = 1;
while (s && s < send) {
const char *t;
LEAVE;
if (optype == OP_REQUIRE) {
const char* msg = SvPVx(ERRSV, n_a);
- SV *nsv = cx->blk_eval.old_namesv;
- (void)hv_store(GvHVn(PL_incgv), SvPVX_const(nsv), SvCUR(nsv),
+ SV *nsv = cx->blk_eval.old_namesv;
+ (void)hv_store(GvHVn(PL_incgv), SvPVX_const(nsv), SvCUR(nsv),
&PL_sv_undef, 0);
DIE(aTHX_ "%sCompilation failed in require",
*msg ? msg : "Unknown error\n");
{
dVAR;
SV *datasv = FILTER_DATA(idx);
- int filter_has_file = IoLINES(datasv);
+ const int filter_has_file = IoLINES(datasv);
GV *filter_child_proc = (GV *)IoFMT_GV(datasv);
SV *filter_state = (SV *)IoTOP_GV(datasv);
SV *filter_sub = (SV *)IoBOTTOM_GV(datasv);
if (hasargs)
{
AV* av;
- SV** ary;
-
#if 0
DEBUG_S(PerlIO_printf(Perl_debug_log,
"%p entersub preparing @_\n", thr));
++MARK;
if (items > AvMAX(av) + 1) {
- ary = AvALLOC(av);
+ SV **ary = AvALLOC(av);
if (AvARRAY(av) != ary) {
AvMAX(av) += AvARRAY(av) - AvALLOC(av);
SvPV_set(av, (char*)ary);
}
if (IoFLAGS(io) & IOf_DIDTOP) { /* Oh dear. It still doesn't fit. */
I32 lines = IoLINES_LEFT(io);
- const char *s = SvPVX(PL_formtarget);
+ const char *s = SvPVX_const(PL_formtarget);
if (lines <= 0) /* Yow, header didn't even fit!!! */
goto forget_top;
while (lines-- > 0) {
PERL_CALLCONV int Perl_magic_setarylen(pTHX_ SV* sv, MAGIC* mg);
PERL_CALLCONV int Perl_magic_setbm(pTHX_ SV* sv, MAGIC* mg);
PERL_CALLCONV int Perl_magic_setdbline(pTHX_ SV* sv, MAGIC* mg);
-#if defined(USE_LOCALE_COLLATE)
-PERL_CALLCONV int Perl_magic_setcollxfrm(pTHX_ SV* sv, MAGIC* mg);
-#endif
PERL_CALLCONV int Perl_magic_setdefelem(pTHX_ SV* sv, MAGIC* mg);
PERL_CALLCONV int Perl_magic_setenv(pTHX_ SV* sv, MAGIC* mg);
PERL_CALLCONV int Perl_magic_setfm(pTHX_ SV* sv, MAGIC* mg);
PERL_CALLCONV void Perl_magicname(pTHX_ const char* sym, const char* name, I32 namlen);
PERL_CALLCONV void Perl_markstack_grow(pTHX);
#if defined(USE_LOCALE_COLLATE)
+PERL_CALLCONV int Perl_magic_setcollxfrm(pTHX_ SV* sv, MAGIC* mg);
PERL_CALLCONV char* Perl_mem_collxfrm(pTHX_ const char* s, STRLEN len, STRLEN* xlen);
#endif
PERL_CALLCONV SV* Perl_mess(pTHX_ const char* pat, ...)
__attribute__nonnull__(pTHX_2);
PERL_CALLCONV void Perl_sv_report_used(pTHX);
-PERL_CALLCONV void Perl_sv_reset(pTHX_ const char* s, HV* stash);
+PERL_CALLCONV void Perl_sv_reset(pTHX_ const char* s, HV* stash)
+ __attribute__nonnull__(pTHX_1);
+
PERL_CALLCONV void Perl_sv_setpvf(pTHX_ SV* sv, const char* pat, ...)
__attribute__format__(__printf__,pTHX_2,pTHX_3);
PERL_CALLCONV void Perl_sv_vsetpvf(pTHX_ SV* sv, const char* pat, va_list* args);
PERL_CALLCONV void Perl_sv_setiv(pTHX_ SV* sv, IV num);
-PERL_CALLCONV void Perl_sv_setpviv(pTHX_ SV* sv, IV num);
+PERL_CALLCONV void Perl_sv_setpviv(pTHX_ SV* sv, IV num)
+ __attribute__nonnull__(pTHX_1);
+
PERL_CALLCONV void Perl_sv_setuv(pTHX_ SV* sv, UV num);
PERL_CALLCONV void Perl_sv_setnv(pTHX_ SV* sv, NV num);
PERL_CALLCONV SV* Perl_sv_setref_iv(pTHX_ SV* rv, const char* classname, IV iv);
PERL_CALLCONV void Perl_sv_vsetpvf_mg(pTHX_ SV* sv, const char* pat, va_list* args);
PERL_CALLCONV void Perl_sv_setiv_mg(pTHX_ SV *sv, IV i);
-PERL_CALLCONV void Perl_sv_setpviv_mg(pTHX_ SV *sv, IV iv);
+PERL_CALLCONV void Perl_sv_setpviv_mg(pTHX_ SV *sv, IV iv)
+ __attribute__nonnull__(pTHX_1);
+
PERL_CALLCONV void Perl_sv_setuv_mg(pTHX_ SV *sv, UV u);
PERL_CALLCONV void Perl_sv_setnv_mg(pTHX_ SV *sv, NV num);
PERL_CALLCONV void Perl_sv_setpv_mg(pTHX_ SV *sv, const char *ptr);
PERL_CALLCONV MAGIC* Perl_mg_dup(pTHX_ MAGIC* mg, CLONE_PARAMS* param);
PERL_CALLCONV SV* Perl_sv_dup(pTHX_ SV* sstr, CLONE_PARAMS* param);
PERL_CALLCONV void Perl_rvpv_dup(pTHX_ SV* dstr, SV *sstr, CLONE_PARAMS* param);
-#if defined(HAVE_INTERP_INTERN)
-PERL_CALLCONV void Perl_sys_intern_dup(pTHX_ struct interp_intern* src, struct interp_intern* dst);
-#endif
PERL_CALLCONV PTR_TBL_t* Perl_ptr_table_new(pTHX);
PERL_CALLCONV void* Perl_ptr_table_fetch(pTHX_ PTR_TBL_t *tbl, void *sv)
__attribute__nonnull__(pTHX_1)
PERL_CALLCONV void Perl_ptr_table_clear(pTHX_ PTR_TBL_t *tbl);
PERL_CALLCONV void Perl_ptr_table_free(pTHX_ PTR_TBL_t *tbl);
-#endif
-#if defined(HAVE_INTERP_INTERN)
+# if defined(HAVE_INTERP_INTERN)
+PERL_CALLCONV void Perl_sys_intern_dup(pTHX_ struct interp_intern* src, struct interp_intern* dst)
+ __attribute__nonnull__(pTHX_1)
+ __attribute__nonnull__(pTHX_2);
+
PERL_CALLCONV void Perl_sys_intern_clear(pTHX);
PERL_CALLCONV void Perl_sys_intern_init(pTHX);
+# endif
#endif
PERL_CALLCONV char * Perl_custom_op_name(pTHX_ const OP* op)
#endif
#if defined(PERL_IN_MG_C) || defined(PERL_DECL_PROT)
-STATIC void S_save_magic(pTHX_ I32 mgs_ix, SV *sv);
-STATIC int S_magic_methpack(pTHX_ SV *sv, const MAGIC *mg, const char *meth);
-STATIC int S_magic_methcall(pTHX_ SV *sv, const MAGIC *mg, const char *meth, I32 f, int n, SV *val);
+STATIC void S_save_magic(pTHX_ I32 mgs_ix, SV *sv)
+ __attribute__nonnull__(pTHX_2);
+
+STATIC int S_magic_methpack(pTHX_ SV *sv, const MAGIC *mg, const char *meth)
+ __attribute__nonnull__(pTHX_1)
+ __attribute__nonnull__(pTHX_2)
+ __attribute__nonnull__(pTHX_3);
+
+STATIC int S_magic_methcall(pTHX_ SV *sv, const MAGIC *mg, const char *meth, I32 f, int n, SV *val)
+ __attribute__nonnull__(pTHX_1)
+ __attribute__nonnull__(pTHX_2)
+ __attribute__nonnull__(pTHX_3);
+
#endif
#if defined(PERL_IN_OP_C) || defined(PERL_DECL_PROT)
-STATIC I32 S_list_assignment(pTHX_ const OP *o);
-STATIC void S_bad_type(pTHX_ I32 n, const char *t, const char *name, const OP *kid);
-STATIC void S_cop_free(pTHX_ COP *cop);
+PERL_CALLCONV OP* Perl_ck_anoncode(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_bitop(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_concat(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_defined(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_delete(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_die(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_eof(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_eval(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_exec(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_exists(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_exit(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_ftst(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_fun(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_glob(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_grep(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_index(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_join(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_lengthconst(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_lfun(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_listiob(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_match(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_method(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_null(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_open(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_repeat(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_require(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_retarget(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_return(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_rfun(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_rvconst(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_sassign(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_select(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_shift(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_sort(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_spair(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_split(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_subr(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_substr(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_svconst(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_trunc(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+PERL_CALLCONV OP* Perl_ck_unpack(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+STATIC bool S_is_handle_constructor(pTHX_ const OP *o, I32 numargs)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+STATIC I32 S_is_list_assignment(pTHX_ const OP *o)
+ __attribute__warn_unused_result__;
+
+STATIC void S_cop_free(pTHX_ COP *cop)
+ __attribute__nonnull__(pTHX_1);
+
STATIC OP* S_modkids(pTHX_ OP *o, I32 type);
-STATIC void S_no_bareword_allowed(pTHX_ const OP *o);
-STATIC OP* S_no_fh_allowed(pTHX_ OP *o);
-STATIC OP* S_scalarboolean(pTHX_ OP *o);
-STATIC OP* S_too_few_arguments(pTHX_ OP *o, const char* name);
-STATIC OP* S_too_many_arguments(pTHX_ OP *o, const char* name);
-STATIC OP* S_newDEFSVOP(pTHX);
-STATIC OP* S_new_logop(pTHX_ I32 type, I32 flags, OP **firstp, OP **otherp);
-STATIC void S_simplify_sort(pTHX_ OP *o);
-STATIC bool S_is_handle_constructor(pTHX_ const OP *o, I32 argnum);
+STATIC OP* S_scalarboolean(pTHX_ OP *o)
+ __attribute__nonnull__(pTHX_1);
+
+STATIC OP* S_newDEFSVOP(pTHX)
+ __attribute__warn_unused_result__;
+
+STATIC OP* S_new_logop(pTHX_ I32 type, I32 flags, OP **firstp, OP **otherp)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_3)
+ __attribute__nonnull__(pTHX_4);
+
+STATIC void S_simplify_sort(pTHX_ OP *o)
+ __attribute__nonnull__(pTHX_1);
+
STATIC char* S_gv_ename(pTHX_ GV *gv);
STATIC bool S_scalar_mod_type(pTHX_ const OP *o, I32 type);
STATIC OP * S_my_kid(pTHX_ OP *o, OP *attrs, OP **imopsp);
STATIC OP * S_dup_attrlist(pTHX_ OP *o);
STATIC void S_apply_attrs(pTHX_ HV *stash, SV *target, OP *attrs, bool for_my);
STATIC void S_apply_attrs_my(pTHX_ HV *stash, OP *target, OP *attrs, OP **imopsp);
+STATIC void S_bad_type(pTHX_ I32 n, const char *t, const char *name, const OP *kid)
+ __attribute__nonnull__(pTHX_2)
+ __attribute__nonnull__(pTHX_3)
+ __attribute__nonnull__(pTHX_4);
+
+STATIC void S_no_bareword_allowed(pTHX_ const OP *o)
+ __attribute__nonnull__(pTHX_1);
+
+STATIC OP* S_no_fh_allowed(pTHX_ OP *o)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1);
+
+STATIC OP* S_too_few_arguments(pTHX_ OP *o, const char* name)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1)
+ __attribute__nonnull__(pTHX_2);
+
+STATIC OP* S_too_many_arguments(pTHX_ OP *o, const char* name)
+ __attribute__warn_unused_result__
+ __attribute__nonnull__(pTHX_1)
+ __attribute__nonnull__(pTHX_2);
+
#endif
#if defined(PL_OP_SLAB_ALLOC)
-PERL_CALLCONV void* Perl_Slab_Alloc(pTHX_ int m, size_t sz);
+PERL_CALLCONV void* Perl_Slab_Alloc(pTHX_ int m, size_t sz)
+ __attribute__warn_unused_result__;
+
PERL_CALLCONV void Perl_Slab_Free(pTHX_ void *op);
#endif
STATIC void S_reginsert(pTHX_ struct RExC_state_t*, U8, regnode *);
STATIC void S_regoptail(pTHX_ struct RExC_state_t*, regnode *, regnode *);
STATIC void S_regtail(pTHX_ struct RExC_state_t*, regnode *, regnode *);
-STATIC char* S_regwhite(pTHX_ char *, char *);
+STATIC char* S_regwhite(pTHX_ char *p, const char *e);
STATIC char* S_nextchar(pTHX_ struct RExC_state_t*);
# ifdef DEBUGGING
STATIC regnode* S_dumpuntil(pTHX_ regnode *start, regnode *node, regnode *last, SV* sv, I32 l);
-STATIC void S_put_byte(pTHX_ SV* sv, int c);
+STATIC void S_put_byte(pTHX_ SV* sv, int c)
+ __attribute__nonnull__(pTHX_1);
+
# endif
STATIC void S_scan_commit(pTHX_ struct RExC_state_t*, struct scan_data_t *data);
STATIC void S_cl_anything(pTHX_ struct RExC_state_t*, struct regnode_charclass_class *cl);
}
STATIC char *
-S_regwhite(pTHX_ char *p, char *e)
+S_regwhite(pTHX_ char *p, const char *e)
{
while (p < e) {
if (isSPACE(*p))
STATIC regnode * /* Location. */
S_reg_node(pTHX_ RExC_state_t *pRExC_state, U8 op)
{
- register regnode *ret;
register regnode *ptr;
+ regnode * const ret = RExC_emit;
- ret = RExC_emit;
if (SIZE_ONLY) {
SIZE_ALIGN(RExC_size);
RExC_size += 1;
STATIC regnode * /* Location. */
S_reganode(pTHX_ RExC_state_t *pRExC_state, U8 op, U32 arg)
{
- register regnode *ret;
register regnode *ptr;
+ regnode * const ret = RExC_emit;
- ret = RExC_emit;
if (SIZE_ONLY) {
SIZE_ALIGN(RExC_size);
RExC_size += 2;
register regnode *src;
register regnode *dst;
register regnode *place;
- register int offset = regarglen[(U8)op];
+ const int offset = regarglen[(U8)op];
/* (PL_regkind[(U8)op] == CURLY ? EXTRA_STEP_2ARGS : 0); */
S_regtail(pTHX_ RExC_state_t *pRExC_state, regnode *p, regnode *val)
{
register regnode *scan;
- register regnode *temp;
if (SIZE_ONLY)
return;
/* Find last node. */
scan = p;
for (;;) {
- temp = regnext(scan);
+ regnode * const temp = regnext(scan);
if (temp == NULL)
break;
scan = temp;
}
else if (SvPOKp(sv) && SvLEN(sv)) {
UV value;
- const int numtype = grok_number(SvPVX(sv), SvCUR(sv), &value);
+ const int numtype = grok_number(SvPVX_const(sv), SvCUR(sv), &value);
/* We want to avoid a possible problem when we cache an IV which
may be later translated to an NV, and the resulting NV is not
the same as the direct translation of the initial string
}
else if (SvPOKp(sv) && SvLEN(sv)) {
UV value;
- const int numtype = grok_number(SvPVX(sv), SvCUR(sv), &value);
+ const int numtype = grok_number(SvPVX_const(sv), SvCUR(sv), &value);
/* We want to avoid a possible problem when we cache a UV which
may be later translated to an NV, and the resulting NV is not
return SvNVX(sv);
if (SvPOKp(sv) && SvLEN(sv)) {
if (ckWARN(WARN_NUMERIC) && !SvIOKp(sv) &&
- !grok_number(SvPVX(sv), SvCUR(sv), NULL))
+ !grok_number(SvPVX_const(sv), SvCUR(sv), NULL))
not_a_number(sv);
return Atof(SvPVX(sv));
}
S_asUV(pTHX_ SV *sv)
{
UV value;
- int numtype = grok_number(SvPVX(sv), SvCUR(sv), &value);
+ const int numtype = grok_number(SvPVX_const(sv), SvCUR(sv), &value);
if ((numtype & (IS_NUMBER_IN_UV | IS_NUMBER_NOT_INT))
== IS_NUMBER_IN_UV) {
/* Got to punt this as an integer if needs be, but we don't issue
warnings. Probably ought to make the sv_iv_please() that does
the conversion if possible, and silently. */
- int numtype = grok_number(SvPVX(sv), SvCUR(sv), NULL);
+ const int numtype = grok_number(SvPVX_const(sv), SvCUR(sv), NULL);
if (numtype && !(numtype & IS_NUMBER_INFINITY)) {
/* Need to try really hard to see if it's an integer.
9.22337203685478e+18 is an integer.
}
#ifdef PERL_PRESERVE_IVUV
{
- int numtype = grok_number(SvPVX(sv), SvCUR(sv), NULL);
+ const int numtype = grok_number(SvPVX_const(sv), SvCUR(sv), NULL);
if (numtype && !(numtype & IS_NUMBER_INFINITY)) {
/* Need to try really hard to see if it's an integer.
9.22337203685478e+18 is an integer.
STRLEN len;
const char *start = SvPVx(sv,len);
const char *end = start + len;
- bool utf = SvUTF8(sv) ? TRUE : FALSE;
+ const bool utf = SvUTF8(sv) ? TRUE : FALSE;
while (start < end) {
STRLEN skip;
UV n;
}
if (warning) {
- char *s = SvPVX(sv);
+ const char *s = SvPVX_const(sv);
if (PL_op)
Perl_warner(aTHX_ packWARN(WARN_UTF8),