Consistent terminology for attached/bound functions

This commit is contained in:
wechman
2022-12-07 19:31:41 +01:00
committed by Kamil Śliwak
parent 1c8745c54a
commit 64a4f32bc2
42 changed files with 132 additions and 133 deletions
+4 -4
View File
@@ -3120,12 +3120,12 @@ vector<smtutil::Expression> SMTEncoder::symbolicArguments(FunctionCall const& _f
vector<ASTPointer<Expression const>> arguments = _funCall.sortedArguments();
auto functionParams = funDef->parameters();
unsigned firstParam = 0;
if (funType->bound())
if (funType->hasBoundFirstArgument())
{
calledExpr = innermostTuple(*calledExpr);
auto const& boundFunction = dynamic_cast<MemberAccess const*>(calledExpr);
solAssert(boundFunction, "");
args.push_back(expr(boundFunction->expression(), functionParams.front()->type()));
auto const& attachedFunction = dynamic_cast<MemberAccess const*>(calledExpr);
solAssert(attachedFunction, "");
args.push_back(expr(attachedFunction->expression(), functionParams.front()->type()));
firstParam = 1;
}
+1 -1
View File
@@ -401,7 +401,7 @@ protected:
void createReturnedExpressions(FunctionCall const& _funCall, ContractDefinition const* _contextContract);
/// @returns the symbolic arguments for a function call,
/// taking into account bound functions and
/// taking into account attached functions and
/// type conversion.
std::vector<smtutil::Expression> symbolicArguments(FunctionCall const& _funCall, ContractDefinition const* _contextContract);