Unify plain-function and custom-op implementations
Unify plain-function and custom-op implementations

Previously, the plain-function case was implemented using ordinary XS
subroutines declared by name. Each of the XS functions had to repeat the
logic used when declaring the custom-op versions.

We now use the same approach in both cases. First, each named operation is
declared using the DECL() macro; then, an XS "BOOT:" section uses the
INSTALL() macro to install the implementation of each operation. Only the
definitions of DECL() and INSTALL() vary according to whether we're using
custom ops. In the absence of custom ops, DECL() creates a subroutine that
can be passed directly to newXS(), and INSTALL() simply calls newXS(). When
custom ops are in use, DECL() and INSTALL() do the more complicated things
they previously did, involving an XS-suitable function, a custom op
implementation, a call checker that upgrades the op tree to use the latter,
and installation of both the XS routines and the call checker.

This allows deletion of a substantial large amount of code that involved a
lot of duplicated logic.

p5pclub/ref-util