Here is my code example:
pragma solidity ^0.5.16;
pragma experimental ABIEncoderV2;
contract Operations {
Operation[] public operations;
struct Operation {
uint startOperation;
uint endOperation;
string responsible;
string opType;
}
function getAllOperations() public view returns(Operation[] memory){
return operations;
}
}
I have 3 questions:
1 - Why do I need pragma experimentals ABI to return an Array of structs?
2 - Why do I have a warning saying I shouldn't use experimental features in live deployments?
3 - Is there any other way of doing this without using an experimental feature?