Only provide code generator to CodeTransform.

This commit is contained in:
chriseth
2021-08-04 18:38:10 +02:00
parent 2d5b9036c2
commit 467cbf92bc
6 changed files with 22 additions and 26 deletions
+5 -5
View File
@@ -65,7 +65,7 @@ class CodeTransform
{
public:
/// Create the code transformer.
/// @param _identifierAccess used to resolve identifiers external to the inline assembly
/// @param _identifierAccessCodeGen used to generate code for identifiers external to the inline assembly
/// As a side-effect of its construction, translates the Yul code and appends it to the
/// given assembly.
/// Throws StackTooDeepError if a variable is not accessible or if a function has too
@@ -77,7 +77,7 @@ public:
EVMDialect const& _dialect,
BuiltinContext& _builtinContext,
bool _allowStackOpt = false,
ExternalIdentifierAccess const& _identifierAccess = ExternalIdentifierAccess(),
ExternalIdentifierAccess::CodeGenerator const& _identifierAccessCodeGen = {},
bool _useNamedLabelsForFunctions = false
): CodeTransform(
_assembly,
@@ -86,7 +86,7 @@ public:
_allowStackOpt,
_dialect,
_builtinContext,
_identifierAccess,
_identifierAccessCodeGen,
_useNamedLabelsForFunctions,
nullptr,
{},
@@ -107,7 +107,7 @@ protected:
bool _allowStackOpt,
EVMDialect const& _dialect,
BuiltinContext& _builtinContext,
ExternalIdentifierAccess _identifierAccess,
ExternalIdentifierAccess::CodeGenerator _identifierAccessCodeGen,
bool _useNamedLabelsForFunctions,
std::shared_ptr<Context> _context,
std::vector<TypedName> _delayedReturnVariables,
@@ -193,7 +193,7 @@ private:
BuiltinContext& m_builtinContext;
bool const m_allowStackOpt = true;
bool const m_useNamedLabelsForFunctions = false;
ExternalIdentifierAccess m_identifierAccess;
ExternalIdentifierAccess::CodeGenerator m_identifierAccessCodeGen;
std::shared_ptr<Context> m_context;
/// Set of variables whose reference counter has reached zero,