I'd like to get the return value of a low level call.
(bool success, ) = address(0x1234...7890).call{value:0}(callData);
This post discusses a solution that sounds like it should work, but it doesn't have a checkmark and I was unable to get the source working because that last copy command in the toBytes function does not exist. I tried experimenting in solidity assembly with mload and mstore to make that copy command, but I could not.
copy(_addr, btsptr, _len);
Does anyone have a complete solution that actually works for this? Or can anyone help me finish that posted pseudo code from the above-linked post?
(bool success, bytes memory data) = ..., then you can returndata? – goodvibration Jun 16 '20 at 04:59callreturns two values - success status and the data returned from the function. And the fact that you have(bool success, )in your code implies that your on solc 0.5.x or higher. – goodvibration Jun 16 '20 at 11:13