Hi, everybody!
I'm new in solidity development and I got one project with smart contract for tron blockchain. And as I see there are some problems with returning struct from function. Can I return struct from function in smat contract on tron blockchain? Is it possible or maybe there are some workarounds?

Aug 13, 2022, 7:52 PM
last time I checked, Tron only supports some ancient Solidity versions. Returning structs has been possible for some time already in Solidity, but I guess Tron just doesn't support such new versions.
What you could do is flatten the struct into basic types and return those - unless there are too many variables.
Aug 13, 2022, 7:58 PM
Thanks, for your reply) I think the same way that I should return basic types.
Aug 13, 2022, 8:00 PM

© 2024 Draquery.com All rights reserved.