Open 0kenx opened 3 weeks ago
contract B { owner: Address; init(addr: Address){ self.owner = addr; } } fun get_init(addr: Address): StateInit { return initOf B(addr); } contract A { receive("aa") { let c: StateInit = get_init(myAddress()); // fails // let c: StateInit = initOf B(myAddress()); // succeeds } }
Build succeeds but execution fails with exit code 135: Code of a contract was not found
Moreover, the following also compiles
fun get_init(): StateInit { return initOf B(myAddress()); }
but clearly the context of the calling contract is not preserved when calling myAddress() from an external function.
myAddress()
Build succeeds but execution fails with exit code 135: Code of a contract was not found
Moreover, the following also compiles
but clearly the context of the calling contract is not preserved when calling
myAddress()
from an external function.