MCPcopy Create free account
hub / github.com/argotorg/solidity / yulIRAst

Method yulIRAst

libsolidity/interface/CompilerStack.cpp:1028–1041  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1026}
1027
1028std::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
1043std::optional<Json> CompilerStack::yulCFGJson(std::string const& _contractName) const
1044{

Callers 2

compileSolidityMethod · 0.80
handleIRAstMethod · 0.80

Calls 2

canBeDeployedMethod · 0.80
astJsonMethod · 0.80

Tested by

no test coverage detected