Got error when I wrote like this:
(int balance, _) = get_balance();


Error:
Error: Func compilation error: contracts/jetton/jetton.fc:273:37: error: cannot assign an expression of type [int, cell] to a variable or pattern of type (int, ??304): cannot unify type (int, ??304) with [int, cell]
(int balance, _) = get_balance();

Jan 23, 2024, 4:23 AM
Oh, I found. It should be:

int ton_balance = get_balance().pair_first();
Jan 23, 2024, 4:24 AM

© 2024 Draquery.com All rights reserved.