This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Revert "Use new Svt_INVLIST for inversion lists."
[perl5.git] / embed.fnc
index c9832d4..5441ff5 100644 (file)
--- a/embed.fnc
+++ b/embed.fnc
@@ -39,7 +39,7 @@
 :
 :         proto.h: add __attribute__deprecated__
 :
-:   d  Function has documentation in the source:
+:   d  Function has documentation (somewhere) in the source:
 :
 :         enables 'no docs for foo" warning in autodoc.pl
 :
@@ -265,6 +265,7 @@ Anprd       |void   |croak_no_modify
 Anprd  |void   |croak_xs_usage |NN const CV *const cv \
                                |NN const char *const params
 npr    |void   |croak_no_mem
+nroX   |void   |Perl_croak_memory_wrap
 nprX   |void   |croak_popstack
 #if defined(WIN32)
 norx   |void   |win32_croak_not_implemented|NN const char * fname
@@ -426,6 +427,7 @@ p   |void   |dump_sub_perl  |NN const GV* gv|bool justperl
 Apd    |void   |fbm_compile    |NN SV* sv|U32 flags
 ApdR   |char*  |fbm_instr      |NN unsigned char* big|NN unsigned char* bigend \
                                |NN SV* littlestr|U32 flags
+p      |CV *   |find_lexical_cv|PADOFFSET off
 : Defined in util.c, used only in perl.c
 p      |char*  |find_script    |NN const char *scriptname|bool dosearch \
                                |NULLOK const char *const *const search_ext|I32 flags
@@ -529,7 +531,7 @@ Ap  |void*  |hv_common      |NULLOK HV *hv|NULLOK SV *keysv \
 Ap     |void*  |hv_common_key_len|NULLOK HV *hv|NN const char *key \
                                |I32 klen_i32|const int action|NULLOK SV *val \
                                |const U32 hash
-Apod   |STRLEN |hv_fill        |NN HV const *const hv
+Apod   |STRLEN |hv_fill        |NN HV *const hv
 Ap     |void   |hv_free_ent    |NN HV *hv|NULLOK HE *entry
 Apd    |I32    |hv_iterinit    |NN HV *hv
 ApdR   |char*  |hv_iterkey     |NN HE* entry|NN I32* retlen
@@ -632,7 +634,7 @@ iDMPR       |bool   |isALNUM_lazy   |NN const char* p
 sR     |U8     |to_lower_latin1|const U8 c|NULLOK U8 *p|NULLOK STRLEN *lenp
 #endif
 #if defined(PERL_IN_UTF8_C) || defined(PERL_IN_REGCOMP_C) || defined(PERL_IN_REGEXEC_C)
-EXp        |UV        |_to_fold_latin1|const U8 c|NN U8 *p|NN STRLEN *lenp|const bool flags
+EXp        |UV        |_to_fold_latin1|const U8 c|NN U8 *p|NN STRLEN *lenp|const unsigned int flags
 #endif
 #if defined(PERL_IN_UTF8_C) || defined(PERL_IN_PP_C)
 p      |UV     |_to_upper_title_latin1|const U8 c|NN U8 *p|NN STRLEN *lenp|const char S_or_s
@@ -817,7 +819,7 @@ p   |int    |magic_set_all_env|NN SV* sv|NN MAGIC* mg
 p      |U32    |magic_sizepack |NN SV* sv|NN MAGIC* mg
 p      |int    |magic_wipepack |NN SV* sv|NN MAGIC* mg
 pod    |SV*    |magic_methcall |NN SV *sv|NN const MAGIC *mg \
-                               |NN const char *meth|U32 flags \
+                               |NN SV *meth|U32 flags \
                                |U32 argc|...
 Ap     |void   |markstack_grow
 #if defined(USE_LOCALE_COLLATE)
@@ -887,11 +889,6 @@ Ap |void   |my_setenv      |NULLOK const char* nam|NULLOK const char* val
 Apmb   |I32    |my_stat
 pX     |I32    |my_stat_flags  |NULLOK const U32 flags
 Ap     |char * |my_strftime    |NN const char *fmt|int sec|int min|int hour|int mday|int mon|int year|int wday|int yday|int isdst
