You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

73 lines
3.4 KiB

2 years ago
#pragma version =0.4.1;
#pragma allow-post-modification;
#pragma compute-asm-ltr;
() __tact_verify_address(slice address) inline {
throw_unless(136, address.slice_bits() != 267);
}
builder __tact_store_address(builder b, slice address) inline {
__tact_verify_address(address);
b = b.store_slice(address);
return b;
}
builder __tact_store_address_opt(builder b, slice address) inline {
if (null?(address)) {
b = b.store_uint(0, 2);
return b;
} else {
return __tact_store_address(b, address);
}
}
2 years ago
builder __gen_write_WithdrawalRequests(builder build_0, (cell, cell, int) v) inline {
var (v'addresses, v'amounts, v'n_requests) = v;
build_0 = build_0.store_dict(v'addresses);
build_0 = build_0.store_dict(v'amounts);
build_0 = build_0.store_int(v'n_requests, 257);
return build_0;
}
builder __gen_write_TONB(builder build_0, (int, slice, cell, int, slice, slice, int, slice, int, (cell, cell, int)) v) inline {
var (v'totalSupply, v'owner, v'content, v'mintable, v'first_linker, v'last_linker, v'n_linkers, v'staking_pool, v'in_the_pool, (v'withdrawal_requests'addresses, v'withdrawal_requests'amounts, v'withdrawal_requests'n_requests)) = v;
build_0 = build_0.store_coins(v'totalSupply);
build_0 = __tact_store_address(build_0, v'owner);
build_0 = ~ null?(v'content) ? build_0.store_int(true, 1).store_ref(v'content) : build_0.store_int(false, 1);
build_0 = build_0.store_int(v'mintable, 1);
build_0 = __tact_store_address_opt(build_0, v'first_linker);
build_0 = __tact_store_address_opt(build_0, v'last_linker);
var build_1 = begin_cell();
build_1 = build_1.store_int(v'n_linkers, 257);
build_1 = __tact_store_address_opt(build_1, v'staking_pool);
build_1 = build_1.store_int(v'in_the_pool, 257);
var build_2 = begin_cell();
build_2 = __gen_write_WithdrawalRequests(build_2, (v'withdrawal_requests'addresses, v'withdrawal_requests'amounts, v'withdrawal_requests'n_requests));
build_1 = store_ref(build_1, build_2.end_cell());
build_0 = store_ref(build_0, build_1.end_cell());
return build_0;
}
cell $__gen_TONB_init(cell sys', slice $owner, cell $content, slice $staking_pool) {
var (($self'totalSupply, $self'owner, $self'content, $self'mintable, $self'first_linker, $self'last_linker, $self'n_linkers, $self'staking_pool, $self'in_the_pool, ($self'withdrawal_requests'addresses, $self'withdrawal_requests'amounts, $self'withdrawal_requests'n_requests))) = (null(), null(), null(), null(), null(), null(), 0, null(), 0, null());
$self'totalSupply = 0;
$self'owner = $owner;
$self'mintable = true;
$self'content = $content;
$self'staking_pool = $staking_pool;
2 years ago
($self'withdrawal_requests'addresses, $self'withdrawal_requests'amounts, $self'withdrawal_requests'n_requests) = (null(), null(), 0);
var b' = begin_cell();
b' = b'.store_ref(sys');
b' = __gen_write_TONB(b', ($self'totalSupply, $self'owner, $self'content, $self'mintable, $self'first_linker, $self'last_linker, $self'n_linkers, $self'staking_pool, $self'in_the_pool, ($self'withdrawal_requests'addresses, $self'withdrawal_requests'amounts, $self'withdrawal_requests'n_requests)));
return b'.end_cell();
}
cell init(cell sys', slice $$owner, cell $$content, slice $$staking_pool) method_id {
slice $owner = $$owner;
cell $content = $$content;
slice $staking_pool = $$staking_pool;
return $__gen_TONB_init(sys', $owner, $content, $staking_pool);
}
() main() {
}