I have an Implementation resulting from the return value of Advice#wrap(Implementation), and a FixedValue. I need to turn these into a single Implementation that does not result in a bytecode verification error.
That is:
Implementation advisedMethodCall = Advice.to(...).wrap(someMethodCall);
Implementation firstArgument = FixedValue.argument(0);
// How can I "run" advisedMethodCall followed by firstArgument?
More generally: how do I take two Implementations (that are not instances of Implementation.Composable) and compose them?
(I know from prior experiments that MethodCall achieves this with some sort of inner class named TerminationHandler, where the particular implementation in question, TerminationHandler.Simple.DROPPING, does something to the stack to allow you to compose MethodCalls. I don't know how to do something analogous with an Implementation that is not a MethodCall (e.g. one resulting from Advice#wrap(Implementation)).)