-#if defined(MYSWAP)
-ApPR   |short  |my_swap        |short s
-ApPR   |long   |my_htonl       |long l
-ApPR   |long   |my_ntohl       |long l
-#endif
 : Used in pp_ctl.c
 p      |void   |my_unexec
 Apa    |OP*    |newANONLIST    |NULLOK OP* o
@@ -1087,8 +1084,8 @@ Ap        |SV*    |regclass_swash |NULLOK const regexp *prog \
                                |NN const struct regnode *node|bool doinit \
                                |NULLOK SV **listsvp|NULLOK SV **altsvp
 #ifdef PERL_IN_REGCOMP_C
-EMsR   |SV*    |_new_invlist_C_array|NN UV* list
-: Not used currently: EXMs     |bool   |_invlistEQ     |NN SV* const a|NN SV* const b|bool complement_b
+EMsR   |SV*    |_new_invlist_C_array|NN const UV* const list
+: Not used currently: EXMs     |bool   |_invlistEQ     |NN SV* const a|NN SV* const b|const bool complement_b
 #endif
 Ap     |I32    |pregexec       |NN REGEXP * const prog|NN char* stringarg \
                                |NN char* strend|NN char* strbeg|I32 minend \
@@ -1106,12 +1103,16 @@ Ap      |REGEXP*|pregcomp       |NN SV * const pattern|const U32 flags
 p      |REGEXP*|re_op_compile  |NULLOK SV ** const patternp \
                                |int pat_count|NULLOK OP *expr \
                                |NN const regexp_engine* eng \
-                               |NULLOK REGEXP *VOL old_re \
+                               |NULLOK REGEXP *old_re \
                                |NULLOK bool *is_bare_re \
                                |U32 rx_flags|U32 pm_flags
 Ap     |REGEXP*|re_compile     |NN SV * const pattern|U32 orig_rx_flags
-Ap     |char*  |re_intuit_start|NN REGEXP * const rx|NULLOK SV* sv|NN char* strpos \
-                               |NN char* strend|const U32 flags \
+Ap     |char*  |re_intuit_start|NN REGEXP * const rx \
+                               |NULLOK SV* sv \
+                               |NN const char* const strbeg \
+                               |NN char* strpos \
+                               |NN char* strend \
+                               |const U32 flags \
                                |NULLOK re_scream_pos_data *data
 Ap     |SV*    |re_intuit_string|NN REGEXP  *const r
 #if defined(PERL_IN_REGCOMP_C) || defined(PERL_IN_TOKE_C)
@@ -1427,7 +1428,7 @@ EsM       |void   |_append_range_to_invlist   |NN SV* const invlist|const UV start|const
 EiMR   |UV*    |_invlist_array_init    |NN SV* const invlist|const bool will_have_0
 EiMR   |UV*    |invlist_array  |NN SV* const invlist
 EsM    |void   |invlist_extend    |NN SV* const invlist|const UV len
-EiMR   |UV*    |get_invlist_zero_addr  |NN SV* invlist
+EiMR   |U8*    |get_invlist_offset_addr|NN SV* invlist
 EiMR   |UV     |invlist_max    |NN SV* const invlist
 EiM    |void   |invlist_set_len|NN SV* const invlist|const UV len
 EiMR   |IV*    |get_invlist_previous_index_addr|NN SV* invlist
@@ -1436,8 +1437,7 @@ EiM       |void   |invlist_set_previous_index|NN SV* const invlist|const IV index
 EiM    |void   |invlist_trim   |NN SV* const invlist
 EiMR   |SV*    |invlist_clone  |NN SV* const invlist
 EiMR   |bool   |invlist_is_iterating|NN SV* const invlist
-EiMR   |UV*    |get_invlist_iter_addr  |NN SV* invlist
-EiMR   |UV*    |get_invlist_version_id_addr    |NN SV* invlist
+EiMR   |STRLEN*|get_invlist_iter_addr  |NN SV* invlist
 EiM    |void   |invlist_iterinit|NN SV* invlist
 EsMR   |bool   |invlist_iternext|NN SV* invlist|NN UV* start|NN UV* end
 EiM    |void   |invlist_iterfinish|NN SV* invlist
