The config.json file defines an object contracts that is a key-value map from contract names to file paths (where to find the contract source code).
The contract as it is called inside the source code file needs to be the same as the key of the key value pair. The reason is that the program currently assumes that the compiled artifacts will be found at <key>.contract and <key>.wasm in the buildFolder. However, the Solidity compiler will always create the compiled artifacts under the names <contractName>.contract and <contractName>.wasm as it does not allow to specify the file name of the artifacts.
Thus, the subsequent call to wasm-opt will fail if the contract name and the source file name are different as it requires the source file at .contractand.wasm`.
The
config.json
file defines an objectcontracts
that is a key-value map from contract names to file paths (where to find the contract source code).The contract as it is called inside the source code file needs to be the same as the key of the key value pair. The reason is that the program currently assumes that the compiled artifacts will be found at
<key>.contract
and<key>.wasm
in thebuildFolder
. However, the Solidity compiler will always create the compiled artifacts under the names<contractName>.contract
and<contractName>.wasm
as it does not allow to specify the file name of the artifacts.Thus, the subsequent call to wasm-opt will fail if the contract name and the source file name are different as it requires the source file at.contract.wasm`.
and