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

Cannot use function in arguments #335

Open
kroggen opened this issue Dec 14, 2023 · 1 comment
Open

Cannot use function in arguments #335

kroggen opened this issue Dec 14, 2023 · 1 comment

Comments

@kroggen
Copy link
Member

kroggen commented Dec 14, 2023

This line of code:

  result = contract.call.value(amount)(resolve(to_call), "test", 111, 222)

Generates this error:

[Contract.LuaCallContract] call err: 'resolve' is not payable

So instead of using the result from the resolve() function, it is using the function itself

@kroggen
Copy link
Member Author

kroggen commented Dec 14, 2023

The current workaround is:

  local address = resolve(to_call)
  result = contract.call.value(amount)(address, "test", 111, 222)

But it would be good if fixed

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

1 participant