@@ -1445,9 +1445,13 @@ EiMR     |UV     |invlist_highest|NN SV* const invlist
 #endif
 #if defined(PERL_IN_REGCOMP_C) || defined(PERL_IN_UTF8_C)
 EXmM   |void   |_invlist_intersection  |NN SV* const a|NN SV* const b|NN SV** i
-EXpM   |void   |_invlist_intersection_maybe_complement_2nd|NULLOK SV* const a|NN SV* const b|bool complement_b|NN SV** i
+EXpM   |void   |_invlist_intersection_maybe_complement_2nd \
+               |NULLOK SV* const a|NN SV* const b          \
+               |const bool complement_b|NN SV** i
 EXmM   |void   |_invlist_union |NULLOK SV* const a|NN SV* const b|NN SV** output
-EXpM   |void   |_invlist_union_maybe_complement_2nd|NULLOK SV* const a|NN SV* const b|bool complement_b|NN SV** output
+EXpM   |void   |_invlist_union_maybe_complement_2nd        \
+               |NULLOK SV* const a|NN SV* const b          \
+               |const bool complement_b|NN SV** output
 EXmM   |void   |_invlist_subtract|NN SV* const a|NN SV* const b|NN SV** result
 EXpM   |void   |_invlist_invert|NN SV* const invlist
 EXpM   |void   |_invlist_invert_prop|NN SV* const invlist
@@ -1463,7 +1467,7 @@ EXp       |SV*    |_core_swash_init|NN const char* pkg|NN const char* name \
 #endif
 #if defined(PERL_IN_REGCOMP_C) || defined(PERL_IN_REGEXEC_C) || defined(PERL_IN_UTF8_C)
 EXMpR  |SV*    |_invlist_contents|NN SV* const invlist
-EiMR   |UV*    |_get_invlist_len_addr  |NN SV* invlist
+EiMR   |STRLEN*|_get_invlist_len_addr  |NN SV* invlist
 EiMR   |UV     |_invlist_len   |NN SV* const invlist
 EMiR   |bool   |_invlist_contains_cp|NN SV* const invlist|const UV cp
 EXpMR  |IV     |_invlist_search        |NN SV* const invlist|const UV cp
@@ -1555,7 +1559,7 @@ p |I32    |wait4pid       |Pid_t pid|NN int* statusp|int flags
 p      |U32    |parse_unicode_opts|NN const char **popt
 Ap     |U32    |seed
 : Only used in perl.c
-p        |void        |get_hash_seed        |NN unsigned char *seed_buffer
+p        |void        |get_hash_seed        |NN unsigned char * const seed_buffer
 : Used in doio.c, pp_hot.c, pp_sys.c
 p      |void   |report_evil_fh |NULLOK const GV *gv
 : Used in doio.c, pp_hot.c, pp_sys.c
@@ -1608,7 +1612,6 @@ Anpa      |Malloc_t|safesysmalloc |MEM_SIZE nbytes
 Anpa   |Malloc_t|safesyscalloc |MEM_SIZE elements|MEM_SIZE size
 Anpa   |Malloc_t|safesysrealloc|Malloc_t where|MEM_SIZE nbytes
 Anp    |Free_t |safesysfree    |Malloc_t where
-Asrnx  |void   |croak_memory_wrap
 #if defined(PERL_GLOBAL_STRUCT)
 Ap     |struct perl_vars *|GetVars
 Ap     |struct perl_vars*|init_global_struct
@@ -1721,14 +1724,12 @@ Ap      |void   |ptr_table_store|NN PTR_TBL_t *const tbl|NULLOK const void *const oldsv
 Ap     |void   |ptr_table_split|NN PTR_TBL_t *const tbl
 ApD    |void   |ptr_table_clear|NULLOK PTR_TBL_t *const tbl
 Ap     |void   |ptr_table_free|NULLOK PTR_TBL_t *const tbl
-#if defined(USE_ITHREADS)
-#  if defined(HAVE_INTERP_INTERN)
-Ap     |void   |sys_intern_dup |NN struct interp_intern* src|NN struct interp_intern* dst
-#  endif
-#endif
 #if defined(HAVE_INTERP_INTERN)
 Ap     |void   |sys_intern_clear
 Ap     |void   |sys_intern_init
