mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
yul fuzzer: Permit upto 7 I/O function parameters (previously 4).
This commit is contained in:
@@ -869,6 +869,18 @@ void ProtoConverter::visitFunctionInputParams(FunctionCall const& _x, unsigned _
|
|||||||
// We reverse the order of function input visits since it helps keep this switch case concise.
|
// We reverse the order of function input visits since it helps keep this switch case concise.
|
||||||
switch (_numInputParams)
|
switch (_numInputParams)
|
||||||
{
|
{
|
||||||
|
case 7:
|
||||||
|
visit(_x.in_param7());
|
||||||
|
m_output << ", ";
|
||||||
|
[[fallthrough]];
|
||||||
|
case 6:
|
||||||
|
visit(_x.in_param6());
|
||||||
|
m_output << ", ";
|
||||||
|
[[fallthrough]];
|
||||||
|
case 5:
|
||||||
|
visit(_x.in_param5());
|
||||||
|
m_output << ", ";
|
||||||
|
[[fallthrough]];
|
||||||
case 4:
|
case 4:
|
||||||
visit(_x.in_param4());
|
visit(_x.in_param4());
|
||||||
m_output << ", ";
|
m_output << ", ";
|
||||||
|
|||||||
@@ -340,8 +340,8 @@ private:
|
|||||||
/// Map of object name to list of sub-object namespace(s) in scope
|
/// Map of object name to list of sub-object namespace(s) in scope
|
||||||
std::map<std::string, std::vector<std::string>> m_objectScope;
|
std::map<std::string, std::vector<std::string>> m_objectScope;
|
||||||
// mod input/output parameters impose an upper bound on the number of input/output parameters a function may have.
|
// mod input/output parameters impose an upper bound on the number of input/output parameters a function may have.
|
||||||
static unsigned constexpr s_modInputParams = 5;
|
static unsigned constexpr s_modInputParams = 8;
|
||||||
static unsigned constexpr s_modOutputParams = 5;
|
static unsigned constexpr s_modOutputParams = 8;
|
||||||
/// Hard-coded identifier for a Yul object's data block
|
/// Hard-coded identifier for a Yul object's data block
|
||||||
static auto constexpr s_dataIdentifier = "datablock";
|
static auto constexpr s_dataIdentifier = "datablock";
|
||||||
/// Predicate to keep track of for body scope. If false, break/continue
|
/// Predicate to keep track of for body scope. If false, break/continue
|
||||||
|
|||||||
@@ -62,10 +62,16 @@ message FunctionCall {
|
|||||||
required Expression in_param2 = 2;
|
required Expression in_param2 = 2;
|
||||||
required Expression in_param3 = 3;
|
required Expression in_param3 = 3;
|
||||||
required Expression in_param4 = 4;
|
required Expression in_param4 = 4;
|
||||||
required VarRef out_param1 = 5;
|
required Expression in_param5 = 5;
|
||||||
required VarRef out_param2 = 6;
|
required Expression in_param6 = 6;
|
||||||
required VarRef out_param3 = 7;
|
required Expression in_param7 = 7;
|
||||||
required VarRef out_param4 = 8;
|
required VarRef out_param1 = 8;
|
||||||
|
required VarRef out_param2 = 9;
|
||||||
|
required VarRef out_param3 = 10;
|
||||||
|
required VarRef out_param4 = 11;
|
||||||
|
required Expression out_param5 = 12;
|
||||||
|
required Expression out_param6 = 13;
|
||||||
|
required Expression out_param7 = 14;
|
||||||
}
|
}
|
||||||
|
|
||||||
message TypedVarDecl {
|
message TypedVarDecl {
|
||||||
|
|||||||
Reference in New Issue
Block a user