| 1026 | } |
| 1027 | |
| 1028 | std::optional<Json> CompilerStack::yulIRAst(std::string const& _contractName) const |
| 1029 | { |
| 1030 | solAssert(m_stackState == CompilationSuccessful, "Compilation was not successful."); |
| 1031 | solUnimplementedAssert(!isExperimentalSolidity()); |
| 1032 | |
| 1033 | // NOTE: Intentionally not using LazyInit. The artifact can get very large and we don't want to |
| 1034 | // keep it around when compiling a large project containing many contracts. |
| 1035 | Contract const& currentContract = contract(_contractName); |
| 1036 | yulAssert(currentContract.contract); |
| 1037 | yulAssert(currentContract.yulIR.has_value() == currentContract.contract->canBeDeployed()); |
| 1038 | if (!currentContract.yulIR) |
| 1039 | return std::nullopt; |
| 1040 | return loadGeneratedIR(*currentContract.yulIR).astJson(); |
| 1041 | } |
| 1042 | |
| 1043 | std::optional<Json> CompilerStack::yulCFGJson(std::string const& _contractName) const |
| 1044 | { |
no test coverage detected