Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow making raw calls returning a value. #3368

Closed
clesaege opened this issue Jan 1, 2018 · 2 comments
Closed

Allow making raw calls returning a value. #3368

clesaege opened this issue Jan 1, 2018 · 2 comments

Comments

@clesaege
Copy link

clesaege commented Jan 1, 2018

Currently the function for making raw calls is call, however the documentation (p42 https://media.readthedocs.org/pdf/solidity/develop/solidity.pdf) specifies that

It is not possible to access the actual data returned (for this we would need to know the encoding and size
in advance).

It would be nice to have a way to make a raw call returning the raw return value. Or to have a raw call where the return value can be specified.

It should work like:
var (x, y) = callReturn[uint, string](bytes4(keccak256("fun(uint256)")), 5778));

That's a real need, in my case for action callback kleros/kleros-interaction#13.

@axic
Copy link
Member

axic commented Jan 1, 2018

For callbacks I suggest to have a look at http://solidity.readthedocs.io/en/develop/types.html?#function-types.

Regarding returning data please see #434. And for ABI decoding see #1707.

@clesaege
Copy link
Author

clesaege commented Jan 1, 2018

Thanks.
I was aware of #1707 but not of #434. I'll move the discussion to #434.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants