1
0
Fork 0
mirror of https://github.com/ton-blockchain/ton synced 2025-03-09 15:40:10 +00:00

Extra currencies (#1122)

* Support extra currencies in tonlib, blockchain-explorer, getAccountPrunned

* Fix dict_combine_with with non-zero mode
This commit is contained in:
SpyCheese 2024-10-01 10:22:49 +03:00 committed by GitHub
parent 257cd8cd9c
commit f94d1bee0c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
12 changed files with 182 additions and 57 deletions

View file

@ -1377,13 +1377,9 @@ void LiteQuery::finish_getAccountState(td::BufferSlice shard_proof) {
if (acc_root.not_null()) {
if (mode_ & 0x40000000) {
vm::MerkleProofBuilder mpb{acc_root};
// account_none$0 = Account;
// account$1 addr:MsgAddressInt storage_stat:StorageInfo storage:AccountStorage = Account;
// account_storage$_ last_trans_lt:uint64 balance:CurrencyCollection state:AccountState = AccountStorage;
// account_active$1 _:StateInit = AccountState;
auto S = mpb.root()->load_cell();
if (S.is_error()) {
fatal_error(S.move_as_error_prefix("Failed to load account: "));
// This does not include code, data and libs into proof, but it includes extra currencies
if (!block::gen::t_Account.validate_ref(mpb.root())) {
fatal_error("failed to validate Account");
return;
}
if (!mpb.extract_proof_to(acc_root)) {