I'm always getting this error: UnimplementedFeatureError: Copying of type struct C.Friends memory[] memory to storage not yet supported. I don't know what is wrong and how to fix it. Can someone help me, please?
pragma solidity >=0.4.22 <0.7.0;
pragma experimental ABIEncoderV2;
contract C {
struct Friends{
string name;
}
struct Person{
string name;
Friends[] friends;
}
mapping(string => Person) persons;
function map(string memory name)public{
Person memory person;
persons[name] = person;
}
}
persons[name].name = name
. – goodvibration Jul 20 '20 at 10:02