示例#1
0
Statement *TypeCompiler::visit(VariableStatement *statement)
{
    for (unsigned int i = 0; i < statement->declarations->size(); i++)
    {
        VariableDeclaration *d = statement->declarations->at(i);
        d->visitExpression(this);
    }

    return statement;
}
示例#2
0
Expression *TypeCompiler::visit(VariableExpression *expression)
{
    for (UTsize i = 0; i < expression->declarations->size(); i++)
    {
        VariableDeclaration *v = expression->declarations->at(i);
        v->visitExpression(this);
        expression->e = v->identifier->e;
    }

    return expression;
}