You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When deploying a smart contract via code, one can specify the initial values of static variables by using the varInit argument of tvm.buildStateInit or new ([https://github.com/tonlabs/TON-Solidity-Compiler/blob/master/API.md#tvmbuildstateinit]).
When deploying a smart contract via command line, one can use tvm_linker init to specify the initial values of static variables, i.e.: tvm_linker init my_contract.tvm '{ "var1" : "value1", ... }' my_contract.abi.json
Being able to specify the initial values of static variables with ft contrat --build or ft contract --deploy (whichever is the most suitable) would be a valuable addition to ft.
The text was updated successfully, but these errors were encountered:
I don't like the idea of modifying the TVC image for such a purpose. It means that there will be one different TVC image for every such contract, and so, probably, we have to call it with a different contract name.
It would probably better to manage that at the account level, adding a field 'initial_data' in the account information. This information would be used to compute the address and when the contract is deployed.
When deploying a smart contract via code, one can specify the initial values of static variables by using the
varInit
argument oftvm.buildStateInit
ornew
([https://github.com/tonlabs/TON-Solidity-Compiler/blob/master/API.md#tvmbuildstateinit]).When deploying a smart contract via command line, one can use
tvm_linker init
to specify the initial values of static variables, i.e.:tvm_linker init my_contract.tvm '{ "var1" : "value1", ... }' my_contract.abi.json
Being able to specify the initial values of static variables with
ft contrat --build
orft contract --deploy
(whichever is the most suitable) would be a valuable addition to ft.The text was updated successfully, but these errors were encountered: