|
|
@ -492,7 +492,7 @@ function addParams (parameterList, tree, scopeId, states, contractObj, sourceLoc |
|
|
|
let location = extractLocationFromAstVariable(param) |
|
|
|
let location = extractLocationFromAstVariable(param) |
|
|
|
location = location === 'default' ? 'memory' : location |
|
|
|
location = location === 'default' ? 'memory' : location |
|
|
|
const attributesName = param.name === '' ? `$${inputParam}` : param.name |
|
|
|
const attributesName = param.name === '' ? `$${inputParam}` : param.name |
|
|
|
tree.scopes[scopeId].locals[attributesName] = { |
|
|
|
const newParam = { |
|
|
|
name: attributesName, |
|
|
|
name: attributesName, |
|
|
|
type: parseType(param.typeDescriptions.typeString, states, contractName, location), |
|
|
|
type: parseType(param.typeDescriptions.typeString, states, contractName, location), |
|
|
|
stackDepth: stackDepth, |
|
|
|
stackDepth: stackDepth, |
|
|
@ -500,7 +500,9 @@ function addParams (parameterList, tree, scopeId, states, contractObj, sourceLoc |
|
|
|
abi: contractObj.contract.abi, |
|
|
|
abi: contractObj.contract.abi, |
|
|
|
isParameter: true |
|
|
|
isParameter: true |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
tree.scopes[scopeId].locals[attributesName] = newParam |
|
|
|
params.push(attributesName) |
|
|
|
params.push(attributesName) |
|
|
|
|
|
|
|
if (!tree.variables[param.id]) tree.variables[param.id] = newParam |
|
|
|
} |
|
|
|
} |
|
|
|
stackPosition += dir |
|
|
|
stackPosition += dir |
|
|
|
} |
|
|
|
} |
|
|
|