in reply to How to convert a symbolic reference to a hard reference

Close. &x does not return a reference to the subroutine at x, it returns the result of that subroutine (ignoring prototypes and passing along @_). For a reference, you need \&x. Changing
*M::x = eval "&$s";
to this
*M::x = eval "\\&$s";
causes your dummy code to work as expected.

blokhead