The different result when I change the order of the properties of my struct
case 1: struct datastruct {
uint64_t id;
time tradetime;
account_name from;
account_name to;
string data;
asset cost;
string mem;
uint64_t primary_key()const { return id; }
account_name get_to()const { return to; }
};
abi result 1: {
"name": "datatable",
"index_type": "i64",
"key_names": [
"id"
],
"key_types": [
"uint64"
],
"type": "datastruct"
}
case 2: struct datastruct {
uint64_t id;
account_name from;
account_name to;
string data;
asset cost;
string mem;
time tradetime;
uint64_t primary_key()const { return id; }
account_name get_to()const { return to; }
};
abi result 2: {
"name": "datatable",
"index_type": "i64i64i64",
"key_names": [
"id",
"from",
"to"
],
"key_types": [
"uint64",
"account_name",
"account_name"
],
"type": "datastruct"
}
I just changed the order of the properties, but the 'index_type' and 'key_names' have changed. Does anyone know why?
I checked this on the latest version, it doesn't behave as mentioned in this ticket anymore.