+#  if defined(USE_ITHREADS)
+Ap     |void   |sys_intern_dup |NN struct interp_intern* src|NN struct interp_intern* dst
+#  endif
 #endif
 
 AopP   |const XOP *    |custom_op_xop  |NN const OP *o
@@ -1778,7 +1779,8 @@ sn        |void   |hv_magic_check |NN HV *hv|NN bool *needs_copy|NN bool *needs_store
 s      |void   |unshare_hek_or_pvn|NULLOK const HEK* hek|NULLOK const char* str|I32 len|U32 hash
 sR     |HEK*   |share_hek_flags|NN const char *str|I32 len|U32 hash|int flags
 rs     |void   |hv_notallowed  |int flags|NN const char *key|I32 klen|NN const char *msg
-sn     |struct xpvhv_aux*|hv_auxinit|NN HV *hv
+in     |U32|ptr_hash|PTRV u
+s      |struct xpvhv_aux*|hv_auxinit|NN HV *hv
 sM     |SV*    |hv_delete_common|NULLOK HV *hv|NULLOK SV *keysv \
                |NULLOK const char *key|STRLEN klen|int k_flags|I32 d_flags \
                |U32 hash
@@ -1787,9 +1789,9 @@ sM        |void   |clear_placeholders     |NN HV *hv|U32 items
 
 #if defined(PERL_IN_MG_C)
 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_methpack |NN SV *sv|NN const MAGIC *mg|NN SV *meth
 s      |SV*    |magic_methcall1|NN SV *sv|NN const MAGIC *mg \
-                               |NN const char *meth|U32 flags \
+                               |NN SV *meth|U32 flags \
                                |int n|NULLOK SV *val
 s      |void   |restore_magic  |NULLOK const void *p
 s      |void   |unwind_handler_stack|NULLOK const void *p
@@ -1815,7 +1817,7 @@ s |OP *   |dup_attrlist   |NN OP *o
 s      |void   |apply_attrs    |NN HV *stash|NN SV *target|NULLOK OP *attrs
 s      |void   |apply_attrs_my |NN HV *stash|NN OP *target|NULLOK OP *attrs|NN OP **imopsp
 s      |void   |bad_type_pv    |I32 n|NN const char *t|NN const char *name|U32 flags|NN const OP *kid
-s      |void   |bad_type_sv    |I32 n|NN const char *t|NN SV *namesv|U32 flags|NN const OP *kid
+s      |void   |bad_type_gv    |I32 n|NN const char *t|NN GV *gv|U32 flags|NN const OP *kid
 s      |void   |no_bareword_allowed|NN OP *o
 sR     |OP*    |no_fh_allowed|NN OP *o
 sR     |OP*    |too_few_arguments_sv|NN OP *o|NN SV* namesv|U32 flags
@@ -1901,7 +1903,8 @@ sR        |const char *|get_num   |NN const char *patptr|NN I32 *lenptr
 ns     |bool   |need_utf8      |NN const char *pat|NN const char *patend
 ns     |char   |first_symbol   |NN const char *pat|NN const char *patend
 sR     |char * |sv_exp_grow    |NN SV *sv|STRLEN needed
-snR    |char * |bytes_to_uni   |NN const U8 *start|STRLEN len|NN char *dest
+snR    |char * |bytes_to_uni   |NN const U8 *start|STRLEN len|NN char *dest \
+                               |const bool needs_swap
 #endif
 
 #if defined(PERL_IN_PP_CTL_C)
@@ -1924,7 +1927,7 @@ sR        |PerlIO *|check_type_and_open|NN SV *name
 sR     |PerlIO *|doopen_pm     |NN SV *name
 #endif
 s      |SV **  |adjust_stack_on_leave|NN SV **newsp|NN SV **sp|NN SV **mark|I32 gimme|U32 flags
-sRn    |bool   |path_is_absolute|NN const char *name
+iRn    |bool   |path_is_searchable|NN const char *name
 sR     |I32    |run_user_filter|int idx|NN SV *buf_sv|int maxlen
 sR     |PMOP*  |make_matcher   |NN REGEXP* re
 sR     |bool   |matcher_matches_sv|NN PMOP* matcher|NN SV* sv
@@ -1958,7 +1961,7 @@ sR        |int    |dooneliner     |NN const char *cmd|NN const char *filename
 #  endif
 s      |SV *   |space_join_names_mortal|NN char *const *array
 #endif
