feature(@packages/solidity): include ast in compiled object

This commit is contained in:
Iuri Matias 2020-01-14 16:26:19 -05:00
parent e2767c27a9
commit c395826c53
1 changed files with 1 additions and 0 deletions

View File

@ -157,6 +157,7 @@ class Solidity {
compiled_object[className].functionHashes = contract.evm.methodIdentifiers; compiled_object[className].functionHashes = contract.evm.methodIdentifiers;
compiled_object[className].abiDefinition = contract.abi; compiled_object[className].abiDefinition = contract.abi;
compiled_object[className].userdoc = contract.userdoc; compiled_object[className].userdoc = contract.userdoc;
compiled_object[className].ast = output.sources[contractFile].ast;
compiled_object[className].filename = filename; compiled_object[className].filename = filename;
const normalized = path.normalize(filename); const normalized = path.normalize(filename);
compiled_object[className].originalFilename = Object.values(originalFilepaths).find(ogFilePath => normalized.indexOf(ogFilePath) > -1); compiled_object[className].originalFilename = Object.values(originalFilepaths).find(ogFilePath => normalized.indexOf(ogFilePath) > -1);