Browse Source

deployment_fix

master
AlexG 2 years ago
parent
commit
b13bfe447a
  1. 2
      package.json
  2. 174
      sources/jetton.deploy.ts
  3. 1298
      sources/output/jetton_JettonDefaultWallet.abi
  4. 1
      sources/output/jetton_JettonDefaultWallet.abi.ipfs
  5. BIN
      sources/output/jetton_JettonDefaultWallet.boc
  6. BIN
      sources/output/jetton_JettonDefaultWallet.code.boc
  7. 196
      sources/output/jetton_JettonDefaultWallet.code.fc
  8. 216
      sources/output/jetton_JettonDefaultWallet.code.fif
  9. 241
      sources/output/jetton_JettonDefaultWallet.code.rev.fif
  10. BIN
      sources/output/jetton_JettonDefaultWallet.init.boc
  11. 37
      sources/output/jetton_JettonDefaultWallet.init.fc
  12. 40
      sources/output/jetton_JettonDefaultWallet.init.fif
  13. 26
      sources/output/jetton_JettonDefaultWallet.init.rev.fif
  14. 67
      sources/output/jetton_JettonDefaultWallet.md
  15. 1
      sources/output/jetton_JettonDefaultWallet.pkg
  16. 1301
      sources/output/jetton_JettonDefaultWallet.ts
  17. 1329
      sources/output/jetton_SampleJetton.abi
  18. 1
      sources/output/jetton_SampleJetton.abi.ipfs
  19. BIN
      sources/output/jetton_SampleJetton.boc
  20. BIN
      sources/output/jetton_SampleJetton.code.boc
  21. 248
      sources/output/jetton_SampleJetton.code.fc
  22. 301
      sources/output/jetton_SampleJetton.code.fif
  23. 452
      sources/output/jetton_SampleJetton.code.rev.fif
  24. BIN
      sources/output/jetton_SampleJetton.init.boc
  25. 39
      sources/output/jetton_SampleJetton.init.fc
  26. 54
      sources/output/jetton_SampleJetton.init.fif
  27. 42
      sources/output/jetton_SampleJetton.init.rev.fif
  28. 72
      sources/output/jetton_SampleJetton.md
  29. 1
      sources/output/jetton_SampleJetton.pkg
  30. 1353
      sources/output/jetton_SampleJetton.ts
  31. 8
      sources/utils/jetton-helpers.ts

2
package.json