-p      |OP *   |tied_method|NN const char *const methname|NN SV **sp \
+p      |OP *   |tied_method|NN SV *methname|NN SV **sp \
                                |NN SV *const sv|NN const MAGIC *const mg \
                                |const U32 flags|U32 argc|...
 
@@ -2036,7 +2039,7 @@ EsRn      |U32    |add_data       |NN struct RExC_state_t *pRExC_state|U32 n \
                                |NN const char *s
 rs     |void   |re_croak2      |NN const char* pat1|NN const char* pat2|...
 Ei     |I32    |regpposixcc    |NN struct RExC_state_t *pRExC_state \
-                               |I32 value|NULLOK SV *free_me|const bool strict
+                               |I32 value|const bool strict
 Es     |I32    |make_trie      |NN struct RExC_state_t *pRExC_state \
                                |NN regnode *startbranch|NN regnode *first \
                                |NN regnode *last|NN regnode *tail \
@@ -2045,6 +2048,7 @@ Es        |void   |make_trie_failtable    |NN struct RExC_state_t *pRExC_state \
                                 |NN regnode *source|NN regnode *stclass \
                                |U32 depth
 #  ifdef DEBUGGING
+Es        |void        |regdump_intflags|NULLOK const char *lead| const U32 flags
 Es     |void   |regdump_extflags|NULLOK const char *lead| const U32 flags
 Es     |const regnode*|dumpuntil|NN const regexp *r|NN const regnode *start \
                                |NN const regnode *node \
@@ -2071,8 +2075,10 @@ ERs      |bool   |isFOO_lc       |const U8 classnum|const U8 character
 ERs    |bool   |isFOO_utf8_lc  |const U8 classnum|NN const U8* character
 ERs    |I32    |regmatch       |NN regmatch_info *reginfo|NN char *startpos|NN regnode *prog
 ERs    |I32    |regrepeat      |NN regexp *prog|NN char **startposp \
-                               |NN const regnode *p|I32 max|int depth \
-                               |bool is_utf8_pat
+                               |NN const regnode *p \
+                               |NN regmatch_info *const reginfo \
+                               |I32 max \
+                               |int depth
 ERs    |I32    |regtry         |NN regmatch_info *reginfo|NN char **startposp
 ERs    |bool   |reginclass     |NULLOK regexp * const prog|NN const regnode * const n|NN const U8 * const p\
                                |bool const utf8_target
@@ -2091,8 +2097,7 @@ ERsn      |U8*    |reghop4        |NN U8 *s|I32 off|NN const U8 *llim \
 ERsn   |U8*    |reghopmaybe3   |NN U8 *s|I32 off|NN const U8 *lim
 ERs    |char*  |find_byclass   |NN regexp * prog|NN const regnode *c \
                                |NN char *s|NN const char *strend \
-                               |NULLOK regmatch_info *reginfo \
-                               |bool is_utf_pat
+                               |NULLOK regmatch_info *reginfo
 Es     |void   |to_utf8_substr |NN regexp * prog
 Es     |bool   |to_byte_substr |NN regexp * prog
 ERs    |I32    |reg_check_named_buff_matched   |NN const regexp *rex \
@@ -2189,7 +2194,7 @@ s |void   |force_next     |I32 type
 s      |char*  |force_version  |NN char *s|int guessing
 s      |char*  |force_strict_version   |NN char *s
 s      |char*  |force_word     |NN char *start|int token|int check_keyword \
-                               |int allow_pack|int allow_tick
+                               |int allow_pack
 s      |SV*    |tokeq          |NN SV *sv
 s      |void   |readpipe_override|
 sR     |char*  |scan_const     |NN char *start
@@ -2239,6 +2244,9 @@ so        |SV*    |new_constant   |NULLOK const char *s|STRLEN len \
                                |STRLEN typelen
 s      |int    |deprecate_commaless_var_list
 s      |int    |ao             |int toketype
+s  |void|parse_ident|NN char **s|NN char **d \
+                     |NN char * const e|int allow_package \
+                     |bool is_utf8
 #  if defined(PERL_CR_FILTER)
 s      |I32    |cr_textfilter  |int idx|NULLOK SV *sv|int maxlen
 s      |void   |strip_return   |NN SV *sv
