Change was_lvalue_sub back to X; spell out the only use of it
authorFather Chrysostomos <sprout@cpan.org>
Fri, 15 Jul 2011 04:49:08 +0000 (21:49 -0700)
committerFather Chrysostomos <sprout@cpan.org>
Fri, 15 Jul 2011 04:49:39 +0000 (21:49 -0700)
commiteebd3bc0dfa10c5d80023c98a5e80dc4fb6689ca
tree2585d5a81ae97c0fa2dfdb5fcd1b459533634c33
parentfe3772c388e259ff8210505dc7e865853c277e69
Change was_lvalue_sub back to X; spell out the only use of it

OK, now I understand what’s happening.

If there is a public macro (PUSHSUB) that contains a call to a pri-
vate function (was_lvalue_sub), that function has to be exported, so
that non-core code can call it.  But if it is marked X, there is no
was_lvalue_sub shorthand macro visible to non-core code, so when the
PUSHSUB macro is expanded in such code, the was_lvalue_sub(...) bit
becomes a call to the function literally named was_lvalue_sub, as
opposed to Perl_lvalue_sub (and is compiled that way on forgiving
platforms).  Making it A makes that macro available to non-core code,
but also implies that it is available for direct use by extensions,
which is not the case with was_lvalue_sub.

So, this commit makes it X again, but spells it out in PUSHSUB, so
there is no need for the function’s macro to be available when
PUSHSUB is expanded.

Hence, there is no need for the was_lvalue_sub macro to exist, so this
commit also removes it.

See also these three commits:

c73b0699db
7b70e81778
777d901444
cop.h
embed.fnc
embed.h