diff options
author | Paul "LeoNerd" Evans <leonerd@leonerd.org.uk> | 2023-01-27 15:28:52 +0000 |
---|---|---|
committer | Paul Evans <leonerd@leonerd.org.uk> | 2023-01-28 16:57:35 +0000 |
commit | 8cb94cf6eb83ea14ef27697517f7e92842876536 (patch) | |
tree | 9f7bb6b04f2c999a663b4ee30f6462b13f3643f5 /proto.h | |
parent | 092675293835fcf4645fe38cc0ff45dd39bc9b98 (diff) | |
download | perl-8cb94cf6eb83ea14ef27697517f7e92842876536.tar.gz |
Expose {optimize,finalize}_optree() as real API functions
These are required by XS modules which want to create custom
LOGOP-shaped optrees, to ensure that both sides of the tree get
optimised and finalised.
See also
https://github.com/Perl/perl5/issues/20743
Diffstat (limited to 'proto.h')
-rw-r--r-- | proto.h | 14 |
1 files changed, 6 insertions, 8 deletions
@@ -1127,8 +1127,7 @@ Perl_filter_read(pTHX_ int idx, SV *buf_sv, int maxlen) assert(buf_sv) PERL_CALLCONV void -Perl_finalize_optree(pTHX_ OP *o) - __attribute__visibility__("hidden"); +Perl_finalize_optree(pTHX_ OP *o); #define PERL_ARGS_ASSERT_FINALIZE_OPTREE \ assert(o) @@ -3265,6 +3264,11 @@ Perl_op_wrap_finally(pTHX_ OP *block, OP *finally) assert(block); assert(finally) PERL_CALLCONV void +Perl_optimize_optree(pTHX_ OP *o); +#define PERL_ARGS_ASSERT_OPTIMIZE_OPTREE \ + assert(o) + +PERL_CALLCONV void Perl_package(pTHX_ OP *o) __attribute__visibility__("hidden"); #define PERL_ARGS_ASSERT_PACKAGE \ @@ -7480,12 +7484,6 @@ Perl_op_varname(pTHX_ const OP *o) assert(o) PERL_CALLCONV void -Perl_optimize_optree(pTHX_ OP *o) - __attribute__visibility__("hidden"); -# define PERL_ARGS_ASSERT_OPTIMIZE_OPTREE \ - assert(o) - -PERL_CALLCONV void Perl_warn_elem_scalar_context(pTHX_ const OP *o, SV *name, bool is_hash, bool is_slice) __attribute__visibility__("hidden"); # define PERL_ARGS_ASSERT_WARN_ELEM_SCALAR_CONTEXT \ |