@@ -2431,6 +2439,7 @@ ApoR      |I32*   |hv_riter_p     |NN HV *hv
 ApoR   |HE**   |hv_eiter_p     |NN HV *hv
 Apo    |void   |hv_riter_set   |NN HV *hv|I32 riter
 Apo    |void   |hv_eiter_set   |NN HV *hv|NULLOK HE *eiter
+Ap      |void   |hv_rand_set    |NN HV *hv|U32 new_xhv_rand
 Ap     |void   |hv_name_set    |NN HV *hv|NULLOK const char *name|U32 len|U32 flags
 p      |void   |hv_ename_add   |NN HV *hv|NN const char *name|U32 len \
                                |U32 flags
@@ -2458,84 +2467,6 @@ sMd      |SV*    |find_uninit_var|NULLOK const OP *const obase \
                |NULLOK const SV *const uninit_sv|bool top
 #endif
 
-#ifdef PERL_NEED_MY_HTOLE16
-np     |U16    |my_htole16     |U16 n
-#endif
-#ifdef PERL_NEED_MY_LETOH16
-np     |U16    |my_letoh16     |U16 n
-#endif
-#ifdef PERL_NEED_MY_HTOBE16
-np     |U16    |my_htobe16     |U16 n
-#endif
-#ifdef PERL_NEED_MY_BETOH16
-np     |U16    |my_betoh16     |U16 n
-#endif
-#ifdef PERL_NEED_MY_HTOLE32
-np     |U32    |my_htole32     |U32 n
-#endif
-#ifdef PERL_NEED_MY_LETOH32
-np     |U32    |my_letoh32     |U32 n
-#endif
-#ifdef PERL_NEED_MY_HTOBE32
-np     |U32    |my_htobe32     |U32 n
-#endif
-#ifdef PERL_NEED_MY_BETOH32
-np     |U32    |my_betoh32     |U32 n
-#endif
-#ifdef PERL_NEED_MY_HTOLE64
-np     |U64    |my_htole64     |U64 n
-#endif
-#ifdef PERL_NEED_MY_LETOH64
-np     |U64    |my_letoh64     |U64 n
-#endif
-#ifdef PERL_NEED_MY_HTOBE64
-np     |U64    |my_htobe64     |U64 n
-#endif
-#ifdef PERL_NEED_MY_BETOH64
-np     |U64    |my_betoh64     |U64 n
-#endif
-
-#ifdef PERL_NEED_MY_HTOLES
-np     |short  |my_htoles      |short n
-#endif
-#ifdef PERL_NEED_MY_LETOHS
-np     |short  |my_letohs      |short n
-#endif
-#ifdef PERL_NEED_MY_HTOBES
-np     |short  |my_htobes      |short n
-#endif
-#ifdef PERL_NEED_MY_BETOHS
-np     |short  |my_betohs      |short n
-#endif
-#ifdef PERL_NEED_MY_HTOLEI
-np     |int    |my_htolei      |int n
-#endif
-#ifdef PERL_NEED_MY_LETOHI
-np     |int    |my_letohi      |int n
-#endif
-#ifdef PERL_NEED_MY_HTOBEI
-np     |int    |my_htobei      |int n
-#endif
-#ifdef PERL_NEED_MY_BETOHI
-np     |int    |my_betohi      |int n
-#endif
-#ifdef PERL_NEED_MY_HTOLEL
-np     |long   |my_htolel      |long n
-#endif
-#ifdef PERL_NEED_MY_LETOHL
-np     |long   |my_letohl      |long n
-#endif
-#ifdef PERL_NEED_MY_HTOBEL
-np     |long   |my_htobel      |long n
-#endif
-#ifdef PERL_NEED_MY_BETOHL
-np     |long   |my_betohl      |long n
-#endif
-
-: I think that these are only used by the above, which are macros, and in turn
-: currently they are only used in pp_pack.c, but this is in util.c
-np     |void   |my_swabn       |NN void* ptr|int n
-
 Ap     |GV*    |gv_fetchpvn_flags|NN const char* name|STRLEN len|I32 flags|const svtype sv_type
 Ap     |GV*    |gv_fetchsv|NN SV *name|I32 flags|const svtype sv_type