@ -11,8 +11,8 @@
"deploy": "ts-node sources/jetton.deploy.ts"
},
"dependencies": {
"@types/jest": "^29.2.4",
"@aws-crypto/sha256-js": "^3.0.0",
"@types/jest": "^29.2.4",
"@types/node": "^18.11.14",
"@types/qs": "^6.9.7",
"jest": "^29.3.1",

174
sources/jetton.deploy.ts

@ -1,25 +1,11 @@
import { beginCell, contractAddress, toNano, TonClient, TonClient4, Address, WalletContractV4, internal, fromNano} from "ton";
import {mnemonicToPrivateKey} from "ton-crypto";
import {JettonMetaDataKeys} from 'utils/jetton-helpers';
import {buildOnchainMetadata} from "./utils/jetton-helpers";
import {SampleJetton} from "./output/jetton_SampleJetton";
(async () => { //need changes for jetton
// This is example data - Modify these params for your own jetton!
// - Data is stored on-chain (except for the image data itself)
// - Owner should usually be the deploying wallet's address.
const jettonParams = {
name: "MyJetton",
symbol: "JET1",
image: "https://www.linkpicture.com/q/download_183.png", // Image url
description: "My jetton",
};
//create client for testnet Toncenter API
const client = new TonClient({
endpoint: 'https://testnet.toncenter.com/api/v2/jsonRPC',
@ -48,16 +34,28 @@ import {JettonMetaDataKeys} from 'utils/jetton-helpers';
// Get deployment wallet balance
let balance: bigint = await contract.getBalance();
// This is example data - Modify these params for your own jetton
// - Data is stored on-chain (except for the image data itself)
const jettonParams = {
name: "TactJet",
description: "My jetton",
image: "https://www.linkpicture.com/q/download_183.png" // Image url
};
// Generate define owner of Jetton contract
// Owner should usually be the deploying wallet's address.
let owner = Address.parse('kQDND6yHEzKB82ZGRn58aY9Tt_69Ie_uz73e2VuuJ3fVVcxf');
// Create content Cell
let content = beginCell().storeUint()
let content = buildOnchainMetadata(jettonParams);
// Compute init for deployment
// Compute init data for deployment
let init = await SampleJetton.init(owner, content);
let destination_address = contractAddress(workchain, init);
let deployAmount = toNano('0.5');
// send a message on new address contract to deploy it
let seqno: number = await contract.getSeqno();
console.log('🛠Preparing new outgoing massage from deployment wallet. Seqno = ', seqno);
@ -77,141 +75,3 @@ import {JettonMetaDataKeys} from 'utils/jetton-helpers';
});
console.log('======deployment message sent to ', destination_address, ' ======');
})();
export type JettonMetaDataKeys = "name" | "description" | "image" | "symbol";
const jettonOnChainMetadataSpec: {
[key in JettonMetaDataKeys]: "utf8" | "ascii" | undefined;
} = {
name: "utf8",
description: "utf8",
image: "ascii",
symbol: "utf8",
};
const sha256 = (str: string) => {
const sha = new Sha256();
sha.update(str);
return Buffer.from(sha.digestSync());
};
export function buildTokenMetadataCell(data: { [s: string]: string | undefined }): Cell {
const KEYLEN = 256;
const dict = beginDict(KEYLEN);
Object.entries(data).forEach(([k, v]: [string, string | undefined]) => {
if (!jettonOnChainMetadataSpec[k as JettonMetaDataKeys])
throw new Error(`Unsupported onchain key: ${k}`);
if (v === undefined || v === "") return;
let bufferToStore = Buffer.from(v, jettonOnChainMetadataSpec[k as JettonMetaDataKeys]);
const CELL_MAX_SIZE_BYTES = Math.floor((1023 - 8) / 8);
const rootCell = new Cell();
rootCell.bits.writeUint8(SNAKE_PREFIX);
let currentCell = rootCell;
while (bufferToStore.length > 0) {
currentCell.bits.writeBuffer(bufferToStore.slice(0, CELL_MAX_SIZE_BYTES));
bufferToStore = bufferToStore.slice(CELL_MAX_SIZE_BYTES);
if (bufferToStore.length > 0) {
const newCell = new Cell();
currentCell.refs.push(newCell);
currentCell = newCell;
}
}
dict.storeRef(sha256(k), rootCell);
});
return beginCell().storeInt(ONCHAIN_CONTENT_PREFIX, 8).storeDict(dict.endDict()).endCell();
}
export function parseTokenMetadataCell(contentCell: Cell): {
[s in JettonMetaDataKeys]?: string;
} {
// Note that this relies on what is (perhaps) an internal implementation detail:
// "ton" library dict parser converts: key (provided as buffer) => BN(base10)
// and upon parsing, it reads it back to a BN(base10)
// tl;dr if we want to read the map back to a JSON with string keys, we have to convert BN(10) back to hex
const toKey = (str: string) => new BN(str, "hex").toString(10);
const KEYLEN = 256;
const contentSlice = contentCell.beginParse();
if (contentSlice.readUint(8).toNumber() !== ONCHAIN_CONTENT_PREFIX)
throw new Error("Expected onchain content marker");
const dict = contentSlice.readDict(KEYLEN, (s) => {
const buffer = Buffer.from("");
const sliceToVal = (s: Slice, v: Buffer, isFirst: boolean) => {
s.toCell().beginParse();
if (isFirst && s.readUint(8).toNumber() !== SNAKE_PREFIX)
throw new Error("Only snake format is supported");
v = Buffer.concat([v, s.readRemainingBytes()]);
if (s.remainingRefs === 1) {
v = sliceToVal(s.readRef(), v, false);
}
return v;
};
return sliceToVal(s.readRef(), buffer, true);
});
const res: { [s in JettonMetaDataKeys]?: string } = {};
Object.keys(jettonOnChainMetadataSpec).forEach((k) => {
const val = dict
.get(toKey(sha256(k).toString("hex")))
?.toString(jettonOnChainMetadataSpec[k as JettonMetaDataKeys]);
if (val) res[k as JettonMetaDataKeys] = val;
});
return res;
}
export function jettonMinterInitData(
owner: Address,
metadata: { [s in JettonMetaDataKeys]?: string }
): Cell {
return beginCell()
.storeCoins(0)
.storeAddress(owner)
.storeRef(buildTokenMetadataCell(metadata))
.storeRef(JETTON_WALLET_CODE)
.endCell();
}
// return the init Cell of the contract storage (according to load_data() contract method)
export function initData() {
return jettonMinterInitData(jettonParams.owner, {
name: jettonParams.name,
symbol: jettonParams.symbol,
image: jettonParams.image,
description: jettonParams.description,
});
}
// return the op that should be sent to the contract on deployment, can be "null" to send an empty message
export function initMessage() {
return null; // TODO?
}
// optional end-to-end sanity test for the actual on-chain contract to see it is actually working on-chain
export async function postDeployTest(
walletContract: WalletContract,
secretKey: Buffer,
contractAddress: Address
) {
const call = await walletContract.client.callGetMethod(contractAddress, "get_jetton_data");
console.log(
parseTokenMetadataCell(
Cell.fromBoc(Buffer.from(call.stack[3][1].bytes, "base64").toString("hex"))[0]
)
);
}

1298
sources/output/jetton_JettonDefaultWallet.abi

File diff suppressed because one or more lines are too long

1
sources/output/jetton_JettonDefaultWallet.abi.ipfs

File diff suppressed because one or more lines are too long

BIN
sources/output/jetton_JettonDefaultWallet.boc

Binary file not shown.

BIN
sources/output/jetton_JettonDefaultWallet.code.boc

Binary file not shown.

196
sources/output/jetton_JettonDefaultWallet.fc → sources/output/jetton_JettonDefaultWallet.code.fc

@ -10,7 +10,12 @@ global cell __tact_context_sys;
(int, slice, int, slice) __tact_context_get() inline { return __tact_context; }
() __tact_verify_address(slice address) inline {
throw_unless(134, address.slice_bits() != 267);
throw_unless(136, address.slice_bits() != 267);
}
builder __tact_store_bool(builder b, int v) inline {
b = b.store_int(v, 1);
return b;
}
(slice, slice) __tact_load_address(slice cs) inline {
@ -44,7 +49,16 @@ builder __tact_store_address_opt(builder b, slice address) inline {
}
}
slice __tact_compute_contract_address(int chain, cell code, cell data) {
slice __tact_create_address(int chain, int hash) inline {
var b = begin_cell();
b = b.store_uint(2, 2);
b = b.store_uint(0, 1);
b = b.store_int(chain, 8);
b = b.store_uint(hash, 256);
return b.end_cell().begin_parse();
}
slice __tact_compute_contract_address(int chain, cell code, cell data) inline {
var b = begin_cell();
b = b.store_uint(0, 2);
b = b.store_uint(3, 2);
@ -52,12 +66,7 @@ slice __tact_compute_contract_address(int chain, cell code, cell data) {
b = b.store_ref(code);
b = b.store_ref(data);
var hash = cell_hash(b.end_cell());
var b2 = begin_cell();
b2 = b2.store_uint(2, 2);
b2 = b2.store_uint(0, 1);
b2 = b2.store_int(chain, 8);
b2 = b2.store_uint(hash, 256);
return b2.end_cell().begin_parse();
return __tact_create_address(chain, hash);
}
int __tact_address_eq(slice a, slice b) inline {
@ -74,42 +83,39 @@ cell __tact_dict_set_code(cell dict, int id, cell code) inline {
cell __tact_dict_get_code(cell dict, int id) inline {
var (data, ok) = udict_get_ref?(dict, 16, id);
throw_unless(100, ok);
throw_unless(135, ok);
return data;
}
(slice, ((int, int, slice, slice, cell, int, slice))) __gen_read_TokenTransfer(slice sc_0) inline {
(slice, ((int, int, slice, slice, cell, int, slice))) __gen_read_TokenTransfer(slice sc_0) inline_ref {
throw_unless(129, sc_0~load_uint(32) == 260734629);
var v'queryId = sc_0~load_uint(64);
var v'amount = sc_0~load_coins();
var v'destination = sc_0~__tact_load_address();
var v'responseDestination = sc_0~__tact_load_address_opt();
var v'customPayload = null();
if (sc_0~load_int(1)) {
v'customPayload = sc_0~load_ref();
}
var v'customPayload = sc_0~load_int(1) ? sc_0~load_ref() : null();
var v'forwardTonAmount = sc_0~load_coins();
var v'forwardPayload = sc_0;
return (sc_0, (v'queryId, v'amount, v'destination, v'responseDestination, v'customPayload, v'forwardTonAmount, v'forwardPayload));
}
builder __gen_write_TokenTransferInternal(builder build_0, (int, int, slice, slice, int, slice) v) inline {
builder __gen_write_TokenTransferInternal(builder build_0, (int, int, slice, slice, int, slice) v) inline_ref {
var (v'queryId, v'amount, v'from, v'responseAddress, v'forwardTonAmount, v'forwardPayload) = v;
build_0 = store_uint(build_0, 395134233, 32);
build_0 = store_uint(build_0, v'queryId, 64);
build_0 = store_coins(build_0, v'amount);
build_0 = build_0.store_uint(v'queryId, 64);
build_0 = build_0.store_coins(v'amount);
build_0 = __tact_store_address(build_0, v'from);
build_0 = __tact_store_address_opt(build_0, v'responseAddress);
build_0 = store_coins(build_0, v'forwardTonAmount);
build_0 = store_slice(build_0, v'forwardPayload);
build_0 = build_0.store_coins(v'forwardTonAmount);
build_0 = build_0.store_slice(v'forwardPayload);
return build_0;
}
cell __gen_writecell_TokenTransferInternal((int, int, slice, slice, int, slice) v) inline {
cell __gen_writecell_TokenTransferInternal((int, int, slice, slice, int, slice) v) inline_ref {
return __gen_write_TokenTransferInternal(begin_cell(), v).end_cell();
}
(slice, ((int, int, slice, slice, int, slice))) __gen_read_TokenTransferInternal(slice sc_0) inline {
(slice, ((int, int, slice, slice, int, slice))) __gen_read_TokenTransferInternal(slice sc_0) inline_ref {
throw_unless(129, sc_0~load_uint(32) == 395134233);
var v'queryId = sc_0~load_uint(64);
var v'amount = sc_0~load_coins();
@ -120,21 +126,21 @@ cell __gen_writecell_TokenTransferInternal((int, int, slice, slice, int, slice)
return (sc_0, (v'queryId, v'amount, v'from, v'responseAddress, v'forwardTonAmount, v'forwardPayload));
}
builder __gen_write_TokenNotification(builder build_0, (int, int, slice, slice) v) inline {
builder __gen_write_TokenNotification(builder build_0, (int, int, slice, slice) v) inline_ref {
var (v'queryId, v'amount, v'from, v'forwardPayload) = v;
build_0 = store_uint(build_0, 1935855772, 32);
build_0 = store_uint(build_0, v'queryId, 64);
build_0 = store_coins(build_0, v'amount);
build_0 = build_0.store_uint(v'queryId, 64);
build_0 = build_0.store_coins(v'amount);
build_0 = __tact_store_address(build_0, v'from);
build_0 = store_slice(build_0, v'forwardPayload);
build_0 = build_0.store_slice(v'forwardPayload);
return build_0;
}
cell __gen_writecell_TokenNotification((int, int, slice, slice) v) inline {
cell __gen_writecell_TokenNotification((int, int, slice, slice) v) inline_ref {
return __gen_write_TokenNotification(begin_cell(), v).end_cell();
}
(slice, ((int, int, slice, slice))) __gen_read_TokenBurn(slice sc_0) inline {
(slice, ((int, int, slice, slice))) __gen_read_TokenBurn(slice sc_0) inline_ref {
throw_unless(129, sc_0~load_uint(32) == 1499400124);
var v'queryId = sc_0~load_uint(64);
var v'amount = sc_0~load_coins();
@ -143,40 +149,40 @@ cell __gen_writecell_TokenNotification((int, int, slice, slice) v) inline {
return (sc_0, (v'queryId, v'amount, v'owner, v'responseAddress));
}
builder __gen_write_TokenBurnNotification(builder build_0, (int, int, slice, slice) v) inline {
builder __gen_write_TokenBurnNotification(builder build_0, (int, int, slice, slice) v) inline_ref {
var (v'queryId, v'amount, v'owner, v'responseAddress) = v;
build_0 = store_uint(build_0, 2078119902, 32);
build_0 = store_uint(build_0, v'queryId, 64);
build_0 = store_coins(build_0, v'amount);
build_0 = build_0.store_uint(v'queryId, 64);
build_0 = build_0.store_coins(v'amount);
build_0 = __tact_store_address(build_0, v'owner);
build_0 = __tact_store_address_opt(build_0, v'responseAddress);
return build_0;
}
cell __gen_writecell_TokenBurnNotification((int, int, slice, slice) v) inline {
cell __gen_writecell_TokenBurnNotification((int, int, slice, slice) v) inline_ref {
return __gen_write_TokenBurnNotification(begin_cell(), v).end_cell();
}
builder __gen_write_TokenExcesses(builder build_0, (int) v) inline {
builder __gen_write_TokenExcesses(builder build_0, (int) v) inline_ref {
var (v'queryId) = v;
build_0 = store_uint(build_0, 3576854235, 32);
build_0 = store_uint(build_0, v'queryId, 64);
build_0 = build_0.store_uint(v'queryId, 64);
return build_0;
}
cell __gen_writecell_TokenExcesses((int) v) inline {
cell __gen_writecell_TokenExcesses((int) v) inline_ref {
return __gen_write_TokenExcesses(begin_cell(), v).end_cell();
}
builder __gen_write_JettonDefaultWallet(builder build_0, (int, slice, slice) v) inline {
builder __gen_write_JettonDefaultWallet(builder build_0, (int, slice, slice) v) inline_ref {
var (v'balance, v'owner, v'master) = v;
build_0 = store_int(build_0, v'balance, 257);
build_0 = build_0.store_int(v'balance, 257);
build_0 = __tact_store_address(build_0, v'owner);
build_0 = __tact_store_address(build_0, v'master);
return build_0;
}
(slice, ((int, slice, slice))) __gen_read_JettonDefaultWallet(slice sc_0) inline {
(slice, ((int, slice, slice))) __gen_read_JettonDefaultWallet(slice sc_0) inline_ref {
var v'balance = sc_0~load_int(257);
var v'owner = sc_0~__tact_load_address();
var v'master = sc_0~__tact_load_address();
@ -188,76 +194,73 @@ _ __gen_StateInit_get_code((cell, cell) v) inline {
return v'code;
}
(int, slice, slice) __gen_load_JettonDefaultWallet() inline {
(int, slice, slice, cell) __gen_JettonWalletData_to_external(((int, slice, slice, cell)) v) {
var (v'balance, v'owner, v'master, v'walletCode) = v;
return (v'balance, v'owner, v'master, v'walletCode);
}
(int, slice, slice) __gen_load_JettonDefaultWallet() inline_ref {
slice sc = get_data().begin_parse();
__tact_context_sys = sc~load_ref();
return sc~__gen_read_JettonDefaultWallet();
}
() __gen_store_JettonDefaultWallet((int, slice, slice) v) impure inline {
() __gen_store_JettonDefaultWallet((int, slice, slice) v) impure inline_ref {
builder b = begin_cell();
b = b.store_ref(__tact_context_sys);
b = __gen_write_JettonDefaultWallet(b, v);
set_data(b.end_cell());
}
builder storeBool(builder $s, int $value) impure {
if ($value) {
return store_int($s, (- 1), 1);
} else {
return store_int($s, 0, 1);
}
}
slice contractAddress((cell, cell) $s) impure {
slice $contractAddress((cell, cell) $s) impure {
var (($s'code, $s'data)) = $s;
return __tact_compute_contract_address(0, $s'code, $s'data);
}
() send((int, slice, int, int, cell, cell, cell) $params) impure {
() $send((int, slice, int, int, cell, cell, cell) $params) impure {
var (($params'bounce, $params'to, $params'value, $params'mode, $params'body, $params'code, $params'data)) = $params;
builder $b = begin_cell();
$b = store_int($b, 1, 2);
$b = storeBool($b, $params'bounce);
$b = __tact_store_bool($b, $params'bounce);
$b = store_int($b, 0, 3);
$b = __tact_store_address($b, $params'to);
$b = store_coins($b, $params'value);
$b = store_int($b, 0, ((((1 + 4) + 4) + 64) + 32));
if (((~ null?($params'code)) | (~ null?($params'data)))) {
$b = storeBool($b, true);
$b = __tact_store_bool($b, true);
builder $bc = begin_cell();
$bc = storeBool($bc, false);
$bc = storeBool($bc, false);
$bc = __tact_store_bool($bc, false);
$bc = __tact_store_bool($bc, false);
if ((~ null?($params'code))) {
$bc = storeBool($bc, true);
$bc = __tact_store_bool($bc, true);
$bc = store_ref($bc, __tact_not_null($params'code));
} else {
$bc = storeBool($bc, false);
$bc = __tact_store_bool($bc, false);
}
if ((~ null?($params'data))) {
$bc = storeBool($bc, true);
$bc = __tact_store_bool($bc, true);
$bc = store_ref($bc, __tact_not_null($params'data));
} else {
$bc = storeBool($bc, false);
$bc = __tact_store_bool($bc, false);
}
$bc = storeBool($bc, false);
$b = storeBool($b, true);
$bc = __tact_store_bool($bc, false);
$b = __tact_store_bool($b, true);
$b = store_ref($b, end_cell($bc));
} else {
$b = storeBool($b, false);
$b = __tact_store_bool($b, false);
}
cell $body = $params'body;
if ((~ null?($body))) {
$b = storeBool($b, true);
$b = __tact_store_bool($b, true);
$b = store_ref($b, __tact_not_null($body));
} else {
$b = storeBool($b, false);
$b = __tact_store_bool($b, false);
}
cell $c = end_cell($b);
send_raw_message($c, $params'mode);
}
int __gen_Context_readForwardFee((int, slice, int, slice) $self) impure {
int $__gen_Context_readForwardFee((int, slice, int, slice) $self) impure {
var (($self'bounced, $self'sender, $self'value, $self'raw)) = $self;
var (($self'bounced, $self'sender, $self'value, $self'raw)) = $self;
slice $sc = $self'raw;
@ -267,7 +270,7 @@ int __gen_Context_readForwardFee((int, slice, int, slice) $self) impure {
return (($sc~load_coins() * 3) / 2);
}
cell __gen_JettonDefaultWallet_init(cell sys', slice $master, slice $owner) {
cell $__gen_JettonDefaultWallet_init(cell sys', slice $master, slice $owner) {
var (($self'balance, $self'owner, $self'master)) = (null(), null(), null());
$self'balance = 0;
$self'owner = $owner;
@ -278,54 +281,55 @@ cell __gen_JettonDefaultWallet_init(cell sys', slice $master, slice $owner) {
return b'.end_cell();
}
(cell, cell) __gen_JettonDefaultWallet_init_child(cell sys', slice $master, slice $owner) {
(cell, cell) $__gen_JettonDefaultWallet_init_child(cell sys', slice $master, slice $owner) {
slice sc' = sys'.begin_parse();
cell source = sc'~load_dict();
cell mine = __tact_dict_get_code(source, 55471);
cell contracts = new_dict();
cell code_55471 = __tact_dict_get_code(source, 55471);
contracts = __tact_dict_set_code(contracts, 55471, code_55471);
;; Contract Code: JettonDefaultWallet
cell mine = __tact_dict_get_code(source, 55471);
contracts = __tact_dict_set_code(contracts, 55471, mine);
cell sys = begin_cell().store_dict(contracts).end_cell();
return (mine, __gen_JettonDefaultWallet_init(sys, $master, $owner));
return (mine, $__gen_JettonDefaultWallet_init(sys, $master, $owner));
}
(int, slice, slice, cell) __gen_JettonDefaultWallet_get_wallet_data((int, slice, slice) $self) impure {
(int, slice, slice, cell) $__gen_JettonDefaultWallet_get_wallet_data((int, slice, slice) $self) impure {
var (($self'balance, $self'owner, $self'master)) = $self;
return ($self'balance, $self'owner, $self'master, __gen_StateInit_get_code(__gen_JettonDefaultWallet_init_child(__tact_context_sys, $self'master, $self'owner)));
return ($self'balance, $self'owner, $self'master, __gen_StateInit_get_code($__gen_JettonDefaultWallet_init_child(__tact_context_sys, $self'master, $self'owner)));
}
_ __gen_get_get_wallet_data() method_id(97026) {
_ $__gen_get_get_wallet_data() method_id(97026) {
var self = __gen_load_JettonDefaultWallet();
var res = __gen_JettonDefaultWallet_get_wallet_data(self);
return res;
var res = $__gen_JettonDefaultWallet_get_wallet_data(self);
return __gen_JettonWalletData_to_external(res);
}
(((int, slice, slice)), ()) __gen_JettonDefaultWallet_receive_TokenTransfer((int, slice, slice) $self, (int, int, slice, slice, cell, int, slice) $msg) impure {
(((int, slice, slice)), ()) $__gen_JettonDefaultWallet_receive_TokenTransfer((int, slice, slice) $self, (int, int, slice, slice, cell, int, slice) $msg) impure {
var ($self'balance, $self'owner, $self'master) = $self;
var ($msg'queryId, $msg'amount, $msg'destination, $msg'responseDestination, $msg'customPayload, $msg'forwardTonAmount, $msg'forwardPayload) = $msg;
var ($ctx'bounced, $ctx'sender, $ctx'value, $ctx'raw) = __tact_context_get();
throw_unless(4429, __tact_address_eq($ctx'sender, $self'owner));
$self'balance = ($self'balance - $msg'amount);
throw_unless(62972, ($self'balance >= 0));
int $fwdFee = __gen_Context_readForwardFee(($ctx'bounced, $ctx'sender, $ctx'value, $ctx'raw));
int $fwdFee = $__gen_Context_readForwardFee(($ctx'bounced, $ctx'sender, $ctx'value, $ctx'raw));
int $fwdCount = 1;
if (($msg'forwardTonAmount > 0)) {
$fwdCount = 2;
}
throw_unless(16059, ($ctx'value > ((($fwdCount * $fwdFee) + (2 * 10000000)) + 10000000)));
var ($init'code, $init'data) = __gen_JettonDefaultWallet_init_child(__tact_context_sys, $self'master, $msg'destination);
slice $walletAddress = contractAddress(($init'code, $init'data));
send((true, $walletAddress, 0, 64, __gen_writecell_TokenTransferInternal(($msg'queryId, $msg'amount, $self'owner, $self'owner, $msg'forwardTonAmount, $msg'forwardPayload)), $init'code, $init'data));
var ($init'code, $init'data) = $__gen_JettonDefaultWallet_init_child(__tact_context_sys, $self'master, $msg'destination);
slice $walletAddress = $contractAddress(($init'code, $init'data));
$send((true, $walletAddress, 0, 64, __gen_writecell_TokenTransferInternal(($msg'queryId, $msg'amount, $self'owner, $self'owner, $msg'forwardTonAmount, $msg'forwardPayload)), $init'code, $init'data));
return (($self'balance, $self'owner, $self'master), ());
}
(((int, slice, slice)), ()) __gen_JettonDefaultWallet_receive_TokenTransferInternal((int, slice, slice) $self, (int, int, slice, slice, int, slice) $msg) impure {
(((int, slice, slice)), ()) $__gen_JettonDefaultWallet_receive_TokenTransferInternal((int, slice, slice) $self, (int, int, slice, slice, int, slice) $msg) impure {
var ($self'balance, $self'owner, $self'master) = $self;
var ($msg'queryId, $msg'amount, $msg'from, $msg'responseAddress, $msg'forwardTonAmount, $msg'forwardPayload) = $msg;
var ($ctx'bounced, $ctx'sender, $ctx'value, $ctx'raw) = __tact_context_get();
if (__tact_address_neq($ctx'sender, $self'master)) {
var ($sinit'code, $sinit'data) = __gen_JettonDefaultWallet_init_child(__tact_context_sys, $self'master, $msg'from);
throw_unless(4429, __tact_address_eq(contractAddress(($sinit'code, $sinit'data)), $ctx'sender));
var ($sinit'code, $sinit'data) = $__gen_JettonDefaultWallet_init_child(__tact_context_sys, $self'master, $msg'from);
throw_unless(4429, __tact_address_eq($contractAddress(($sinit'code, $sinit'data)), $ctx'sender));
}
$self'balance = ($self'balance + $msg'amount);
throw_unless(62972, ($self'balance >= 0));
@ -334,30 +338,30 @@ _ __gen_get_get_wallet_data() method_id(97026) {
int $storageFee = (10000000 - min($tonBalanceBeforeMsg, 10000000));
$msgValue = ($msgValue - ($storageFee + 10000000));
if (($msg'forwardTonAmount > 0)) {
int $fwdFee = __gen_Context_readForwardFee(($ctx'bounced, $ctx'sender, $ctx'value, $ctx'raw));
int $fwdFee = $__gen_Context_readForwardFee(($ctx'bounced, $ctx'sender, $ctx'value, $ctx'raw));
$msgValue = ($msgValue - ($msg'forwardTonAmount + $fwdFee));
send((false, $self'owner, $msg'forwardTonAmount, 0, __gen_writecell_TokenNotification(($msg'queryId, $msg'amount, $msg'from, $msg'forwardPayload)), null(), null()));
$send((false, $self'owner, $msg'forwardTonAmount, 0, __gen_writecell_TokenNotification(($msg'queryId, $msg'amount, $msg'from, $msg'forwardPayload)), null(), null()));
}
if (((~ null?($msg'responseAddress)) & ($msgValue > 0))) {
send((false, __tact_not_null($msg'responseAddress), $msgValue, 0, __gen_writecell_TokenExcesses(($msg'queryId)), null(), null()));
$send((false, __tact_not_null($msg'responseAddress), $msgValue, 0, __gen_writecell_TokenExcesses(($msg'queryId)), null(), null()));
}
return (($self'balance, $self'owner, $self'master), ());
}
(((int, slice, slice)), ()) __gen_JettonDefaultWallet_receive_TokenBurn((int, slice, slice) $self, (int, int, slice, slice) $msg) impure {
(((int, slice, slice)), ()) $__gen_JettonDefaultWallet_receive_TokenBurn((int, slice, slice) $self, (int, int, slice, slice) $msg) impure {
var ($self'balance, $self'owner, $self'master) = $self;
var ($msg'queryId, $msg'amount, $msg'owner, $msg'responseAddress) = $msg;
var ($ctx'bounced, $ctx'sender, $ctx'value, $ctx'raw) = __tact_context_get();
throw_unless(4429, __tact_address_eq($ctx'sender, $self'owner));
$self'balance = ($self'balance - $msg'amount);
throw_unless(62972, ($self'balance >= 0));
int $fwdFee = __gen_Context_readForwardFee(($ctx'bounced, $ctx'sender, $ctx'value, $ctx'raw));
int $fwdFee = $__gen_Context_readForwardFee(($ctx'bounced, $ctx'sender, $ctx'value, $ctx'raw));
throw_unless(16059, ($ctx'value > (($fwdFee + (2 * 10000000)) + 10000000)));
send((true, $self'master, 0, 64, __gen_writecell_TokenBurnNotification(($msg'queryId, $msg'amount, $self'owner, $self'owner)), null(), null()));
$send((true, $self'master, 0, 64, __gen_writecell_TokenBurnNotification(($msg'queryId, $msg'amount, $self'owner, $self'owner)), null(), null()));
return (($self'balance, $self'owner, $self'master), ());
}
((int, slice, slice), ()) __gen_JettonDefaultWallet_receive_bounced((int, slice, slice) $self, slice $msg) impure {
((int, slice, slice), ()) $__gen_JettonDefaultWallet_receive_bounced((int, slice, slice) $self, slice $msg) impure {
var ($self'balance, $self'owner, $self'master) = $self;
$msg~skip_bits(32);
int $op = $msg~load_uint(32);
@ -385,7 +389,7 @@ _ __gen_get_get_wallet_data() method_id(97026) {
;; Handle bounced messages
if (msg_bounced) {
var self = __gen_load_JettonDefaultWallet();
self~__gen_JettonDefaultWallet_receive_bounced(in_msg);
self~$__gen_JettonDefaultWallet_receive_bounced(in_msg);
__gen_store_JettonDefaultWallet(self);
return ();
}
@ -394,7 +398,7 @@ _ __gen_get_get_wallet_data() method_id(97026) {
if (op == 260734629) {
var self = __gen_load_JettonDefaultWallet();
var msg = in_msg~__gen_read_TokenTransfer();
self~__gen_JettonDefaultWallet_receive_TokenTransfer(msg);
self~$__gen_JettonDefaultWallet_receive_TokenTransfer(msg);
__gen_store_JettonDefaultWallet(self);
return ();
}
@ -403,7 +407,7 @@ _ __gen_get_get_wallet_data() method_id(97026) {
if (op == 395134233) {
var self = __gen_load_JettonDefaultWallet();
var msg = in_msg~__gen_read_TokenTransferInternal();
self~__gen_JettonDefaultWallet_receive_TokenTransferInternal(msg);
self~$__gen_JettonDefaultWallet_receive_TokenTransferInternal(msg);
__gen_store_JettonDefaultWallet(self);
return ();
}
@ -412,7 +416,7 @@ _ __gen_get_get_wallet_data() method_id(97026) {
if (op == 1499400124) {
var self = __gen_load_JettonDefaultWallet();
var msg = in_msg~__gen_read_TokenBurn();
self~__gen_JettonDefaultWallet_receive_TokenBurn(msg);
self~$__gen_JettonDefaultWallet_receive_TokenBurn(msg);
__gen_store_JettonDefaultWallet(self);
return ();
}
@ -420,10 +424,6 @@ _ __gen_get_get_wallet_data() method_id(97026) {
throw(130);
}
cell init_JettonDefaultWallet(cell sys', slice master, slice owner) method_id {
return __gen_JettonDefaultWallet_init(sys', master, owner);
}
_ supported_interfaces() method_id {
return (
"org.ton.introspection.v0"H >> 128,
@ -433,5 +433,5 @@ _ supported_interfaces() method_id {
}
_ get_abi_ipfs() {
return "ipfs://QmdPUYM67SQxPhiSig4LVW3rjqcKgEce6SGvRp3oZRXEM1";
return "ipfs://QmXBfqbQzeN1uT55MyYpwhU9RV47Sq3quVt3qFLgWH8NhD";
}

216
sources/output/jetton_JettonDefaultWallet.fif → sources/output/jetton_JettonDefaultWallet.code.fif

@ -3,10 +3,12 @@ PROGRAM{
DECLPROC __tact_not_null
DECLPROC __tact_context_get
DECLPROC __tact_verify_address
DECLPROC __tact_store_bool
DECLPROC __tact_load_address
DECLPROC __tact_load_address_opt
DECLPROC __tact_store_address
DECLPROC __tact_store_address_opt
DECLPROC __tact_create_address
DECLPROC __tact_compute_contract_address
DECLPROC __tact_address_eq
DECLPROC __tact_address_neq
@ -26,22 +28,21 @@ PROGRAM{
DECLPROC __gen_write_JettonDefaultWallet
DECLPROC __gen_read_JettonDefaultWallet
DECLPROC __gen_StateInit_get_code
DECLPROC __gen_JettonWalletData_to_external
DECLPROC __gen_load_JettonDefaultWallet
DECLPROC __gen_store_JettonDefaultWallet
DECLPROC storeBool
DECLPROC contractAddress
DECLPROC send
DECLPROC __gen_Context_readForwardFee
DECLPROC __gen_JettonDefaultWallet_init
DECLPROC __gen_JettonDefaultWallet_init_child
DECLPROC __gen_JettonDefaultWallet_get_wallet_data
97026 DECLMETHOD __gen_get_get_wallet_data
DECLPROC __gen_JettonDefaultWallet_receive_TokenTransfer
DECLPROC __gen_JettonDefaultWallet_receive_TokenTransferInternal
DECLPROC __gen_JettonDefaultWallet_receive_TokenBurn
DECLPROC __gen_JettonDefaultWallet_receive_bounced
DECLPROC $contractAddress
DECLPROC $send
DECLPROC $__gen_Context_readForwardFee
DECLPROC $__gen_JettonDefaultWallet_init
DECLPROC $__gen_JettonDefaultWallet_init_child
DECLPROC $__gen_JettonDefaultWallet_get_wallet_data
97026 DECLMETHOD $__gen_get_get_wallet_data
DECLPROC $__gen_JettonDefaultWallet_receive_TokenTransfer
DECLPROC $__gen_JettonDefaultWallet_receive_TokenTransferInternal
DECLPROC $__gen_JettonDefaultWallet_receive_TokenBurn
DECLPROC $__gen_JettonDefaultWallet_receive_bounced
DECLPROC recv_internal
111075 DECLMETHOD init_JettonDefaultWallet
113617 DECLMETHOD supported_interfaces
DECLPROC get_abi_ipfs
DECLGLOBVAR __tact_context
@ -63,7 +64,11 @@ PROGRAM{
SBITS
267 PUSHINT
NEQ
134 THROWIFNOT
136 THROWIFNOT
}>
__tact_store_bool PROCINLINE:<{
SWAP
1 STI
}>
__tact_load_address PROCINLINE:<{
LDMSGADDR
@ -96,34 +101,37 @@ PROGRAM{
__tact_store_address INLINECALLDICT
}>
}>
__tact_compute_contract_address PROC:<{
__tact_create_address PROCINLINE:<{
NEWC
0 PUSHINT
SWAP
2 STU
3 PUSHINT
2 PUSHINT
SWAP
2 STU
0 PUSHINT
SWAP
1 STU
s1 s2 XCHG
STREF
STREF
8 STI
256 STU
ENDC
HASHCU
CTOS
}>
__tact_compute_contract_address PROCINLINE:<{
NEWC
2 PUSHINT
0 PUSHINT
SWAP
2 STU
3 PUSHINT
SWAP
2 STU
0 PUSHINT
SWAP
1 STU
s1 s2 XCHG
8 STI
256 STU
STREF
STREF
ENDC
CTOS
HASHCU
__tact_create_address INLINECALLDICT
}>
__tact_address_eq PROCINLINE:<{
SDEQ
@ -142,9 +150,9 @@ PROGRAM{
16 PUSHINT
DICTUGETREF
NULLSWAPIFNOT
100 THROWIFNOT
135 THROWIFNOT
}>
__gen_read_TokenTransfer PROCINLINE:<{
__gen_read_TokenTransfer PROCREF:<{
32 LDU
SWAP
260734629 PUSHINT
@ -155,22 +163,23 @@ PROGRAM{
__tact_load_address INLINECALLDICT
SWAP
__tact_load_address_opt INLINECALLDICT
PUSHNULL
s0 s2 XCHG
SWAP
1 LDI
SWAP
IF:<{
1 2 BLKDROP2
LDREF
s1 s2 XCHG
}>ELSE<{
PUSHNULL
SWAP
}>
LDGRAMS
s6 s6 XCPU
s1 s6 XCHG
s1 s5 XCHG
s4 s4 s0 XCHG3
s1 s4 XCHG
s3 s3 s0 XCHG3
}>
__gen_write_TokenTransferInternal PROCINLINE:<{
__gen_write_TokenTransferInternal PROCREF:<{
395134233 PUSHINT
s0 s7 XCHG2
32 STU
@ -187,13 +196,13 @@ PROGRAM{
SWAP
STSLICER
}>
__gen_writecell_TokenTransferInternal PROCINLINE:<{
__gen_writecell_TokenTransferInternal PROCREF:<{
NEWC
6 -ROLL
__gen_write_TokenTransferInternal INLINECALLDICT
ENDC
}>
__gen_read_TokenTransferInternal PROCINLINE:<{
__gen_read_TokenTransferInternal PROCREF:<{
32 LDU
SWAP
395134233 PUSHINT
@ -211,7 +220,7 @@ PROGRAM{
s1 s4 XCHG
s3 s3 s0 XCHG3
}>
__gen_write_TokenNotification PROCINLINE:<{
__gen_write_TokenNotification PROCREF:<{
1935855772 PUSHINT
s0 s5 XCHG2
32 STU
@ -224,13 +233,13 @@ PROGRAM{
SWAP
STSLICER
}>
__gen_writecell_TokenNotification PROCINLINE:<{
__gen_writecell_TokenNotification PROCREF:<{
NEWC
4 -ROLL
__gen_write_TokenNotification INLINECALLDICT
ENDC
}>
__gen_read_TokenBurn PROCINLINE:<{
__gen_read_TokenBurn PROCREF:<{
32 LDU
SWAP
1499400124 PUSHINT
@ -244,7 +253,7 @@ PROGRAM{
s1 s4 XCHG
s3 s3 s0 XCHG3
}>
__gen_write_TokenBurnNotification PROCINLINE:<{
__gen_write_TokenBurnNotification PROCREF:<{
2078119902 PUSHINT
s0 s5 XCHG2
32 STU
@ -257,25 +266,25 @@ PROGRAM{
SWAP
__tact_store_address_opt INLINECALLDICT
}>
__gen_writecell_TokenBurnNotification PROCINLINE:<{
__gen_writecell_TokenBurnNotification PROCREF:<{
NEWC
4 -ROLL
__gen_write_TokenBurnNotification INLINECALLDICT
ENDC
}>
__gen_write_TokenExcesses PROCINLINE:<{
__gen_write_TokenExcesses PROCREF:<{
3576854235 PUSHINT
ROT
32 STU
64 STU
}>
__gen_writecell_TokenExcesses PROCINLINE:<{
__gen_writecell_TokenExcesses PROCREF:<{
NEWC
SWAP
__gen_write_TokenExcesses INLINECALLDICT
ENDC
}>
__gen_write_JettonDefaultWallet PROCINLINE:<{
__gen_write_JettonDefaultWallet PROCREF:<{
s2 s3 XCHG2
257 PUSHINT
STIX
@ -284,7 +293,7 @@ PROGRAM{
SWAP
__tact_store_address INLINECALLDICT
}>
__gen_read_JettonDefaultWallet PROCINLINE:<{
__gen_read_JettonDefaultWallet PROCREF:<{
257 PUSHINT
LDIX
__tact_load_address INLINECALLDICT
@ -295,7 +304,9 @@ PROGRAM{
__gen_StateInit_get_code PROCINLINE:<{
DROP
}>
__gen_load_JettonDefaultWallet PROCINLINE:<{
__gen_JettonWalletData_to_external PROC:<{
}>
__gen_load_JettonDefaultWallet PROCREF:<{
c4 PUSH
CTOS
LDREF
@ -304,7 +315,7 @@ PROGRAM{
__gen_read_JettonDefaultWallet INLINECALLDICT
1 3 BLKDROP2
}>
__gen_store_JettonDefaultWallet PROCINLINE:<{
__gen_store_JettonDefaultWallet PROCREF:<{
NEWC
__tact_context_sys GETGLOB
SWAP
@ -314,28 +325,18 @@ PROGRAM{
ENDC
c4 POP
}>
storeBool PROC:<{
IFJMP:<{
-1 PUSHINT
SWAP
1 STI
}>
0 PUSHINT
SWAP
1 STI
}>
contractAddress PROC:<{
$contractAddress PROC:<{
0 PUSHINT
-ROT
__tact_compute_contract_address CALLDICT
__tact_compute_contract_address INLINECALLDICT
}>
send PROC:<{
$send PROC:<{
NEWC
1 PUSHINT
SWAP
2 STI
s0 s7 XCHG2
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
0 PUSHINT
SWAP
3 STI
@ -355,18 +356,18 @@ PROGRAM{
OR
IF:<{
TRUE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
NEWC
FALSE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
FALSE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
s4 PUSH
ISNULL
NOT
IF:<{
TRUE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
s0 s4 XCHG
__tact_not_null CALLDICT
s0 s4 XCHG2
@ -375,14 +376,14 @@ PROGRAM{
s4 POP
s0 s3 XCHG
FALSE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
}>
s4 PUSH
ISNULL
NOT
IF:<{
TRUE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
s0 s4 XCHG
__tact_not_null CALLDICT
s0 s4 XCHG2
@ -391,13 +392,13 @@ PROGRAM{
s4 POP
s0 s3 XCHG
FALSE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
}>
FALSE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
s0 s2 XCHG
TRUE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
s0 s2 XCHG
ENDC
ROT
@ -407,14 +408,14 @@ PROGRAM{
s3 POP
SWAP
FALSE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
}>
OVER
ISNULL
NOT
IF:<{
TRUE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
SWAP
__tact_not_null CALLDICT
SWAP
@ -422,13 +423,13 @@ PROGRAM{
}>ELSE<{
NIP
FALSE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
}>
ENDC
SWAP
SENDRAWMSG
}>
__gen_Context_readForwardFee PROC:<{
$__gen_Context_readForwardFee PROC:<{
3 1 BLKDROP2
LDGRAMS
NIP
@ -441,7 +442,7 @@ PROGRAM{
3 MULCONST
1 RSHIFT#
}>
__gen_JettonDefaultWallet_init PROC:<{
$__gen_JettonDefaultWallet_init PROC:<{
0 PUSHINT
s0 s3 XCHG
NEWC
@ -450,39 +451,37 @@ PROGRAM{
__gen_write_JettonDefaultWallet INLINECALLDICT
ENDC
}>
__gen_JettonDefaultWallet_init_child PROC:<{
$__gen_JettonDefaultWallet_init_child PROC:<{
s0 s2 XCHG
CTOS
LDDICT
DROP
DUP
55471 PUSHINT
__tact_dict_get_code INLINECALLDICT
NEWDICT
s0 s2 XCHG
SWAP
55471 PUSHINT
__tact_dict_get_code INLINECALLDICT
s1 s2 XCHG
55471 PUSHINT
SWAP
55471 PUSHINT
s2 PUSH
__tact_dict_set_code INLINECALLDICT
NEWC
STDICT
ENDC
s0 s0 s3 XCHG3
__gen_JettonDefaultWallet_init CALLDICT
$__gen_JettonDefaultWallet_init CALLDICT
}>
__gen_JettonDefaultWallet_get_wallet_data PROC:<{
$__gen_JettonDefaultWallet_get_wallet_data PROC:<{
__tact_context_sys GETGLOB
s1 s2 PUSH2
__gen_JettonDefaultWallet_init_child CALLDICT
$__gen_JettonDefaultWallet_init_child CALLDICT
__gen_StateInit_get_code INLINECALLDICT
}>
__gen_get_get_wallet_data PROC:<{
$__gen_get_get_wallet_data PROC:<{
__gen_load_JettonDefaultWallet INLINECALLDICT
__gen_JettonDefaultWallet_get_wallet_data CALLDICT
$__gen_JettonDefaultWallet_get_wallet_data CALLDICT
__gen_JettonWalletData_to_external CALLDICT
}>
__gen_JettonDefaultWallet_receive_TokenTransfer PROC:<{
$__gen_JettonDefaultWallet_receive_TokenTransfer PROC:<{
2 2 BLKDROP2
__tact_context_get INLINECALLDICT
4429 PUSHINT
@ -497,7 +496,7 @@ PROGRAM{
THROWANYIFNOT
s3 s3 s0 XCHG3
s3 s11 PUXC
__gen_Context_readForwardFee CALLDICT
$__gen_Context_readForwardFee CALLDICT
1 PUSHINT
s4 PUSH
0 GTINT
@ -517,9 +516,9 @@ PROGRAM{
THROWANYIFNOT
__tact_context_sys GETGLOB
s0 s6 s3 XCPUXC
__gen_JettonDefaultWallet_init_child CALLDICT
$__gen_JettonDefaultWallet_init_child CALLDICT
2DUP
contractAddress CALLDICT
$contractAddress CALLDICT
TRUE
s7 s6 XCHG2
0 PUSHINT
@ -531,20 +530,20 @@ PROGRAM{
s5 s6 XCHG
s3 s4 XCHG
-ROT
send CALLDICT
$send CALLDICT
}>
__gen_JettonDefaultWallet_receive_TokenTransferInternal PROC:<{
$__gen_JettonDefaultWallet_receive_TokenTransferInternal PROC:<{
__tact_context_get INLINECALLDICT
s2 s10 PUSH2
__tact_address_neq INLINECALLDICT
IF:<{
__tact_context_sys GETGLOB
s11 s8 PUSH2
__gen_JettonDefaultWallet_init_child CALLDICT
$__gen_JettonDefaultWallet_init_child CALLDICT
SWAP
4429 PUSHINT
s0 s2 XCHG
contractAddress CALLDICT
$contractAddress CALLDICT
s4 PUSH
__tact_address_eq INLINECALLDICT
THROWANYIFNOT
@ -571,7 +570,7 @@ PROGRAM{
IF:<{
s4 s13 XCHG2
s3 s3 s0 XCHG3
__gen_Context_readForwardFee CALLDICT
$__gen_Context_readForwardFee CALLDICT
s3 s(-1) PUXC
ADD
s1 s10 XCHG
@ -588,7 +587,7 @@ PROGRAM{
s5 s5 XCHG2
PUSHNULL
PUSHNULL
send CALLDICT
$send CALLDICT
s0 s5 XCHG2
}>ELSE<{
s7 s13 XCHG
@ -613,13 +612,13 @@ PROGRAM{
s1 s7 XCHG
PUSHNULL
PUSHNULL
send CALLDICT
$send CALLDICT
}>ELSE<{
s5 POP
2DROP
}>
}>
__gen_JettonDefaultWallet_receive_TokenBurn PROC:<{
$__gen_JettonDefaultWallet_receive_TokenBurn PROC:<{
2DROP
__tact_context_get INLINECALLDICT
4429 PUSHINT
@ -634,7 +633,7 @@ PROGRAM{
THROWANYIFNOT
s3 s3 s0 XCHG3
s3 s8 PUXC
__gen_Context_readForwardFee CALLDICT
$__gen_Context_readForwardFee CALLDICT
16059 PUSHINT
SWAP
20000000 PUSHINT
@ -654,9 +653,9 @@ PROGRAM{
s3 s3 XCHG2
PUSHNULL
PUSHNULL
send CALLDICT
$send CALLDICT
}>
__gen_JettonDefaultWallet_receive_bounced PROC:<{
$__gen_JettonDefaultWallet_receive_bounced PROC:<{
32 PUSHINT
SDSKIPFIRST
32 LDU
@ -712,7 +711,7 @@ PROGRAM{
DROP
__gen_load_JettonDefaultWallet INLINECALLDICT
3 ROLL
__gen_JettonDefaultWallet_receive_bounced CALLDICT
$__gen_JettonDefaultWallet_receive_bounced CALLDICT
__gen_store_JettonDefaultWallet INLINECALLDICT
}>
DUP
@ -727,7 +726,7 @@ PROGRAM{
s8 s9 XCHG
s7 s8 XCHG
6 ROLL
__gen_JettonDefaultWallet_receive_TokenTransfer CALLDICT
$__gen_JettonDefaultWallet_receive_TokenTransfer CALLDICT
__gen_store_JettonDefaultWallet INLINECALLDICT
}>
DUP
@ -742,7 +741,7 @@ PROGRAM{
s7 s8 XCHG
s6 s7 XCHG
5 ROLL
__gen_JettonDefaultWallet_receive_TokenTransferInternal CALLDICT
$__gen_JettonDefaultWallet_receive_TokenTransferInternal CALLDICT
__gen_store_JettonDefaultWallet INLINECALLDICT
}>
1499400124 PUSHINT
@ -755,21 +754,18 @@ PROGRAM{
s5 s6 XCHG
s4 s5 XCHG
3 ROLL
__gen_JettonDefaultWallet_receive_TokenBurn CALLDICT
$__gen_JettonDefaultWallet_receive_TokenBurn CALLDICT
__gen_store_JettonDefaultWallet INLINECALLDICT
}>
DROP
130 THROW
}>
init_JettonDefaultWallet PROC:<{
__gen_JettonDefaultWallet_init CALLDICT
}>
supported_interfaces PROC:<{
123515602279859691144772641439386770278 PUSHINT
209801025412363888721030803524359905849 PUSHINT
209778528950190195973528115415557644819 PUSHINT
}>
get_abi_ipfs PROC:<{
x{697066733a2f2f516d645055594d3637535178506869536967344c565733726a71634b67456365365347765270336f5a5258454d31} PUSHSLICE
x{697066733a2f2f516d5842667162517a654e31755435354d7959707768553952563437537133717556743371464c675748384e6844} PUSHSLICE
}>
}END>c

241
sources/output/jetton_JettonDefaultWallet.rev.fif → sources/output/jetton_JettonDefaultWallet.code.rev.fif

@ -34,11 +34,13 @@ SETCP0
s0 s2 XCHG
<{
s0 POP
<{
c4 PUSH
CTOS
LDREF
s0 s1 XCHG
2 SETGLOBVAR
<{
257 PUSHINT
LDI
LDMSGADDR
@ -47,14 +49,18 @@ SETCP0
LDMSGADDR
s0 s1 XCHG
s3 s3 s0 XCHG3
}> CALLREF
1 3 BLKDROP2
}> CALLREF
1 3 BLKSWAP
40 CALLDICT
42 CALLDICT
<{
NEWC
2 GETGLOBVAR
s0 s1 XCHG
STREF
3 1 BLKSWAP
<{
s2 s3 XCHG2
257 PUSHINT
STIX
@ -62,8 +68,10 @@ SETCP0
STSLICER
s0 s1 XCHG
STSLICER
}> CALLREF
ENDC
c4 POP
}> CALLREF
}> PUSHCONT
IFJMP
s0 PUSH
@ -71,11 +79,13 @@ SETCP0
EQUAL
<{
s0 POP
<{
c4 PUSH
CTOS
LDREF
s0 s1 XCHG
2 SETGLOBVAR
<{
257 PUSHINT
LDI
LDMSGADDR
@ -84,8 +94,11 @@ SETCP0
LDMSGADDR
s0 s1 XCHG
s3 s3 s0 XCHG3
}> CALLREF
1 3 BLKDROP2
}> CALLREF
s0 s3 XCHG
<{
32 LDU
s0 s1 XCHG
260734629 PUSHINT
@ -108,31 +121,36 @@ SETCP0
PUSHNULL
}> PUSHCONT
IFELSE
PUSHNULL
s0 s2 XCHG
s0 s1 XCHG
1 LDI
s0 s1 XCHG
<{
1 2 BLKDROP2
LDREF
s1 s2 XCHG
}> PUSHCONT
IF
<{
PUSHNULL
s0 s1 XCHG
}> PUSHCONT
IFELSE
LDGRAMS
s6 s6 XCPU
s1 s6 XCHG
s1 s5 XCHG
s4 s4 s0 XCHG3
s1 s4 XCHG
s3 s3 s0 XCHG3
}> CALLREF
s7 POP
s8 s9 XCHG
s7 s8 XCHG
1 6 BLKSWAP
37 CALLDICT
39 CALLDICT
<{
NEWC
2 GETGLOBVAR
s0 s1 XCHG
STREF
3 1 BLKSWAP
<{
s2 s3 XCHG2
257 PUSHINT
STIX
@ -140,19 +158,23 @@ SETCP0
STSLICER
s0 s1 XCHG
STSLICER
}> CALLREF
ENDC
c4 POP
}> CALLREF
}> IFJMPREF
s0 PUSH
395134233 PUSHINT
EQUAL
<{
s0 POP
<{
c4 PUSH
CTOS
LDREF
s0 s1 XCHG
2 SETGLOBVAR
<{
257 PUSHINT
LDI
LDMSGADDR
@ -161,8 +183,11 @@ SETCP0
LDMSGADDR
s0 s1 XCHG
s3 s3 s0 XCHG3
}> CALLREF
1 3 BLKDROP2
}> CALLREF
s0 s3 XCHG
<{
32 LDU
s0 s1 XCHG
395134233 PUSHINT
@ -191,16 +216,19 @@ SETCP0
s1 s5 XCHG
s1 s4 XCHG
s3 s3 s0 XCHG3
}> CALLREF
s6 POP
s7 s8 XCHG
s6 s7 XCHG
1 5 BLKSWAP
38 CALLDICT
40 CALLDICT
<{
NEWC
2 GETGLOBVAR
s0 s1 XCHG
STREF
3 1 BLKSWAP
<{
s2 s3 XCHG2
257 PUSHINT
STIX
@ -208,17 +236,22 @@ SETCP0
STSLICER
s0 s1 XCHG
STSLICER
}> CALLREF
ENDC
c4 POP
}> IFJMPREF
}> CALLREF
}> PUSHCONT
IFJMP
1499400124 PUSHINT
EQUAL
<{
<{
c4 PUSH
CTOS
LDREF
s0 s1 XCHG
2 SETGLOBVAR
<{
257 PUSHINT
LDI
LDMSGADDR
@ -227,8 +260,11 @@ SETCP0
LDMSGADDR
s0 s1 XCHG
s3 s3 s0 XCHG3
}> CALLREF
1 3 BLKDROP2
}> CALLREF
s0 s3 XCHG
<{
32 LDU
s0 s1 XCHG
1499400124 PUSHINT
@ -253,16 +289,19 @@ SETCP0
IFELSE
s1 s4 XCHG
s3 s3 s0 XCHG3
}> CALLREF
s4 POP
s5 s6 XCHG
s4 s5 XCHG
1 3 BLKSWAP
39 CALLDICT
41 CALLDICT
<{
NEWC
2 GETGLOBVAR
s0 s1 XCHG
STREF
3 1 BLKSWAP
<{
s2 s3 XCHG2
257 PUSHINT
STIX
@ -270,9 +309,12 @@ SETCP0
STSLICER
s0 s1 XCHG
STSLICER
}> CALLREF
ENDC
c4 POP
}> IFJMPREF
}> CALLREF
}> PUSHCONT
IFJMP
s0 POP
130 THROW
@ -281,7 +323,11 @@ SETCP0
ISNULL
128 THROWIF
9:
30:
33:
0 PUSHINT
ROTREV
NEWC
0 PUSHINT
s0 s1 XCHG
@ -310,29 +356,14 @@ SETCP0
ENDC
CTOS
30:
<{
-1 PUSHINT
s0 s1 XCHG
1 STI
}> PUSHCONT
IFJMP
0 PUSHINT
s0 s1 XCHG
1 STI
31:
0 PUSHINT
ROTREV
9 CALLDICT
32:
34:
NEWC
1 PUSHINT
s0 s1 XCHG
2 STI
s0 s7 XCHG2
30 CALLDICT
s0 s1 XCHG
1 STI
0 PUSHINT
s0 s1 XCHG
3 STI
@ -352,18 +383,22 @@ SETCP0
OR
<{
-1 PUSHINT
30 CALLDICT
s0 s1 XCHG
1 STI
NEWC
0 PUSHINT
30 CALLDICT
s0 s1 XCHG
1 STI
0 PUSHINT
30 CALLDICT
s0 s1 XCHG
1 STI
s4 PUSH
ISNULL
NOT
<{
-1 PUSHINT
30 CALLDICT
s0 s1 XCHG
1 STI
s0 s4 XCHG
2 CALLDICT
s0 s4 XCHG2
@ -373,7 +408,8 @@ SETCP0
s4 POP
s0 s3 XCHG
0 PUSHINT
30 CALLDICT
s0 s1 XCHG
1 STI
}> PUSHCONT
IFELSE
s4 PUSH
@ -381,7 +417,8 @@ SETCP0
NOT
<{
-1 PUSHINT
30 CALLDICT
s0 s1 XCHG
1 STI
s0 s4 XCHG
2 CALLDICT
s0 s4 XCHG2
@ -391,14 +428,17 @@ SETCP0
s4 POP
s0 s3 XCHG
0 PUSHINT
30 CALLDICT
s0 s1 XCHG
1 STI
}> PUSHCONT
IFELSE
0 PUSHINT
30 CALLDICT
s0 s1 XCHG
1 STI
s0 s2 XCHG
-1 PUSHINT
30 CALLDICT
s0 s1 XCHG
1 STI
s0 s2 XCHG
ENDC
ROT
@ -409,7 +449,8 @@ SETCP0
s3 POP
s0 s1 XCHG
0 PUSHINT
30 CALLDICT
s0 s1 XCHG
1 STI
}> PUSHCONT
IFELSE
s1 PUSH
@ -417,23 +458,22 @@ SETCP0
NOT
<{
-1 PUSHINT
30 CALLDICT
s0 s1 XCHG
1 STI
s0 s1 XCHG
2 CALLDICT
s0 s1 XCHG
STREF
}> PUSHCONT
<{
s1 POP
0 PUSHINT
30 CALLDICT
}> PUSHCONT
IFELSE
}> IFREFELSEREF
ENDC
s0 s1 XCHG
SENDRAWMSG
s1 POP
0 PUSHINT
s0 s1 XCHG
1 STI
33:
35:
3 1 BLKDROP2
LDGRAMS
s1 POP
@ -446,12 +486,13 @@ SETCP0
3 MULCONST
1 RSHIFT
34:
36:
0 PUSHINT
s0 s3 XCHG
NEWC
STREF
s3 s1 s3 XCHG3
<{
s2 s3 XCHG2
257 PUSHINT
STIX
@ -459,31 +500,25 @@ SETCP0
STSLICER
s0 s1 XCHG
STSLICER
}> CALLREF
ENDC
35:
37:
s0 s2 XCHG
CTOS
LDDICT
s0 POP
s0 PUSH
55471 PUSHINT
s0 s1 XCHG
16 PUSHINT
DICTUGETREF
NULLSWAPIFNOT
100 THROWIFNOT
PUSHNULL
s0 s2 XCHG
s0 s1 XCHG
55471 PUSHINT
s0 s1 XCHG
16 PUSHINT
DICTUGETREF
NULLSWAPIFNOT
100 THROWIFNOT
s1 s2 XCHG
55471 PUSHINT
135 THROWIFNOT
s0 s1 XCHG
55471 PUSHINT
s2 PUSH
s0 s2 XCHG
16 PUSHINT
DICTUSETREF
@ -491,15 +526,15 @@ SETCP0
STDICT
ENDC
s0 s0 s3 XCHG3
34 CALLDICT
36 CALLDICT
36:
38:
2 GETGLOBVAR
s1 s2 PUSH2
35 CALLDICT
37 CALLDICT
s0 POP
37:
39:
2 2 BLKDROP2
1 GETGLOBVAR
4 UNTUPLE
@ -515,7 +550,7 @@ SETCP0
THROWANYIFNOT
s3 s3 s0 XCHG3
s3 s11 PUXC
33 CALLDICT
35 CALLDICT
1 PUSHINT
s4 PUSH
0 GTINT
@ -536,9 +571,9 @@ SETCP0
THROWANYIFNOT
2 GETGLOBVAR
0 6 3 XCPUXC
35 CALLDICT
37 CALLDICT
2DUP
31 CALLDICT
33 CALLDICT
-1 PUSHINT
s7 s6 XCHG2
0 PUSHINT
@ -546,8 +581,10 @@ SETCP0
s11 PUSH
12 2 8 PUXC2
s1 s8 XCHG
<{
NEWC
6 1 BLKSWAP
<{
395134233 PUSHINT
s0 s7 XCHG2
32 STU
@ -574,13 +611,15 @@ SETCP0
STGRAMS
s0 s1 XCHG
STSLICER
}> CALLREF
ENDC
}> CALLREF
s5 s6 XCHG
s3 s4 XCHG
ROTREV
32 CALLDICT
34 CALLDICT
38:
40:
1 GETGLOBVAR
4 UNTUPLE
s2 s10 PUSH2
@ -589,11 +628,11 @@ SETCP0
<{
2 GETGLOBVAR
s11 s8 PUSH2
35 CALLDICT
37 CALLDICT
s0 s1 XCHG
4429 PUSHINT
s0 s2 XCHG
31 CALLDICT
33 CALLDICT
s4 PUSH
SDEQ
THROWANYIFNOT
@ -619,15 +658,10 @@ SETCP0
SUB
s6 PUSH
0 GTINT
<{
s7 s13 XCHG
s8 s9 XCHG2
8 BLKDROP
}> PUSHCONT
<{
s4 s13 XCHG2
s3 s3 s0 XCHG3
33 CALLDICT
35 CALLDICT
s3 s-1 PUXC
ADD
s1 s10 XCHG
@ -637,8 +671,10 @@ SETCP0
s8 PUSH
s8 s1 s3 XCHG3
s7 s4 XCHG2
<{
NEWC
4 1 BLKSWAP
<{
1935855772 PUSHINT
s0 s5 XCHG2
32 STU
@ -650,16 +686,24 @@ SETCP0
STSLICER
s0 s1 XCHG
STSLICER
}> CALLREF
ENDC
}> CALLREF
s8 PUSH
s4 s6 XCHG
s3 s1 s3 XCHG3
s5 s5 XCHG2
PUSHNULL
PUSHNULL
32 CALLDICT
34 CALLDICT
s0 s5 XCHG2
}> IFREFELSE
}> PUSHCONT
<{
s7 s13 XCHG
s8 s9 XCHG2
8 BLKDROP
}> PUSHCONT
IFELSE
s5 PUSH
ISNULL
NOT
@ -672,27 +716,28 @@ SETCP0
2 CALLDICT
0 PUSHINT
s0 s4 XCHG
<{
NEWC
s0 s1 XCHG
<{
3576854235 PUSHINT
ROT
32 STU
64 STU
}> CALLREF
ENDC
}> CALLREF
s4 s7 XCHG
s3 s3 s0 XCHG3
s1 s7 XCHG
PUSHNULL
PUSHNULL
32 CALLDICT
}> PUSHCONT
<{
34 CALLDICT
}> IFREFELSEREF
s5 POP
2DROP
}> PUSHCONT
IFELSE
39:
41:
2DROP
1 GETGLOBVAR
4 UNTUPLE
@ -708,7 +753,7 @@ SETCP0
THROWANYIFNOT
s3 s3 s0 XCHG3
s3 s8 PUXC
33 CALLDICT
35 CALLDICT
16059 PUSHINT
s0 s1 XCHG
20000000 PUSHINT
@ -723,8 +768,10 @@ SETCP0
s0 s3 XCHG
64 PUSHINT
3 6 6 XCPU2
<{
NEWC
4 1 BLKSWAP
<{
2078119902 PUSHINT
s0 s5 XCHG2
32 STU
@ -747,14 +794,16 @@ SETCP0
STSLICER
}> PUSHCONT
IFELSE
}> CALLREF
ENDC
}> CALLREF
3 0 4 XC2PU
s3 s3 XCHG2
PUSHNULL
PUSHNULL
32 CALLDICT
34 CALLDICT
40:
42:
32 PUSHINT
SDSKIPFIRST
32 LDU
@ -778,11 +827,13 @@ SETCP0
s0 s2 XCHG
get_wallet_data:
<{
c4 PUSH
CTOS
LDREF
s0 s1 XCHG
2 SETGLOBVAR
<{
257 PUSHINT
LDI
LDMSGADDR
@ -791,11 +842,11 @@ SETCP0
LDMSGADDR
s0 s1 XCHG
s3 s3 s0 XCHG3
}> CALLREF
1 3 BLKDROP2
36 CALLDICT
111075:
34 CALLDICT
}> CALLREF
38 CALLDICT
30 CALLDICT
113617:
123515602279859691144772641439386770278 PUSHINT

BIN
sources/output/jetton_JettonDefaultWallet.init.boc

Binary file not shown.

37
sources/output/jetton_JettonDefaultWallet.init.fc

@ -0,0 +1,37 @@
() __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 __gen_write_JettonDefaultWallet(builder build_0, (int, slice, slice) v) inline_ref {
var (v'balance, v'owner, v'master) = v;
build_0 = build_0.store_int(v'balance, 257);
build_0 = __tact_store_address(build_0, v'owner);
build_0 = __tact_store_address(build_0, v'master);
return build_0;
}
cell $__gen_JettonDefaultWallet_init(cell sys', slice $master, slice $owner) {
var (($self'balance, $self'owner, $self'master)) = (null(), null(), null());
$self'balance = 0;
$self'owner = $owner;
$self'master = $master;
var b' = begin_cell();
b' = b'.store_ref(sys');
b' = __gen_write_JettonDefaultWallet(b', ($self'balance, $self'owner, $self'master));
return b'.end_cell();
}
cell init(cell sys', slice $$master, slice $$owner) method_id {
slice $master = $$master;
slice $owner = $$owner;
return $__gen_JettonDefaultWallet_init(sys', $master, $owner);
}
() main() {
}

40
sources/output/jetton_JettonDefaultWallet.init.fif

@ -0,0 +1,40 @@
PROGRAM{
DECLPROC __tact_verify_address
DECLPROC __tact_store_address
DECLPROC __gen_write_JettonDefaultWallet
DECLPROC $__gen_JettonDefaultWallet_init
107886 DECLMETHOD init
DECLPROC main
__tact_verify_address PROCINLINE:<{
SBITS
267 PUSHINT
NEQ
136 THROWIFNOT
}>
__tact_store_address PROCINLINE:<{
STSLICER
}>
__gen_write_JettonDefaultWallet PROCREF:<{
s2 s3 XCHG2
257 PUSHINT
STIX
SWAP
__tact_store_address INLINECALLDICT
SWAP
__tact_store_address INLINECALLDICT
}>
$__gen_JettonDefaultWallet_init PROC:<{
0 PUSHINT
s0 s3 XCHG
NEWC
STREF
s3 s1 s3 XCHG3
__gen_write_JettonDefaultWallet INLINECALLDICT
ENDC
}>
init PROC:<{
$__gen_JettonDefaultWallet_init CALLDICT
}>
main PROC:<{
}>
}END>c

26
sources/output/jetton_JettonDefaultWallet.init.rev.fif

@ -0,0 +1,26 @@
SETCP0
(:methods
recv_internal:
4:
0 PUSHINT
s0 s3 XCHG
NEWC
STREF
s3 s1 s3 XCHG3
<{
s2 s3 XCHG2
257 PUSHINT
STIX
s0 s1 XCHG
STSLICER
s0 s1 XCHG
STSLICER
}> CALLREF
ENDC
107886:
4 CALLDICT
) 19 DICTPUSHCONST
DICTIGETJMPZ
11 THROWARG

67
sources/output/jetton_JettonDefaultWallet.md

@ -0,0 +1,67 @@
# TACT Compilation Report
Contract: JettonDefaultWallet
BOC Size: 1321 bytes
# Types
Total Types: 14
## StateInit
TLB: `_ code:^cell data:^cell = StateInit`
Signature: `StateInit{code:^cell,data:^cell}`
## Context
TLB: `_ bounced:bool sender:address value:int257 raw:^slice = Context`
Signature: `Context{bounced:bool,sender:address,value:int257,raw:^slice}`
## SendParameters
TLB: `_ bounce:bool to:address value:int257 mode:int257 body:Maybe ^cell code:Maybe ^cell data:Maybe ^cell = SendParameters`
Signature: `SendParameters{bounce:bool,to:address,value:int257,mode:int257,body:Maybe ^cell,code:Maybe ^cell,data:Maybe ^cell}`
## ChangeOwner
TLB: `change_owner#0f474d03 newOwner:address = ChangeOwner`
Signature: `ChangeOwner{newOwner:address}`
## TokenTransfer
TLB: `token_transfer#0f8a7ea5 queryId:uint64 amount:coins destination:address responseDestination:Maybe address customPayload:Maybe ^cell forwardTonAmount:coins forwardPayload:remainder<slice> = TokenTransfer`
Signature: `TokenTransfer{queryId:uint64,amount:coins,destination:address,responseDestination:Maybe address,customPayload:Maybe ^cell,forwardTonAmount:coins,forwardPayload:remainder<slice>}`
## TokenTransferInternal
TLB: `token_transfer_internal#178d4519 queryId:uint64 amount:coins from:address responseAddress:Maybe address forwardTonAmount:coins forwardPayload:remainder<slice> = TokenTransferInternal`
Signature: `TokenTransferInternal{queryId:uint64,amount:coins,from:address,responseAddress:Maybe address,forwardTonAmount:coins,forwardPayload:remainder<slice>}`
## TokenNotification
TLB: `token_notification#7362d09c queryId:uint64 amount:coins from:address forwardPayload:remainder<slice> = TokenNotification`
Signature: `TokenNotification{queryId:uint64,amount:coins,from:address,forwardPayload:remainder<slice>}`
## TokenBurn
TLB: `token_burn#595f07bc queryId:uint64 amount:coins owner:address responseAddress:Maybe address = TokenBurn`
Signature: `TokenBurn{queryId:uint64,amount:coins,owner:address,responseAddress:Maybe address}`
## TokenBurnNotification
TLB: `token_burn_notification#7bdd97de queryId:uint64 amount:coins owner:address responseAddress:Maybe address = TokenBurnNotification`
Signature: `TokenBurnNotification{queryId:uint64,amount:coins,owner:address,responseAddress:Maybe address}`
## TokenExcesses
TLB: `token_excesses#d53276db queryId:uint64 = TokenExcesses`
Signature: `TokenExcesses{queryId:uint64}`
## TokenUpdateContent
TLB: `token_update_content#0c087a9e content:Maybe ^cell = TokenUpdateContent`
Signature: `TokenUpdateContent{content:Maybe ^cell}`
## JettonData
TLB: `_ totalSupply:int257 mintable:bool owner:address content:Maybe ^cell walletCode:^cell = JettonData`
Signature: `JettonData{totalSupply:int257,mintable:bool,owner:address,content:Maybe ^cell,walletCode:^cell}`
## JettonWalletData
TLB: `_ balance:int257 owner:address master:address walletCode:^cell = JettonWalletData`
Signature: `JettonWalletData{balance:int257,owner:address,master:address,walletCode:^cell}`
## Mint
TLB: `mint#01fb345b amount:int257 = Mint`
Signature: `Mint{amount:int257}`
# Get Methods
Total Get Methods: 1
## get_wallet_data

1
sources/output/jetton_JettonDefaultWallet.pkg

File diff suppressed because one or more lines are too long

1301
sources/output/jetton_JettonDefaultWallet.ts

File diff suppressed because it is too large Load Diff

1329
sources/output/jetton_SampleJetton.abi

File diff suppressed because one or more lines are too long

1
sources/output/jetton_SampleJetton.abi.ipfs

File diff suppressed because one or more lines are too long

BIN
sources/output/jetton_SampleJetton.boc

Binary file not shown.

BIN
sources/output/jetton_SampleJetton.code.boc

Binary file not shown.

248
sources/output/jetton_SampleJetton.fc → sources/output/jetton_SampleJetton.code.fc

@ -6,7 +6,12 @@ global cell __tact_context_sys;
(int, slice, int, slice) __tact_context_get() inline { return __tact_context; }
() __tact_verify_address(slice address) inline {
throw_unless(134, address.slice_bits() != 267);
throw_unless(136, address.slice_bits() != 267);
}
builder __tact_store_bool(builder b, int v) inline {
b = b.store_int(v, 1);
return b;
}
(slice, slice) __tact_load_address(slice cs) inline {
@ -40,7 +45,16 @@ builder __tact_store_address_opt(builder b, slice address) inline {
}
}
slice __tact_compute_contract_address(int chain, cell code, cell data) {
slice __tact_create_address(int chain, int hash) inline {
var b = begin_cell();
b = b.store_uint(2, 2);
b = b.store_uint(0, 1);
b = b.store_int(chain, 8);
b = b.store_uint(hash, 256);
return b.end_cell().begin_parse();
}
slice __tact_compute_contract_address(int chain, cell code, cell data) inline {
var b = begin_cell();
b = b.store_uint(0, 2);
b = b.store_uint(3, 2);
@ -48,12 +62,7 @@ slice __tact_compute_contract_address(int chain, cell code, cell data) {
b = b.store_ref(code);
b = b.store_ref(data);
var hash = cell_hash(b.end_cell());
var b2 = begin_cell();
b2 = b2.store_uint(2, 2);
b2 = b2.store_uint(0, 1);
b2 = b2.store_int(chain, 8);
b2 = b2.store_uint(hash, 256);
return b2.end_cell().begin_parse();
return __tact_create_address(chain, hash);
}
int __tact_address_eq(slice a, slice b) inline {
@ -66,27 +75,27 @@ cell __tact_dict_set_code(cell dict, int id, cell code) inline {
cell __tact_dict_get_code(cell dict, int id) inline {
var (data, ok) = udict_get_ref?(dict, 16, id);
throw_unless(100, ok);
throw_unless(135, ok);
return data;
}
builder __gen_write_TokenTransferInternal(builder build_0, (int, int, slice, slice, int, slice) v) inline {
builder __gen_write_TokenTransferInternal(builder build_0, (int, int, slice, slice, int, slice) v) inline_ref {
var (v'queryId, v'amount, v'from, v'responseAddress, v'forwardTonAmount, v'forwardPayload) = v;
build_0 = store_uint(build_0, 395134233, 32);
build_0 = store_uint(build_0, v'queryId, 64);
build_0 = store_coins(build_0, v'amount);
build_0 = build_0.store_uint(v'queryId, 64);
build_0 = build_0.store_coins(v'amount);
build_0 = __tact_store_address(build_0, v'from);
build_0 = __tact_store_address_opt(build_0, v'responseAddress);
build_0 = store_coins(build_0, v'forwardTonAmount);
build_0 = store_slice(build_0, v'forwardPayload);
build_0 = build_0.store_coins(v'forwardTonAmount);
build_0 = build_0.store_slice(v'forwardPayload);
return build_0;
}
cell __gen_writecell_TokenTransferInternal((int, int, slice, slice, int, slice) v) inline {
cell __gen_writecell_TokenTransferInternal((int, int, slice, slice, int, slice) v) inline_ref {
return __gen_write_TokenTransferInternal(begin_cell(), v).end_cell();
}
(slice, ((int, int, slice, slice))) __gen_read_TokenBurnNotification(slice sc_0) inline {
(slice, ((int, int, slice, slice))) __gen_read_TokenBurnNotification(slice sc_0) inline_ref {
throw_unless(129, sc_0~load_uint(32) == 2078119902);
var v'queryId = sc_0~load_uint(64);
var v'amount = sc_0~load_coins();
@ -95,61 +104,50 @@ cell __gen_writecell_TokenTransferInternal((int, int, slice, slice, int, slice)
return (sc_0, (v'queryId, v'amount, v'owner, v'responseAddress));
}
builder __gen_write_TokenExcesses(builder build_0, (int) v) inline {
builder __gen_write_TokenExcesses(builder build_0, (int) v) inline_ref {
var (v'queryId) = v;
build_0 = store_uint(build_0, 3576854235, 32);
build_0 = store_uint(build_0, v'queryId, 64);
build_0 = build_0.store_uint(v'queryId, 64);
return build_0;
}
cell __gen_writecell_TokenExcesses((int) v) inline {
cell __gen_writecell_TokenExcesses((int) v) inline_ref {
return __gen_write_TokenExcesses(begin_cell(), v).end_cell();
}
(slice, ((cell))) __gen_read_TokenUpdateContent(slice sc_0) inline {
throw_unless(129, sc_0~load_uint(32) == 1862840892);
var v'content = null();
if (sc_0~load_int(1)) {
v'content = sc_0~load_ref();
}
(slice, ((cell))) __gen_read_TokenUpdateContent(slice sc_0) inline_ref {
throw_unless(129, sc_0~load_uint(32) == 201882270);
var v'content = sc_0~load_int(1) ? sc_0~load_ref() : null();
return (sc_0, (v'content));
}
(slice, ((int))) __gen_read_Mint(slice sc_0) inline {
throw_unless(129, sc_0~load_uint(32) == 2737462367);
(slice, ((int))) __gen_read_Mint(slice sc_0) inline_ref {
throw_unless(129, sc_0~load_uint(32) == 33240155);
var v'amount = sc_0~load_int(257);
return (sc_0, (v'amount));
}
builder __gen_write_JettonDefaultWallet(builder build_0, (int, slice, slice) v) inline {
builder __gen_write_JettonDefaultWallet(builder build_0, (int, slice, slice) v) inline_ref {
var (v'balance, v'owner, v'master) = v;
build_0 = store_int(build_0, v'balance, 257);
build_0 = build_0.store_int(v'balance, 257);
build_0 = __tact_store_address(build_0, v'owner);
build_0 = __tact_store_address(build_0, v'master);
return build_0;
}
builder __gen_write_SampleJetton(builder build_0, (int, slice, cell, int) v) inline {
builder __gen_write_SampleJetton(builder build_0, (int, slice, cell, int) v) inline_ref {
var (v'totalSupply, v'owner, v'content, v'mintable) = v;
build_0 = store_coins(build_0, v'totalSupply);
build_0 = build_0.store_coins(v'totalSupply);
build_0 = __tact_store_address(build_0, v'owner);
if (null?(v'content)) {
build_0 = store_int(build_0, false, 1);
} else {
build_0 = store_int(build_0, true, 1);
build_0 = store_ref(build_0, v'content);
}
build_0 = store_int(build_0, v'mintable, 1);
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);
return build_0;
}
(slice, ((int, slice, cell, int))) __gen_read_SampleJetton(slice sc_0) inline {
(slice, ((int, slice, cell, int))) __gen_read_SampleJetton(slice sc_0) inline_ref {
var v'totalSupply = sc_0~load_coins();
var v'owner = sc_0~__tact_load_address();
var v'content = null();
if (sc_0~load_int(1)) {
v'content = sc_0~load_ref();
}
var v'content = sc_0~load_int(1) ? sc_0~load_ref() : null();
var v'mintable = sc_0~load_int(1);
return (sc_0, (v'totalSupply, v'owner, v'content, v'mintable));
}
@ -164,89 +162,86 @@ _ __gen_Context_get_sender((int, slice, int, slice) v) inline {
return v'sender;
}
(int, slice, cell, int) __gen_load_SampleJetton() inline {
(int, int, slice, cell, cell) __gen_JettonData_to_external(((int, int, slice, cell, cell)) v) {
var (v'totalSupply, v'mintable, v'owner, v'content, v'walletCode) = v;
return (v'totalSupply, v'mintable, v'owner, v'content, v'walletCode);
}
(int, slice, cell, int) __gen_load_SampleJetton() inline_ref {
slice sc = get_data().begin_parse();
__tact_context_sys = sc~load_ref();
return sc~__gen_read_SampleJetton();
}
() __gen_store_SampleJetton((int, slice, cell, int) v) impure inline {
() __gen_store_SampleJetton((int, slice, cell, int) v) impure inline_ref {
builder b = begin_cell();
b = b.store_ref(__tact_context_sys);
b = __gen_write_SampleJetton(b, v);
set_data(b.end_cell());
}
builder storeBool(builder $s, int $value) impure {
if ($value) {
return store_int($s, (- 1), 1);
} else {
return store_int($s, 0, 1);
}
}
cell emptyCell() impure {
cell $emptyCell() impure {
return end_cell(begin_cell());
}
slice __gen_Cell_asSlice(cell $self) impure {
slice $__gen_Cell_asSlice(cell $self) impure {
var ($self) = $self;
return begin_parse($self);
}
slice emptySlice() impure {
return __gen_Cell_asSlice(emptyCell());
slice $emptySlice() impure {
return $__gen_Cell_asSlice($emptyCell());
}
slice contractAddress((cell, cell) $s) impure {
slice $contractAddress((cell, cell) $s) impure {
var (($s'code, $s'data)) = $s;
return __tact_compute_contract_address(0, $s'code, $s'data);
}
() send((int, slice, int, int, cell, cell, cell) $params) impure {
() $send((int, slice, int, int, cell, cell, cell) $params) impure {
var (($params'bounce, $params'to, $params'value, $params'mode, $params'body, $params'code, $params'data)) = $params;
builder $b = begin_cell();
$b = store_int($b, 1, 2);
$b = storeBool($b, $params'bounce);
$b = __tact_store_bool($b, $params'bounce);
$b = store_int($b, 0, 3);
$b = __tact_store_address($b, $params'to);
$b = store_coins($b, $params'value);
$b = store_int($b, 0, ((((1 + 4) + 4) + 64) + 32));
if (((~ null?($params'code)) | (~ null?($params'data)))) {
$b = storeBool($b, true);
$b = __tact_store_bool($b, true);
builder $bc = begin_cell();
$bc = storeBool($bc, false);
$bc = storeBool($bc, false);
$bc = __tact_store_bool($bc, false);
$bc = __tact_store_bool($bc, false);
if ((~ null?($params'code))) {
$bc = storeBool($bc, true);
$bc = __tact_store_bool($bc, true);
$bc = store_ref($bc, __tact_not_null($params'code));
} else {
$bc = storeBool($bc, false);
$bc = __tact_store_bool($bc, false);
}
if ((~ null?($params'data))) {
$bc = storeBool($bc, true);
$bc = __tact_store_bool($bc, true);
$bc = store_ref($bc, __tact_not_null($params'data));
} else {
$bc = storeBool($bc, false);
$bc = __tact_store_bool($bc, false);
}
$bc = storeBool($bc, false);
$b = storeBool($b, true);
$bc = __tact_store_bool($bc, false);
$b = __tact_store_bool($b, true);
$b = store_ref($b, end_cell($bc));
} else {
$b = storeBool($b, false);
$b = __tact_store_bool($b, false);
}
cell $body = $params'body;
if ((~ null?($body))) {
$b = storeBool($b, true);
$b = __tact_store_bool($b, true);
$b = store_ref($b, __tact_not_null($body));
} else {
$b = storeBool($b, false);
$b = __tact_store_bool($b, false);
}
cell $c = end_cell($b);
send_raw_message($c, $params'mode);
}
cell __gen_JettonDefaultWallet_init(cell sys', slice $master, slice $owner) {
cell $__gen_JettonDefaultWallet_init(cell sys', slice $master, slice $owner) {
var (($self'balance, $self'owner, $self'master)) = (null(), null(), null());
$self'balance = 0;
$self'owner = $owner;
@ -257,121 +252,112 @@ cell __gen_JettonDefaultWallet_init(cell sys', slice $master, slice $owner) {
return b'.end_cell();
}
(cell, cell) __gen_JettonDefaultWallet_init_child(cell sys', slice $master, slice $owner) {
(cell, cell) $__gen_JettonDefaultWallet_init_child(cell sys', slice $master, slice $owner) {
slice sc' = sys'.begin_parse();
cell source = sc'~load_dict();
cell mine = __tact_dict_get_code(source, 55471);
cell contracts = new_dict();
cell code_55471 = __tact_dict_get_code(source, 55471);
contracts = __tact_dict_set_code(contracts, 55471, code_55471);
cell sys = begin_cell().store_dict(contracts).end_cell();
return (mine, __gen_JettonDefaultWallet_init(sys, $master, $owner));
}
cell __gen_SampleJetton_init(cell sys', slice $owner, cell $content) {
var (($self'totalSupply, $self'owner, $self'content, $self'mintable)) = (null(), null(), null(), null());
$self'totalSupply = 0;
$self'owner = $owner;
$self'mintable = true;
$self'content = $content;
var b' = begin_cell();
b' = b'.store_ref(sys');
b' = __gen_write_SampleJetton(b', ($self'totalSupply, $self'owner, $self'content, $self'mintable));
return b'.end_cell();
;; Contract Code: JettonDefaultWallet
cell mine = __tact_dict_get_code(source, 55471);
contracts = __tact_dict_set_code(contracts, 55471, mine);
cell sys = begin_cell().store_dict(contracts).end_cell();
return (mine, $__gen_JettonDefaultWallet_init(sys, $master, $owner));
}
((int, slice, cell, int), (cell, cell)) __gen_SampleJetton_getJettonWalletInit((int, slice, cell, int) $self, slice $address) impure {
((int, slice, cell, int), (cell, cell)) $__gen_SampleJetton_getJettonWalletInit((int, slice, cell, int) $self, slice $address) impure {
var (($self'totalSupply, $self'owner, $self'content, $self'mintable)) = $self;
return (($self'totalSupply, $self'owner, $self'content, $self'mintable), __gen_JettonDefaultWallet_init_child(__tact_context_sys, my_address(), $address));
return (($self'totalSupply, $self'owner, $self'content, $self'mintable), $__gen_JettonDefaultWallet_init_child(__tact_context_sys, my_address(), $address));
}
slice __gen_SampleJetton_get_wallet_address((int, slice, cell, int) $self, slice $owner) impure {
slice $__gen_SampleJetton_get_wallet_address((int, slice, cell, int) $self, slice $owner) impure {
var (($self'totalSupply, $self'owner, $self'content, $self'mintable)) = $self;
var ($winit'code, $winit'data) = ($self'totalSupply, $self'owner, $self'content, $self'mintable)~__gen_SampleJetton_getJettonWalletInit($owner);
return contractAddress(($winit'code, $winit'data));
var ($winit'code, $winit'data) = ($self'totalSupply, $self'owner, $self'content, $self'mintable)~$__gen_SampleJetton_getJettonWalletInit($owner);
return $contractAddress(($winit'code, $winit'data));
}
_ __gen_get_get_wallet_address(slice $owner) method_id(103289) {
_ $__gen_get_get_wallet_address(slice $$owner) method_id(103289) {
slice $owner = $$owner;
var self = __gen_load_SampleJetton();
var res = __gen_SampleJetton_get_wallet_address(self, $owner);
var res = $__gen_SampleJetton_get_wallet_address(self, $owner);
return res;
}
(int, int, slice, cell, cell) __gen_SampleJetton_get_jetton_data((int, slice, cell, int) $self) impure {
(int, int, slice, cell, cell) $__gen_SampleJetton_get_jetton_data((int, slice, cell, int) $self) impure {
var (($self'totalSupply, $self'owner, $self'content, $self'mintable)) = $self;
return ($self'totalSupply, $self'mintable, $self'owner, $self'content, __gen_StateInit_get_code(($self'totalSupply, $self'owner, $self'content, $self'mintable)~__gen_SampleJetton_getJettonWalletInit(my_address())));
cell $code = __gen_StateInit_get_code(($self'totalSupply, $self'owner, $self'content, $self'mintable)~$__gen_SampleJetton_getJettonWalletInit(my_address()));
return ($self'totalSupply, $self'mintable, $self'owner, $self'content, $code);
}
_ __gen_get_get_jetton_data() method_id(106029) {
_ $__gen_get_get_jetton_data() method_id(106029) {
var self = __gen_load_SampleJetton();
var res = __gen_SampleJetton_get_jetton_data(self);
return res;
var res = $__gen_SampleJetton_get_jetton_data(self);
return __gen_JettonData_to_external(res);
}
((int, slice, cell, int), ()) __gen_SampleJetton_mint((int, slice, cell, int) $self, slice $to, int $amount, slice $responseAddress) impure {
((int, slice, cell, int), ()) $__gen_SampleJetton_mint((int, slice, cell, int) $self, slice $to, int $amount, slice $responseAddress) impure {
var (($self'totalSupply, $self'owner, $self'content, $self'mintable)) = $self;
$self'totalSupply = ($self'totalSupply + $amount);
var ($winit'code, $winit'data) = ($self'totalSupply, $self'owner, $self'content, $self'mintable)~__gen_SampleJetton_getJettonWalletInit($to);
slice $walletAddress = contractAddress(($winit'code, $winit'data));
send((false, $walletAddress, 0, 64, __gen_writecell_TokenTransferInternal((0, $amount, my_address(), $responseAddress, 0, emptySlice())), $winit'code, $winit'data));
var ($winit'code, $winit'data) = ($self'totalSupply, $self'owner, $self'content, $self'mintable)~$__gen_SampleJetton_getJettonWalletInit($to);
slice $walletAddress = $contractAddress(($winit'code, $winit'data));
$send((false, $walletAddress, 0, 64, __gen_writecell_TokenTransferInternal((0, $amount, my_address(), $responseAddress, 0, $emptySlice())), $winit'code, $winit'data));
return (($self'totalSupply, $self'owner, $self'content, $self'mintable), ());
}
((int, slice, cell, int), ()) __gen_SampleJetton_requireWallet((int, slice, cell, int) $self, slice $owner) impure {
((int, slice, cell, int), ()) $__gen_SampleJetton_requireWallet((int, slice, cell, int) $self, slice $owner) impure {
var (($self'totalSupply, $self'owner, $self'content, $self'mintable)) = $self;
var ($ctx'bounced, $ctx'sender, $ctx'value, $ctx'raw) = __tact_context_get();
var ($winit'code, $winit'data) = ($self'totalSupply, $self'owner, $self'content, $self'mintable)~__gen_SampleJetton_getJettonWalletInit($owner);
throw_unless(4429, __tact_address_eq(contractAddress(($winit'code, $winit'data)), $ctx'sender));
var ($winit'code, $winit'data) = ($self'totalSupply, $self'owner, $self'content, $self'mintable)~$__gen_SampleJetton_getJettonWalletInit($owner);
throw_unless(4429, __tact_address_eq($contractAddress(($winit'code, $winit'data)), $ctx'sender));
return (($self'totalSupply, $self'owner, $self'content, $self'mintable), ());
}
((int, slice, cell, int), ()) __gen_SampleJetton_requireOwner((int, slice, cell, int) $self) impure {
((int, slice, cell, int), ()) $__gen_SampleJetton_requireOwner((int, slice, cell, int) $self) impure {
var (($self'totalSupply, $self'owner, $self'content, $self'mintable)) = $self;
throw_unless(132, __tact_address_eq(__gen_Context_get_sender(__tact_context_get()), $self'owner));
return (($self'totalSupply, $self'owner, $self'content, $self'mintable), ());
}
slice __gen_SampleJetton_owner((int, slice, cell, int) $self) impure {
slice $__gen_SampleJetton_owner((int, slice, cell, int) $self) impure {
var (($self'totalSupply, $self'owner, $self'content, $self'mintable)) = $self;
return $self'owner;
}
_ __gen_get_owner() method_id(83229) {
_ $__gen_get_owner() method_id(83229) {
var self = __gen_load_SampleJetton();
var res = __gen_SampleJetton_owner(self);
var res = $__gen_SampleJetton_owner(self);
return res;
}
(((int, slice, cell, int)), ()) __gen_SampleJetton_receive_Mint((int, slice, cell, int) $self, (int) $msg) impure {
(((int, slice, cell, int)), ()) $__gen_SampleJetton_receive_Mint((int, slice, cell, int) $self, (int) $msg) impure {
var ($self'totalSupply, $self'owner, $self'content, $self'mintable) = $self;
var ($msg'amount) = $msg;
var ($ctx'bounced, $ctx'sender, $ctx'value, $ctx'raw) = __tact_context_get();
($self'totalSupply, $self'owner, $self'content, $self'mintable)~__gen_SampleJetton_mint($ctx'sender, $msg'amount, $ctx'sender);
($self'totalSupply, $self'owner, $self'content, $self'mintable)~$__gen_SampleJetton_mint($ctx'sender, $msg'amount, $ctx'sender);
return (($self'totalSupply, $self'owner, $self'content, $self'mintable), ());
}
((int, slice, cell, int), ()) __gen_SampleJetton_receive_comment_cd0d986cb1a2f468ae7089f4fc3162c116e5f53fbd11a6839f52dbf5040830b2((int, slice, cell, int) $self) impure {
((int, slice, cell, int), ()) $__gen_SampleJetton_receive_comment_cd0d986cb1a2f468ae7089f4fc3162c116e5f53fbd11a6839f52dbf5040830b2((int, slice, cell, int) $self) impure {
var ($self'totalSupply, $self'owner, $self'content, $self'mintable) = $self;
var ($ctx'bounced, $ctx'sender, $ctx'value, $ctx'raw) = __tact_context_get();
($self'totalSupply, $self'owner, $self'content, $self'mintable)~__gen_SampleJetton_mint($ctx'sender, 1000000000, $ctx'sender);
($self'totalSupply, $self'owner, $self'content, $self'mintable)~$__gen_SampleJetton_mint($ctx'sender, 1000000000, $ctx'sender);
return (($self'totalSupply, $self'owner, $self'content, $self'mintable), ());
}
(((int, slice, cell, int)), ()) __gen_SampleJetton_receive_TokenUpdateContent((int, slice, cell, int) $self, (cell) $msg) impure {
(((int, slice, cell, int)), ()) $__gen_SampleJetton_receive_TokenUpdateContent((int, slice, cell, int) $self, (cell) $msg) impure {
var ($self'totalSupply, $self'owner, $self'content, $self'mintable) = $self;
var ($msg'content) = $msg;
($self'totalSupply, $self'owner, $self'content, $self'mintable)~__gen_SampleJetton_requireOwner();
($self'totalSupply, $self'owner, $self'content, $self'mintable)~$__gen_SampleJetton_requireOwner();
$self'content = $msg'content;
return (($self'totalSupply, $self'owner, $self'content, $self'mintable), ());
}
(((int, slice, cell, int)), ()) __gen_SampleJetton_receive_TokenBurnNotification((int, slice, cell, int) $self, (int, int, slice, slice) $msg) impure {
(((int, slice, cell, int)), ()) $__gen_SampleJetton_receive_TokenBurnNotification((int, slice, cell, int) $self, (int, int, slice, slice) $msg) impure {
var ($self'totalSupply, $self'owner, $self'content, $self'mintable) = $self;
var ($msg'queryId, $msg'amount, $msg'owner, $msg'responseAddress) = $msg;
($self'totalSupply, $self'owner, $self'content, $self'mintable)~__gen_SampleJetton_requireWallet($msg'owner);
($self'totalSupply, $self'owner, $self'content, $self'mintable)~$__gen_SampleJetton_requireWallet($msg'owner);
$self'totalSupply = ($self'totalSupply - $msg'amount);
if ((~ null?($msg'responseAddress))) {
send((false, $msg'responseAddress, 0, (64 + 2), __gen_writecell_TokenExcesses(($msg'queryId)), null(), null()));
$send((false, $msg'responseAddress, 0, (64 + 2), __gen_writecell_TokenExcesses(($msg'queryId)), null(), null()));
}
return (($self'totalSupply, $self'owner, $self'content, $self'mintable), ());
}
@ -396,19 +382,19 @@ _ __gen_get_owner() method_id(83229) {
}
;; Receive Mint message
if (op == 2737462367) {
if (op == 33240155) {
var self = __gen_load_SampleJetton();
var msg = in_msg~__gen_read_Mint();
self~__gen_SampleJetton_receive_Mint(msg);
self~$__gen_SampleJetton_receive_Mint(msg);
__gen_store_SampleJetton(self);
return ();
}
;; Receive TokenUpdateContent message
if (op == 1862840892) {
if (op == 201882270) {
var self = __gen_load_SampleJetton();
var msg = in_msg~__gen_read_TokenUpdateContent();
self~__gen_SampleJetton_receive_TokenUpdateContent(msg);
self~$__gen_SampleJetton_receive_TokenUpdateContent(msg);
__gen_store_SampleJetton(self);
return ();
}
@ -417,7 +403,7 @@ _ __gen_get_owner() method_id(83229) {
if (op == 2078119902) {
var self = __gen_load_SampleJetton();
var msg = in_msg~__gen_read_TokenBurnNotification();
self~__gen_SampleJetton_receive_TokenBurnNotification(msg);
self~$__gen_SampleJetton_receive_TokenBurnNotification(msg);
__gen_store_SampleJetton(self);
return ();
}
@ -429,7 +415,7 @@ _ __gen_get_owner() method_id(83229) {
;; Receive "Mint!" message
if (text_op == 0xcd0d986cb1a2f468ae7089f4fc3162c116e5f53fbd11a6839f52dbf5040830b2) {
var self = __gen_load_SampleJetton();
self~__gen_SampleJetton_receive_comment_cd0d986cb1a2f468ae7089f4fc3162c116e5f53fbd11a6839f52dbf5040830b2();
self~$__gen_SampleJetton_receive_comment_cd0d986cb1a2f468ae7089f4fc3162c116e5f53fbd11a6839f52dbf5040830b2();
__gen_store_SampleJetton(self);
return ();
}
@ -438,10 +424,6 @@ _ __gen_get_owner() method_id(83229) {
throw(130);
}
cell init_SampleJetton(cell sys', slice owner, cell content) method_id {
return __gen_SampleJetton_init(sys', owner, content);
}
_ supported_interfaces() method_id {
return (
"org.ton.introspection.v0"H >> 128,
@ -452,5 +434,5 @@ _ supported_interfaces() method_id {
}
_ get_abi_ipfs() {
return "ipfs://QmfEvDdmm4QFHZHyaeXmxoQzn6vUaLtdbVnjusevQcp7eA";
return "ipfs://QmPfyoAvkPUqzx93gq8EBcVccAYXFEbjnqCMrHYtyPUHfE";
}

301
sources/output/jetton_SampleJetton.fif → sources/output/jetton_SampleJetton.code.fif

@ -2,10 +2,12 @@ PROGRAM{
DECLPROC __tact_not_null
DECLPROC __tact_context_get
DECLPROC __tact_verify_address
DECLPROC __tact_store_bool
DECLPROC __tact_load_address
DECLPROC __tact_load_address_opt
DECLPROC __tact_store_address
DECLPROC __tact_store_address_opt
DECLPROC __tact_create_address
DECLPROC __tact_compute_contract_address
DECLPROC __tact_address_eq
DECLPROC __tact_dict_set_code
@ -22,33 +24,31 @@ PROGRAM{
DECLPROC __gen_read_SampleJetton
DECLPROC __gen_StateInit_get_code
DECLPROC __gen_Context_get_sender
DECLPROC __gen_JettonData_to_external
DECLPROC __gen_load_SampleJetton
DECLPROC __gen_store_SampleJetton
DECLPROC storeBool
DECLPROC emptyCell
DECLPROC __gen_Cell_asSlice
DECLPROC emptySlice
DECLPROC contractAddress
DECLPROC send
DECLPROC __gen_JettonDefaultWallet_init
DECLPROC __gen_JettonDefaultWallet_init_child
DECLPROC __gen_SampleJetton_init
DECLPROC __gen_SampleJetton_getJettonWalletInit
DECLPROC __gen_SampleJetton_get_wallet_address
103289 DECLMETHOD __gen_get_get_wallet_address
DECLPROC __gen_SampleJetton_get_jetton_data
106029 DECLMETHOD __gen_get_get_jetton_data
DECLPROC __gen_SampleJetton_mint
DECLPROC __gen_SampleJetton_requireWallet
DECLPROC __gen_SampleJetton_requireOwner
DECLPROC __gen_SampleJetton_owner
83229 DECLMETHOD __gen_get_owner
DECLPROC __gen_SampleJetton_receive_Mint
DECLPROC __gen_SampleJetton_receive_comment_cd0d986cb1a2f468ae7089f4fc3162c116e5f53fbd11a6839f52dbf5040830b2
DECLPROC __gen_SampleJetton_receive_TokenUpdateContent
DECLPROC __gen_SampleJetton_receive_TokenBurnNotification
DECLPROC $emptyCell
DECLPROC $__gen_Cell_asSlice
DECLPROC $emptySlice
DECLPROC $contractAddress
DECLPROC $send
DECLPROC $__gen_JettonDefaultWallet_init
DECLPROC $__gen_JettonDefaultWallet_init_child
DECLPROC $__gen_SampleJetton_getJettonWalletInit
DECLPROC $__gen_SampleJetton_get_wallet_address
103289 DECLMETHOD $__gen_get_get_wallet_address
DECLPROC $__gen_SampleJetton_get_jetton_data
106029 DECLMETHOD $__gen_get_get_jetton_data
DECLPROC $__gen_SampleJetton_mint
DECLPROC $__gen_SampleJetton_requireWallet
DECLPROC $__gen_SampleJetton_requireOwner
DECLPROC $__gen_SampleJetton_owner
83229 DECLMETHOD $__gen_get_owner
DECLPROC $__gen_SampleJetton_receive_Mint
DECLPROC $__gen_SampleJetton_receive_comment_cd0d986cb1a2f468ae7089f4fc3162c116e5f53fbd11a6839f52dbf5040830b2
DECLPROC $__gen_SampleJetton_receive_TokenUpdateContent
DECLPROC $__gen_SampleJetton_receive_TokenBurnNotification
DECLPROC recv_internal
122307 DECLMETHOD init_SampleJetton
113617 DECLMETHOD supported_interfaces
DECLPROC get_abi_ipfs
DECLGLOBVAR __tact_context
@ -66,7 +66,11 @@ PROGRAM{
SBITS
267 PUSHINT
NEQ
134 THROWIFNOT
136 THROWIFNOT
}>
__tact_store_bool PROCINLINE:<{
SWAP
1 STI
}>
__tact_load_address PROCINLINE:<{
LDMSGADDR
@ -99,34 +103,37 @@ PROGRAM{
__tact_store_address INLINECALLDICT
}>
}>
__tact_compute_contract_address PROC:<{
__tact_create_address PROCINLINE:<{
NEWC
0 PUSHINT
SWAP
2 STU
3 PUSHINT
2 PUSHINT
SWAP
2 STU
0 PUSHINT
SWAP
1 STU
s1 s2 XCHG
STREF
STREF
8 STI
256 STU
ENDC
HASHCU
CTOS
}>
__tact_compute_contract_address PROCINLINE:<{
NEWC
2 PUSHINT
0 PUSHINT
SWAP
2 STU
3 PUSHINT
SWAP
2 STU
0 PUSHINT
SWAP
1 STU
s1 s2 XCHG
8 STI
256 STU
STREF
STREF
ENDC
CTOS
HASHCU
__tact_create_address INLINECALLDICT
}>
__tact_address_eq PROCINLINE:<{
SDEQ
@ -141,9 +148,9 @@ PROGRAM{
16 PUSHINT
DICTUGETREF
NULLSWAPIFNOT
100 THROWIFNOT
135 THROWIFNOT
}>
__gen_write_TokenTransferInternal PROCINLINE:<{
__gen_write_TokenTransferInternal PROCREF:<{
395134233 PUSHINT
s0 s7 XCHG2
32 STU
@ -160,13 +167,13 @@ PROGRAM{
SWAP
STSLICER
}>
__gen_writecell_TokenTransferInternal PROCINLINE:<{
__gen_writecell_TokenTransferInternal PROCREF:<{
NEWC
6 -ROLL
__gen_write_TokenTransferInternal INLINECALLDICT
ENDC
}>
__gen_read_TokenBurnNotification PROCINLINE:<{
__gen_read_TokenBurnNotification PROCREF:<{
32 LDU
SWAP
2078119902 PUSHINT
@ -180,45 +187,45 @@ PROGRAM{
s1 s4 XCHG
s3 s3 s0 XCHG3
}>
__gen_write_TokenExcesses PROCINLINE:<{
__gen_write_TokenExcesses PROCREF:<{
3576854235 PUSHINT
ROT
32 STU
64 STU
}>
__gen_writecell_TokenExcesses PROCINLINE:<{
__gen_writecell_TokenExcesses PROCREF:<{
NEWC
SWAP
__gen_write_TokenExcesses INLINECALLDICT
ENDC
}>
__gen_read_TokenUpdateContent PROCINLINE:<{
__gen_read_TokenUpdateContent PROCREF:<{
32 LDU
SWAP
1862840892 PUSHINT
201882270 PUSHINT
EQUAL
129 THROWIFNOT
PUSHNULL
SWAP
1 LDI
SWAP
IF:<{
NIP
LDREF
}>ELSE<{
PUSHNULL
SWAP
}>
SWAP
}>
__gen_read_Mint PROCINLINE:<{
__gen_read_Mint PROCREF:<{
32 LDU
SWAP
2737462367 PUSHINT
33240155 PUSHINT
EQUAL
129 THROWIFNOT
257 PUSHINT
LDIX
SWAP
}>
__gen_write_JettonDefaultWallet PROCINLINE:<{
__gen_write_JettonDefaultWallet PROCREF:<{
s2 s3 XCHG2
257 PUSHINT
STIX
@ -227,42 +234,42 @@ PROGRAM{
SWAP
__tact_store_address INLINECALLDICT
}>
__gen_write_SampleJetton PROCINLINE:<{
__gen_write_SampleJetton PROCREF:<{
s4 s3 XCHG2
STGRAMS
SWAP
__tact_store_address INLINECALLDICT
s2 PUSH
ISNULL
NOT
IF:<{
s2 POP
FALSE
ROT
1 STI
}>ELSE<{
TRUE
SWAP
1 STI
s1 s2 XCHG
STREF
}>ELSE<{
s2 POP
FALSE
ROT
1 STI
}>
1 STI
}>
__gen_read_SampleJetton PROCINLINE:<{
__gen_read_SampleJetton PROCREF:<{
LDGRAMS
__tact_load_address INLINECALLDICT
PUSHNULL
s0 s2 XCHG
SWAP
1 LDI
SWAP
IF:<{
1 2 BLKDROP2
LDREF
s1 s2 XCHG
}>ELSE<{
PUSHNULL
SWAP
}>
1 LDI
s0 s4 XCHG
s3 s3 XCHG2
4 -ROLL
}>
__gen_StateInit_get_code PROCINLINE:<{
DROP
@ -271,7 +278,9 @@ PROGRAM{
s2 s3 XCHG
3 BLKDROP
}>
__gen_load_SampleJetton PROCINLINE:<{
__gen_JettonData_to_external PROC:<{
}>
__gen_load_SampleJetton PROCREF:<{
c4 PUSH
CTOS
LDREF
@ -280,7 +289,7 @@ PROGRAM{
__gen_read_SampleJetton INLINECALLDICT
1 4 BLKDROP2
}>
__gen_store_SampleJetton PROCINLINE:<{
__gen_store_SampleJetton PROCREF:<{
NEWC
__tact_context_sys GETGLOB
SWAP
@ -290,39 +299,29 @@ PROGRAM{
ENDC
c4 POP
}>
storeBool PROC:<{
IFJMP:<{
-1 PUSHINT
SWAP
1 STI
}>
0 PUSHINT
SWAP
1 STI
}>
emptyCell PROC:<{
$emptyCell PROC:<{
NEWC
ENDC
}>
__gen_Cell_asSlice PROC:<{
$__gen_Cell_asSlice PROC:<{
CTOS
}>
emptySlice PROC:<{
emptyCell CALLDICT
__gen_Cell_asSlice CALLDICT
$emptySlice PROC:<{
$emptyCell CALLDICT
$__gen_Cell_asSlice CALLDICT
}>
contractAddress PROC:<{
$contractAddress PROC:<{
0 PUSHINT
-ROT
__tact_compute_contract_address CALLDICT
__tact_compute_contract_address INLINECALLDICT
}>
send PROC:<{
$send PROC:<{
NEWC
1 PUSHINT
SWAP
2 STI
s0 s7 XCHG2
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
0 PUSHINT
SWAP
3 STI
@ -342,18 +341,18 @@ PROGRAM{
OR
IF:<{
TRUE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
NEWC
FALSE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
FALSE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
s4 PUSH
ISNULL
NOT
IF:<{
TRUE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
s0 s4 XCHG
__tact_not_null CALLDICT
s0 s4 XCHG2
@ -362,14 +361,14 @@ PROGRAM{
s4 POP
s0 s3 XCHG
FALSE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
}>
s4 PUSH
ISNULL
NOT
IF:<{
TRUE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
s0 s4 XCHG
__tact_not_null CALLDICT
s0 s4 XCHG2
@ -378,13 +377,13 @@ PROGRAM{
s4 POP
s0 s3 XCHG
FALSE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
}>
FALSE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
s0 s2 XCHG
TRUE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
s0 s2 XCHG
ENDC
ROT
@ -394,14 +393,14 @@ PROGRAM{
s3 POP
SWAP
FALSE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
}>
OVER
ISNULL
NOT
IF:<{
TRUE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
SWAP
__tact_not_null CALLDICT
SWAP
@ -409,13 +408,13 @@ PROGRAM{
}>ELSE<{
NIP
FALSE
storeBool CALLDICT
__tact_store_bool INLINECALLDICT
}>
ENDC
SWAP
SENDRAWMSG
}>
__gen_JettonDefaultWallet_init PROC:<{
$__gen_JettonDefaultWallet_init PROC:<{
0 PUSHINT
s0 s3 XCHG
NEWC
@ -424,78 +423,66 @@ PROGRAM{
__gen_write_JettonDefaultWallet INLINECALLDICT
ENDC
}>
__gen_JettonDefaultWallet_init_child PROC:<{
$__gen_JettonDefaultWallet_init_child PROC:<{
s0 s2 XCHG
CTOS
LDDICT
DROP
DUP
55471 PUSHINT
__tact_dict_get_code INLINECALLDICT
NEWDICT
s0 s2 XCHG
SWAP
55471 PUSHINT
__tact_dict_get_code INLINECALLDICT
s1 s2 XCHG
55471 PUSHINT
SWAP
55471 PUSHINT
s2 PUSH
__tact_dict_set_code INLINECALLDICT
NEWC
STDICT
ENDC
s0 s0 s3 XCHG3
__gen_JettonDefaultWallet_init CALLDICT
$__gen_JettonDefaultWallet_init CALLDICT
}>
__gen_SampleJetton_init PROC:<{
0 PUSHINT
TRUE
s0 s4 XCHG
NEWC
STREF
s3 s3 s4 XCHG3
__gen_write_SampleJetton INLINECALLDICT
ENDC
}>
__gen_SampleJetton_getJettonWalletInit PROC:<{
$__gen_SampleJetton_getJettonWalletInit PROC:<{
__tact_context_sys GETGLOB
MYADDR
ROT
__gen_JettonDefaultWallet_init_child CALLDICT
$__gen_JettonDefaultWallet_init_child CALLDICT
}>
__gen_SampleJetton_get_wallet_address PROC:<{
__gen_SampleJetton_getJettonWalletInit CALLDICT
$__gen_SampleJetton_get_wallet_address PROC:<{
$__gen_SampleJetton_getJettonWalletInit CALLDICT
4 2 BLKDROP2
contractAddress CALLDICT
$contractAddress CALLDICT
}>
__gen_get_get_wallet_address PROC:<{
$__gen_get_get_wallet_address PROC:<{
__gen_load_SampleJetton INLINECALLDICT
4 ROLL
__gen_SampleJetton_get_wallet_address CALLDICT
$__gen_SampleJetton_get_wallet_address CALLDICT
}>
__gen_SampleJetton_get_jetton_data PROC:<{
$__gen_SampleJetton_get_jetton_data PROC:<{
MYADDR
__gen_SampleJetton_getJettonWalletInit CALLDICT
$__gen_SampleJetton_getJettonWalletInit CALLDICT
__gen_StateInit_get_code INLINECALLDICT
s3 s3 s0 XCHG3
}>
__gen_get_get_jetton_data PROC:<{
$__gen_get_get_jetton_data PROC:<{
__gen_load_SampleJetton INLINECALLDICT
__gen_SampleJetton_get_jetton_data CALLDICT
$__gen_SampleJetton_get_jetton_data CALLDICT
__gen_JettonData_to_external CALLDICT
}>
__gen_SampleJetton_mint PROC:<{
$__gen_SampleJetton_mint PROC:<{
s6 s1 XCPU
ADD
4 2 BLKSWAP
__gen_SampleJetton_getJettonWalletInit CALLDICT
$__gen_SampleJetton_getJettonWalletInit CALLDICT
2DUP
contractAddress CALLDICT
$contractAddress CALLDICT
FALSE
0 PUSHINT
64 PUSHINT
OVER
MYADDR
OVER
emptySlice CALLDICT
$emptySlice CALLDICT
s3 s5 XCHG
s4 s14 XCHG
s2 s3 XCHG
@ -505,66 +492,66 @@ PROGRAM{
s4 s10 XCHG
s3 s9 XCHG
s0 s10 s9 XCHG3
send CALLDICT
$send CALLDICT
2SWAP
}>
__gen_SampleJetton_requireWallet PROC:<{
$__gen_SampleJetton_requireWallet PROC:<{
__tact_context_get INLINECALLDICT
s2 s3 XCHG
3 BLKDROP
5 -ROLL
__gen_SampleJetton_getJettonWalletInit CALLDICT
$__gen_SampleJetton_getJettonWalletInit CALLDICT
SWAP
4429 PUSHINT
s0 s2 XCHG
contractAddress CALLDICT
$contractAddress CALLDICT
s0 s6 XCHG2
__tact_address_eq INLINECALLDICT
s1 s5 XCHG
THROWANYIFNOT
3 ROLL
}>
__gen_SampleJetton_requireOwner PROC:<{
$__gen_SampleJetton_requireOwner PROC:<{
__tact_context_get INLINECALLDICT
__gen_Context_get_sender INLINECALLDICT
s3 PUSH
__tact_address_eq INLINECALLDICT
132 THROWIFNOT
}>
__gen_SampleJetton_owner PROC:<{
$__gen_SampleJetton_owner PROC:<{
s2 s3 XCHG
3 BLKDROP
}>
__gen_get_owner PROC:<{
$__gen_get_owner PROC:<{
__gen_load_SampleJetton INLINECALLDICT
__gen_SampleJetton_owner CALLDICT
$__gen_SampleJetton_owner CALLDICT
}>
__gen_SampleJetton_receive_Mint PROC:<{
$__gen_SampleJetton_receive_Mint PROC:<{
__tact_context_get INLINECALLDICT
s2 s3 XCHG
3 BLKDROP
TUCK
__gen_SampleJetton_mint CALLDICT
$__gen_SampleJetton_mint CALLDICT
}>
__gen_SampleJetton_receive_comment_cd0d986cb1a2f468ae7089f4fc3162c116e5f53fbd11a6839f52dbf5040830b2 PROC:<{
$__gen_SampleJetton_receive_comment_cd0d986cb1a2f468ae7089f4fc3162c116e5f53fbd11a6839f52dbf5040830b2 PROC:<{
__tact_context_get INLINECALLDICT
s2 s3 XCHG
3 BLKDROP
1000000000 PUSHINT
OVER
__gen_SampleJetton_mint CALLDICT
$__gen_SampleJetton_mint CALLDICT
}>
__gen_SampleJetton_receive_TokenUpdateContent PROC:<{
$__gen_SampleJetton_receive_TokenUpdateContent PROC:<{
4 -ROLL
__gen_SampleJetton_requireOwner CALLDICT
$__gen_SampleJetton_requireOwner CALLDICT
NIP
s1 s3 s0 XCHG3
}>
__gen_SampleJetton_receive_TokenBurnNotification PROC:<{
$__gen_SampleJetton_receive_TokenBurnNotification PROC:<{
s4 s7 XCHG
s3 s6 XCHG
s5 s7 s7 XCHG3
__gen_SampleJetton_requireWallet CALLDICT
$__gen_SampleJetton_requireWallet CALLDICT
s3 s4 XCHG2
SUB
s5 PUSH
@ -581,7 +568,7 @@ PROGRAM{
s1 s7 s0 XCHG3
PUSHNULL
PUSHNULL
send CALLDICT
$send CALLDICT
s2 s3 XCHG
}>ELSE<{
s4 POP
@ -590,6 +577,7 @@ PROGRAM{
s3 s0 s0 XCHG3
}>
recv_internal PROC:<{
c2 SAVE
SAMEALTSAVE
0 PUSHINT
OVER
@ -623,7 +611,7 @@ PROGRAM{
2DROP
}>
DUP
2737462367 PUSHINT
33240155 PUSHINT
EQUAL
IFJMP:<{
DROP
@ -633,11 +621,11 @@ PROGRAM{
NIP
s3 s4 XCHG
s1 s3 s0 XCHG3
__gen_SampleJetton_receive_Mint CALLDICT
$__gen_SampleJetton_receive_Mint CALLDICT
__gen_store_SampleJetton INLINECALLDICT
}>
DUP
1862840892 PUSHINT
201882270 PUSHINT
EQUAL
IFJMP:<{
DROP
@ -647,7 +635,7 @@ PROGRAM{
NIP
s3 s4 XCHG
s1 s3 s0 XCHG3
__gen_SampleJetton_receive_TokenUpdateContent CALLDICT
$__gen_SampleJetton_receive_TokenUpdateContent CALLDICT
__gen_store_SampleJetton INLINECALLDICT
}>
DUP
@ -663,7 +651,7 @@ PROGRAM{
s5 s6 XCHG
s4 s5 XCHG
3 ROLL
__gen_SampleJetton_receive_TokenBurnNotification CALLDICT
$__gen_SampleJetton_receive_TokenBurnNotification CALLDICT
__gen_store_SampleJetton INLINECALLDICT
}>
0 EQINT
@ -673,7 +661,7 @@ PROGRAM{
EQUAL
IFJMP:<{
__gen_load_SampleJetton INLINECALLDICT
__gen_SampleJetton_receive_comment_cd0d986cb1a2f468ae7089f4fc3162c116e5f53fbd11a6839f52dbf5040830b2 CALLDICT
$__gen_SampleJetton_receive_comment_cd0d986cb1a2f468ae7089f4fc3162c116e5f53fbd11a6839f52dbf5040830b2 CALLDICT
__gen_store_SampleJetton INLINECALLDICT
RETALT
}>
@ -682,9 +670,6 @@ PROGRAM{
}>
130 THROW
}>
init_SampleJetton PROC:<{
__gen_SampleJetton_init CALLDICT
}>
supported_interfaces PROC:<{
123515602279859691144772641439386770278 PUSHINT
209801025412363888721030803524359905849 PUSHINT
@ -692,6 +677,6 @@ PROGRAM{
86142586315491086060343270784266291122 PUSHINT
}>
get_abi_ipfs PROC:<{
x{697066733a2f2f516d66457644646d6d345146485a48796165586d786f517a6e367655614c746462566e6a75736576516370376541} PUSHSLICE
x{697066733a2f2f516d5066796f41766b5055717a7839336771384542635663634159584645626a6e71434d72485974795055486645} PUSHSLICE
}>
}END>c

452
sources/output/jetton_SampleJetton.rev.fif → sources/output/jetton_SampleJetton.code.rev.fif

@ -1,6 +1,7 @@
SETCP0
(:methods
recv_internal:
c2 SAVE
SAMEALTSAVE
0 PUSHINT
s1 PUSH
@ -38,62 +39,65 @@ SETCP0
}> PUSHCONT
IFJMP
s0 PUSH
2737462367 PUSHINT
33240155 PUSHINT
EQUAL
<{
s0 POP
<{
c4 PUSH
CTOS
LDREF
s0 s1 XCHG
2 SETGLOBVAR
<{
LDGRAMS
LDMSGADDR
s0 s1 XCHG
PUSHNULL
s0 s2 XCHG
s0 s1 XCHG
1 LDI
s0 s1 XCHG
<{
1 2 BLKDROP2
LDREF
s1 s2 XCHG
}> PUSHCONT
IF
<{
PUSHNULL
s0 s1 XCHG
}> PUSHCONT
IFELSE
1 LDI
s0 s4 XCHG
s3 s3 XCHG2
4 1 BLKSWAP
}> CALLREF
1 4 BLKDROP2
}> CALLREF
s0 s4 XCHG
<{
32 LDU
s0 s1 XCHG
2737462367 PUSHINT
33240155 PUSHINT
EQUAL
129 THROWIFNOT
257 PUSHINT
LDI
s0 s1 XCHG
}> CALLREF
s1 POP
s3 s4 XCHG
s1 s3 s0 XCHG3
42 CALLDICT
43 CALLDICT
<{
NEWC
2 GETGLOBVAR
s0 s1 XCHG
STREF
4 1 BLKSWAP
<{
s4 s3 XCHG2
STGRAMS
s0 s1 XCHG
STSLICER
s2 PUSH
ISNULL
<{
s2 POP
0 PUSHINT
ROT
1 STI
}> PUSHCONT
NOT
<{
-1 PUSHINT
s0 s1 XCHG
@ -101,75 +105,88 @@ SETCP0
s1 s2 XCHG
STREF
}> PUSHCONT
<{
s2 POP
0 PUSHINT
ROT
1 STI
}> PUSHCONT
IFELSE
1 STI
}> CALLREF
ENDC
c4 POP
}> IFJMPREF
}> CALLREF
}> PUSHCONT
IFJMP
s0 PUSH
1862840892 PUSHINT
201882270 PUSHINT
EQUAL
<{
s0 POP
<{
c4 PUSH
CTOS
LDREF
s0 s1 XCHG
2 SETGLOBVAR
<{
LDGRAMS
LDMSGADDR
s0 s1 XCHG
PUSHNULL
s0 s2 XCHG
s0 s1 XCHG
1 LDI
s0 s1 XCHG
<{
1 2 BLKDROP2
LDREF
s1 s2 XCHG
}> PUSHCONT
IF
<{
PUSHNULL
s0 s1 XCHG
}> PUSHCONT
IFELSE
1 LDI
s0 s4 XCHG
s3 s3 XCHG2
4 1 BLKSWAP
}> CALLREF
1 4 BLKDROP2
}> CALLREF
s0 s4 XCHG
<{
32 LDU
s0 s1 XCHG
1862840892 PUSHINT
201882270 PUSHINT
EQUAL
129 THROWIFNOT
PUSHNULL
s0 s1 XCHG
1 LDI
s0 s1 XCHG
<{
s1 POP
LDREF
}> PUSHCONT
IF
<{
PUSHNULL
s0 s1 XCHG
}> PUSHCONT
IFELSE
s0 s1 XCHG
}> CALLREF
s1 POP
s3 s4 XCHG
s1 s3 s0 XCHG3
44 CALLDICT
45 CALLDICT
<{
NEWC
2 GETGLOBVAR
s0 s1 XCHG
STREF
4 1 BLKSWAP
<{
s4 s3 XCHG2
STGRAMS
s0 s1 XCHG
STSLICER
s2 PUSH
ISNULL
<{
s2 POP
0 PUSHINT
ROT
1 STI
}> PUSHCONT
NOT
<{
-1 PUSHINT
s0 s1 XCHG
@ -177,39 +194,53 @@ SETCP0
s1 s2 XCHG
STREF
}> PUSHCONT
<{
s2 POP
0 PUSHINT
ROT
1 STI
}> PUSHCONT
IFELSE
1 STI
}> CALLREF
ENDC
c4 POP
}> IFJMPREF
}> CALLREF
}> PUSHCONT
IFJMP
s0 PUSH
2078119902 PUSHINT
EQUAL
<{
s0 POP
<{
c4 PUSH
CTOS
LDREF
s0 s1 XCHG
2 SETGLOBVAR
<{
LDGRAMS
LDMSGADDR
s0 s1 XCHG
PUSHNULL
s0 s2 XCHG
s0 s1 XCHG
1 LDI
s0 s1 XCHG
<{
1 2 BLKDROP2
LDREF
s1 s2 XCHG
}> PUSHCONT
IF
<{
PUSHNULL
s0 s1 XCHG
}> PUSHCONT
IFELSE
1 LDI
s0 s4 XCHG
s3 s3 XCHG2
4 1 BLKSWAP
}> CALLREF
1 4 BLKDROP2
}> CALLREF
s0 s4 XCHG
<{
32 LDU
s0 s1 XCHG
2078119902 PUSHINT
@ -234,29 +265,27 @@ SETCP0
IFELSE
s1 s4 XCHG
s3 s3 s0 XCHG3
}> CALLREF
s4 POP
s6 s7 XCHG
s5 s6 XCHG
s4 s5 XCHG
1 3 BLKSWAP
45 CALLDICT
46 CALLDICT
<{
NEWC
2 GETGLOBVAR
s0 s1 XCHG
STREF
4 1 BLKSWAP
<{
s4 s3 XCHG2
STGRAMS
s0 s1 XCHG
STSLICER
s2 PUSH
ISNULL
<{
s2 POP
0 PUSHINT
ROT
1 STI
}> PUSHCONT
NOT
<{
-1 PUSHINT
s0 s1 XCHG
@ -264,57 +293,67 @@ SETCP0
s1 s2 XCHG
STREF
}> PUSHCONT
<{
s2 POP
0 PUSHINT
ROT
1 STI
}> PUSHCONT
IFELSE
1 STI
}> CALLREF
ENDC
c4 POP
}> IFJMPREF
}> CALLREF
}> PUSHCONT
IFJMP
0 EQINT
<{
HASHSU
92748154967237992140665580847895802782213764542359950109876145449566260965554 PUSHINT
EQUAL
<{
<{
c4 PUSH
CTOS
LDREF
s0 s1 XCHG
2 SETGLOBVAR
<{
LDGRAMS
LDMSGADDR
s0 s1 XCHG
PUSHNULL
s0 s2 XCHG
s0 s1 XCHG
1 LDI
s0 s1 XCHG
<{
1 2 BLKDROP2
LDREF
s1 s2 XCHG
}> PUSHCONT
IF
<{
PUSHNULL
s0 s1 XCHG
}> PUSHCONT
IFELSE
1 LDI
s0 s4 XCHG
s3 s3 XCHG2
4 1 BLKSWAP
}> CALLREF
1 4 BLKDROP2
43 CALLDICT
}> CALLREF
44 CALLDICT
<{
NEWC
2 GETGLOBVAR
s0 s1 XCHG
STREF
4 1 BLKSWAP
<{
s4 s3 XCHG2
STGRAMS
s0 s1 XCHG
STSLICER
s2 PUSH
ISNULL
<{
s2 POP
0 PUSHINT
ROT
1 STI
}> PUSHCONT
NOT
<{
-1 PUSHINT
s0 s1 XCHG
@ -322,10 +361,18 @@ SETCP0
s1 s2 XCHG
STREF
}> PUSHCONT
<{
s2 POP
0 PUSHINT
ROT
1 STI
}> PUSHCONT
IFELSE
1 STI
}> CALLREF
ENDC
c4 POP
}> CALLREF
RETALT
}> PUSHCONT
IFJMP
@ -341,7 +388,22 @@ SETCP0
ISNULL
128 THROWIF
8:
26:
29:
NEWC
ENDC
30:
CTOS
31:
29 CALLDICT
30 CALLDICT
32:
0 PUSHINT
ROTREV
NEWC
0 PUSHINT
s0 s1 XCHG
@ -370,40 +432,14 @@ SETCP0
ENDC
CTOS
26:
<{
-1 PUSHINT
s0 s1 XCHG
1 STI
}> PUSHCONT
IFJMP
0 PUSHINT
s0 s1 XCHG
1 STI
27:
NEWC
ENDC
28:
CTOS
29:
27 CALLDICT
28 CALLDICT
30:
0 PUSHINT
ROTREV
8 CALLDICT
31:
33:
NEWC
1 PUSHINT
s0 s1 XCHG
2 STI
s0 s7 XCHG2
26 CALLDICT
s0 s1 XCHG
1 STI
0 PUSHINT
s0 s1 XCHG
3 STI
@ -423,18 +459,22 @@ SETCP0
OR
<{
-1 PUSHINT
26 CALLDICT
s0 s1 XCHG
1 STI
NEWC
0 PUSHINT
26 CALLDICT
s0 s1 XCHG
1 STI
0 PUSHINT
26 CALLDICT
s0 s1 XCHG
1 STI
s4 PUSH
ISNULL
NOT
<{
-1 PUSHINT
26 CALLDICT
s0 s1 XCHG
1 STI
s0 s4 XCHG
1 CALLDICT
s0 s4 XCHG2
@ -444,7 +484,8 @@ SETCP0
s4 POP
s0 s3 XCHG
0 PUSHINT
26 CALLDICT
s0 s1 XCHG
1 STI
}> PUSHCONT
IFELSE
s4 PUSH
@ -452,7 +493,8 @@ SETCP0
NOT
<{
-1 PUSHINT
26 CALLDICT
s0 s1 XCHG
1 STI
s0 s4 XCHG
1 CALLDICT
s0 s4 XCHG2
@ -462,14 +504,17 @@ SETCP0
s4 POP
s0 s3 XCHG
0 PUSHINT
26 CALLDICT
s0 s1 XCHG
1 STI
}> PUSHCONT
IFELSE
0 PUSHINT
26 CALLDICT
s0 s1 XCHG
1 STI
s0 s2 XCHG
-1 PUSHINT
26 CALLDICT
s0 s1 XCHG
1 STI
s0 s2 XCHG
ENDC
ROT
@ -480,7 +525,8 @@ SETCP0
s3 POP
s0 s1 XCHG
0 PUSHINT
26 CALLDICT
s0 s1 XCHG
1 STI
}> PUSHCONT
IFELSE
s1 PUSH
@ -488,28 +534,28 @@ SETCP0
NOT
<{
-1 PUSHINT
26 CALLDICT
s0 s1 XCHG
1 STI
s0 s1 XCHG
1 CALLDICT
s0 s1 XCHG
STREF
}> PUSHCONT
<{
s1 POP
0 PUSHINT
26 CALLDICT
}> PUSHCONT
IFELSE
}> IFREFELSEREF
ENDC
s0 s1 XCHG
SENDRAWMSG
s1 POP
0 PUSHINT
s0 s1 XCHG
1 STI
32:
34:
0 PUSHINT
s0 s3 XCHG
NEWC
STREF
s3 s1 s3 XCHG3
<{
s2 s3 XCHG2
257 PUSHINT
STIX
@ -517,31 +563,25 @@ SETCP0
STSLICER
s0 s1 XCHG
STSLICER
}> CALLREF
ENDC
33:
35:
s0 s2 XCHG
CTOS
LDDICT
s0 POP
s0 PUSH
55471 PUSHINT
s0 s1 XCHG
16 PUSHINT
DICTUGETREF
NULLSWAPIFNOT
100 THROWIFNOT
PUSHNULL
s0 s2 XCHG
s0 s1 XCHG
55471 PUSHINT
s0 s1 XCHG
16 PUSHINT
DICTUGETREF
NULLSWAPIFNOT
100 THROWIFNOT
s1 s2 XCHG
55471 PUSHINT
135 THROWIFNOT
s0 s1 XCHG
55471 PUSHINT
s2 PUSH
s0 s2 XCHG
16 PUSHINT
DICTUSETREF
@ -549,75 +589,47 @@ SETCP0
STDICT
ENDC
s0 s0 s3 XCHG3
32 CALLDICT
34:
0 PUSHINT
-1 PUSHINT
s0 s4 XCHG
NEWC
STREF
s3 s3 s4 XCHG3
s4 s3 XCHG2
STGRAMS
s0 s1 XCHG
STSLICER
s2 PUSH
ISNULL
<{
s2 POP
0 PUSHINT
ROT
1 STI
}> PUSHCONT
<{
-1 PUSHINT
s0 s1 XCHG
1 STI
s1 s2 XCHG
STREF
}> PUSHCONT
IFELSE
1 STI
ENDC
34 CALLDICT
35:
36:
2 GETGLOBVAR
MYADDR
ROT
33 CALLDICT
36:
35 CALLDICT
4 2 BLKDROP2
30 CALLDICT
37:
36 CALLDICT
4 2 BLKDROP2
32 CALLDICT
38:
MYADDR
35 CALLDICT
36 CALLDICT
s0 POP
s3 s3 s0 XCHG3
38:
39:
s6 s1 XCPU
ADD
4 2 BLKSWAP
35 CALLDICT
36 CALLDICT
2DUP
30 CALLDICT
32 CALLDICT
0 PUSHINT
0 PUSHINT
64 PUSHINT
s1 PUSH
MYADDR
s1 PUSH
29 CALLDICT
31 CALLDICT
s3 s5 XCHG
s4 s14 XCHG
s2 s3 XCHG
s2 s15 XCHG
<{
NEWC
6 1 BLKSWAP
<{
395134233 PUSHINT
s0 s7 XCHG2
32 STU
@ -644,32 +656,34 @@ SETCP0
STGRAMS
s0 s1 XCHG
STSLICER
}> CALLREF
ENDC
}> CALLREF
s5 s6 s0 XCHG3
s4 s10 XCHG
s3 s9 XCHG
s0 s10 s9 XCHG3
31 CALLDICT
33 CALLDICT
2SWAP
39:
40:
1 GETGLOBVAR
4 UNTUPLE
s2 s3 XCHG
3 BLKDROP
5 1 BLKSWAP
35 CALLDICT
36 CALLDICT
s0 s1 XCHG
4429 PUSHINT
s0 s2 XCHG
30 CALLDICT
32 CALLDICT
s0 s6 XCHG2
SDEQ
s1 s5 XCHG
THROWANYIFNOT
1 3 BLKSWAP
40:
41:
1 GETGLOBVAR
4 UNTUPLE
s2 s3 XCHG
@ -678,38 +692,38 @@ SETCP0
SDEQ
132 THROWIFNOT
41:
42:
s2 s3 XCHG
3 BLKDROP
42:
43:
1 GETGLOBVAR
4 UNTUPLE
s2 s3 XCHG
3 BLKDROP
TUCK
38 CALLDICT
39 CALLDICT
43:
44:
1 GETGLOBVAR
4 UNTUPLE
s2 s3 XCHG
3 BLKDROP
1000000000 PUSHINT
s1 PUSH
38 CALLDICT
39 CALLDICT
44:
45:
4 1 BLKSWAP
40 CALLDICT
41 CALLDICT
s1 POP
s1 s3 s0 XCHG3
45:
46:
s4 s7 XCHG
s3 s6 XCHG
s5 s7 s7 XCHG3
39 CALLDICT
40 CALLDICT
s3 s4 XCHG2
SUB
s5 PUSH
@ -720,19 +734,23 @@ SETCP0
0 PUSHINT
66 PUSHINT
s0 s7 XCHG
<{
NEWC
s0 s1 XCHG
<{
3576854235 PUSHINT
ROT
32 STU
64 STU
}> CALLREF
ENDC
}> CALLREF
s2 s4 XCHG
s3 s8 XCHG
s1 s7 s0 XCHG3
PUSHNULL
PUSHNULL
31 CALLDICT
33 CALLDICT
s2 s3 XCHG
}> PUSHCONT
<{
@ -743,89 +761,99 @@ SETCP0
s3 s0 s0 XCHG3
owner:
<{
c4 PUSH
CTOS
LDREF
s0 s1 XCHG
2 SETGLOBVAR
<{
LDGRAMS
LDMSGADDR
s0 s1 XCHG
PUSHNULL
s0 s2 XCHG
s0 s1 XCHG
1 LDI
s0 s1 XCHG
<{
1 2 BLKDROP2
LDREF
s1 s2 XCHG
}> PUSHCONT
IF
<{
PUSHNULL
s0 s1 XCHG
}> PUSHCONT
IFELSE
1 LDI
s0 s4 XCHG
s3 s3 XCHG2
4 1 BLKSWAP
}> CALLREF
1 4 BLKDROP2
41 CALLDICT
}> CALLREF
42 CALLDICT
get_wallet_address:
<{
c4 PUSH
CTOS
LDREF
s0 s1 XCHG
2 SETGLOBVAR
<{
LDGRAMS
LDMSGADDR
s0 s1 XCHG
PUSHNULL
s0 s2 XCHG
s0 s1 XCHG
1 LDI
s0 s1 XCHG
<{
1 2 BLKDROP2
LDREF
s1 s2 XCHG
}> PUSHCONT
IF
<{
PUSHNULL
s0 s1 XCHG
}> PUSHCONT
IFELSE
1 LDI
s0 s4 XCHG
s3 s3 XCHG2
4 1 BLKSWAP
}> CALLREF
1 4 BLKDROP2
}> CALLREF
1 4 BLKSWAP
36 CALLDICT
37 CALLDICT
get_jetton_data:
<{
c4 PUSH
CTOS
LDREF
s0 s1 XCHG
2 SETGLOBVAR
<{
LDGRAMS
LDMSGADDR
s0 s1 XCHG
PUSHNULL
s0 s2 XCHG
s0 s1 XCHG
1 LDI
s0 s1 XCHG
<{
1 2 BLKDROP2
LDREF
s1 s2 XCHG
}> PUSHCONT
IF
<{
PUSHNULL
s0 s1 XCHG
}> PUSHCONT
IFELSE
1 LDI
s0 s4 XCHG
s3 s3 XCHG2
4 1 BLKSWAP
}> CALLREF
1 4 BLKDROP2
37 CALLDICT
}> CALLREF
38 CALLDICT
26 CALLDICT
113617:
123515602279859691144772641439386770278 PUSHINT
209801025412363888721030803524359905849 PUSHINT
258390863389042349688353801369539695109 PUSHINT
86142586315491086060343270784266291122 PUSHINT
122307:
34 CALLDICT
) 19 DICTPUSHCONST
DICTIGETJMPZ
11 THROWARG

BIN
sources/output/jetton_SampleJetton.init.boc

Binary file not shown.

39
sources/output/jetton_SampleJetton.init.fc

@ -0,0 +1,39 @@
() __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 __gen_write_SampleJetton(builder build_0, (int, slice, cell, int) v) inline_ref {
var (v'totalSupply, v'owner, v'content, v'mintable) = 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);
return build_0;
}
cell $__gen_SampleJetton_init(cell sys', slice $owner, cell $content) {
var (($self'totalSupply, $self'owner, $self'content, $self'mintable)) = (null(), null(), null(), null());
$self'totalSupply = 0;
$self'owner = $owner;
$self'mintable = true;
$self'content = $content;
var b' = begin_cell();
b' = b'.store_ref(sys');
b' = __gen_write_SampleJetton(b', ($self'totalSupply, $self'owner, $self'content, $self'mintable));
return b'.end_cell();
}
cell init(cell sys', slice $$owner, cell $$content) method_id {
slice $owner = $$owner;
cell $content = $$content;
return $__gen_SampleJetton_init(sys', $owner, $content);
}
() main() {
}

54
sources/output/jetton_SampleJetton.init.fif

@ -0,0 +1,54 @@
PROGRAM{
DECLPROC __tact_verify_address
DECLPROC __tact_store_address
DECLPROC __gen_write_SampleJetton
DECLPROC $__gen_SampleJetton_init
107886 DECLMETHOD init
DECLPROC main
__tact_verify_address PROCINLINE:<{
SBITS
267 PUSHINT
NEQ
136 THROWIFNOT
}>
__tact_store_address PROCINLINE:<{
STSLICER
}>
__gen_write_SampleJetton PROCREF:<{
s4 s3 XCHG2
STGRAMS
SWAP
__tact_store_address INLINECALLDICT
s2 PUSH
ISNULL
NOT
IF:<{
TRUE
SWAP
1 STI
s1 s2 XCHG
STREF
}>ELSE<{
s2 POP
FALSE
ROT
1 STI
}>
1 STI
}>
$__gen_SampleJetton_init PROC:<{
0 PUSHINT
TRUE
s0 s4 XCHG
NEWC
STREF
s3 s3 s4 XCHG3
__gen_write_SampleJetton INLINECALLDICT
ENDC
}>
init PROC:<{
$__gen_SampleJetton_init CALLDICT
}>
main PROC:<{
}>
}END>c

42
sources/output/jetton_SampleJetton.init.rev.fif

@ -0,0 +1,42 @@
SETCP0
(:methods
recv_internal:
4:
0 PUSHINT
-1 PUSHINT
s0 s4 XCHG
NEWC
STREF
s3 s3 s4 XCHG3
<{
s4 s3 XCHG2
STGRAMS
s0 s1 XCHG
STSLICER
s2 PUSH
ISNULL
NOT
<{
-1 PUSHINT
s0 s1 XCHG
1 STI
s1 s2 XCHG
STREF
}> PUSHCONT
<{
s2 POP
0 PUSHINT
ROT
1 STI
}> PUSHCONT
IFELSE
1 STI
}> CALLREF
ENDC
107886:
4 CALLDICT
) 19 DICTPUSHCONST
DICTIGETJMPZ
11 THROWARG

72
sources/output/jetton_SampleJetton.md

@ -0,0 +1,72 @@
# TACT Compilation Report
Contract: SampleJetton
BOC Size: 1199 bytes
# Types
Total Types: 14
## StateInit
TLB: `_ code:^cell data:^cell = StateInit`
Signature: `StateInit{code:^cell,data:^cell}`
## Context
TLB: `_ bounced:bool sender:address value:int257 raw:^slice = Context`
Signature: `Context{bounced:bool,sender:address,value:int257,raw:^slice}`
## SendParameters
TLB: `_ bounce:bool to:address value:int257 mode:int257 body:Maybe ^cell code:Maybe ^cell data:Maybe ^cell = SendParameters`
Signature: `SendParameters{bounce:bool,to:address,value:int257,mode:int257,body:Maybe ^cell,code:Maybe ^cell,data:Maybe ^cell}`
## ChangeOwner
TLB: `change_owner#0f474d03 newOwner:address = ChangeOwner`
Signature: `ChangeOwner{newOwner:address}`
## TokenTransfer
TLB: `token_transfer#0f8a7ea5 queryId:uint64 amount:coins destination:address responseDestination:Maybe address customPayload:Maybe ^cell forwardTonAmount:coins forwardPayload:remainder<slice> = TokenTransfer`
Signature: `TokenTransfer{queryId:uint64,amount:coins,destination:address,responseDestination:Maybe address,customPayload:Maybe ^cell,forwardTonAmount:coins,forwardPayload:remainder<slice>}`
## TokenTransferInternal
TLB: `token_transfer_internal#178d4519 queryId:uint64 amount:coins from:address responseAddress:Maybe address forwardTonAmount:coins forwardPayload:remainder<slice> = TokenTransferInternal`
Signature: `TokenTransferInternal{queryId:uint64,amount:coins,from:address,responseAddress:Maybe address,forwardTonAmount:coins,forwardPayload:remainder<slice>}`
## TokenNotification
TLB: `token_notification#7362d09c queryId:uint64 amount:coins from:address forwardPayload:remainder<slice> = TokenNotification`
Signature: `TokenNotification{queryId:uint64,amount:coins,from:address,forwardPayload:remainder<slice>}`
## TokenBurn
TLB: `token_burn#595f07bc queryId:uint64 amount:coins owner:address responseAddress:Maybe address = TokenBurn`
Signature: `TokenBurn{queryId:uint64,amount:coins,owner:address,responseAddress:Maybe address}`
## TokenBurnNotification
TLB: `token_burn_notification#7bdd97de queryId:uint64 amount:coins owner:address responseAddress:Maybe address = TokenBurnNotification`
Signature: `TokenBurnNotification{queryId:uint64,amount:coins,owner:address,responseAddress:Maybe address}`
## TokenExcesses
TLB: `token_excesses#d53276db queryId:uint64 = TokenExcesses`
Signature: `TokenExcesses{queryId:uint64}`
## TokenUpdateContent
TLB: `token_update_content#0c087a9e content:Maybe ^cell = TokenUpdateContent`
Signature: `TokenUpdateContent{content:Maybe ^cell}`
## JettonData
TLB: `_ totalSupply:int257 mintable:bool owner:address content:Maybe ^cell walletCode:^cell = JettonData`
Signature: `JettonData{totalSupply:int257,mintable:bool,owner:address,content:Maybe ^cell,walletCode:^cell}`
## JettonWalletData
TLB: `_ balance:int257 owner:address master:address walletCode:^cell = JettonWalletData`
Signature: `JettonWalletData{balance:int257,owner:address,master:address,walletCode:^cell}`
## Mint
TLB: `mint#01fb345b amount:int257 = Mint`
Signature: `Mint{amount:int257}`
# Get Methods
Total Get Methods: 3
## get_wallet_address
Argument: owner
## get_jetton_data
## owner

1
sources/output/jetton_SampleJetton.pkg

File diff suppressed because one or more lines are too long

1353
sources/output/jetton_SampleJetton.ts

File diff suppressed because it is too large Load Diff

8
sources/utils/jetton-helpers.ts

@ -2,6 +2,10 @@ import { Sha256 } from "@aws-crypto/sha256-js";
import { beginCell, Cell } from "ton";
import { Dictionary } from "ton-core";
const ONCHAIN_CONTENT_PREFIX = 0x00;
const SNAKE_PREFIX = 0x00;
const CELL_MAX_SIZE_BYTES = Math.floor((1023 - 8) / 8);
function bufferToChunks(buff: Buffer, chunkSize: number) {
let chunks: Buffer[] = [];
while (buff.byteLength > 0) {
@ -10,7 +14,6 @@ function bufferToChunks(buff: Buffer, chunkSize: number) {
}
return chunks;
}
const CELL_MAX_SIZE_BYTES = Math.floor((1023 - 8) / 8);
export function makeSnakeCell(data: Buffer) {
let chunks = bufferToChunks(data, CELL_MAX_SIZE_BYTES);
@ -29,9 +32,6 @@ export function makeSnakeCell(data: Buffer) {
return b.endCell();
}
const ONCHAIN_CONTENT_PREFIX = 0x00;
const SNAKE_PREFIX = 0x00;
const sha256 = (str: string) => {
const sha = new Sha256();
sha.update(str);

Loading…
Cancel
Save