コード例 #1
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::FunctionDec & e)
{
    context.pushFn(&e);
    auto range = preCheck(e);
    e.getBody().accept(*this);
    postCheck(e, range);

    context.popFn();
}
コード例 #2
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::ForExp & e)
{
    context.pushLoop(&e);
    auto range = preCheck(e);
    e.getVardec().accept(*this);
    e.getBody().accept(*this);
    postCheck(e, range);
    context.popLoop();
}
コード例 #3
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::MatrixLineExp & e)
{
    auto range = preCheck(e);
    const ast::exps_t & columns = e.getColumns();
    for (const auto column : columns)
    {
        column->accept(*this);
    }
    postCheck(e, range);
}
コード例 #4
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::CellExp & e)
{
    auto range = preCheck(e);
    ast::exps_t lines = e.getLines();
    for (ast::exps_t::const_iterator it = lines.begin(), itEnd = lines.end(); it != itEnd ; ++it)
    {
        (*it)->accept(*this);
    }
    postCheck(e, range);
}
コード例 #5
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::AssignListExp & e)
{
    auto range = preCheck(e);
    const ast::exps_t & exps = e.getExps();
    for (ast::exps_t::const_iterator it = exps.begin(), itEnd = exps.end(); it != itEnd; ++it)
    {
        (*it)->accept(*this);
    }
    postCheck(e, range);
}
コード例 #6
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::ArrayListVar & e)
{
    auto range = preCheck(e);
    ast::exps_t vars = e.getVars();
    for (ast::exps_t::const_iterator it = vars.begin (), itEnd = vars.end(); it != itEnd; ++it)
    {
        (*it)->accept(*this);
    }
    postCheck(e, range);
}
コード例 #7
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::ListExp & e)
{
    auto range = preCheck(e);
    e.getStart().accept(*this);
    if (e.hasExplicitStep())
    {
        e.getStep().accept(*this);
    }
    e.getEnd().accept(*this);
    postCheck(e, range);
}
コード例 #8
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::IfExp & e)
{
    auto range = preCheck(e);
    e.getTest().accept(*this);
    e.getThen().accept(*this);
    if (e.hasElse())
    {
        e.getElse().accept(*this);
    }
    postCheck(e, range);
}
コード例 #9
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::CellCallExp & e)
{
    auto range = preCheck(e);
    e.getName().accept(*this);

    ast::exps_t args = e.getArgs();
    for (auto arg : args)
    {
        arg->accept(*this);
    }
    postCheck(e, range);
}
コード例 #10
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::SeqExp & e)
{
    const ast::exps_t & exps = e.getExps();
    seqExpIts.emplace(exps.begin(), exps.end());
    auto range = preCheck(e);
    ast::exps_t::const_iterator & seqExpIt = seqExpIts.top().first;
    const ast::exps_t::const_iterator & seqExpEnd = seqExpIts.top().second;
    for (; seqExpIt != seqExpEnd; ++seqExpIt)
    {
        (*seqExpIt)->accept(*this);
    }
    postCheck(e, range);
    seqExpIts.pop();
}
コード例 #11
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::SelectExp & e)
{
    auto range = preCheck(e);
    e.getSelect()->accept(*this);

    ast::exps_t cases = e.getCases();
    for (auto exp : cases)
    {
        exp->accept(*this);
    }

    if (e.getDefaultCase() != NULL)
    {
        e.getDefaultCase()->accept(*this);
    }

    postCheck(e, range);
}
コード例 #12
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::MemfillExp & e)
{
    auto range = preCheck(e);
    e.getOriginal()->accept(*this);
    postCheck(e, range);
}
コード例 #13
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::VarDec & e)
{
    auto range = preCheck(e);
    e.getInit().accept(*this);
    postCheck(e, range);
}
コード例 #14
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::TransposeExp & e)
{
    auto range = preCheck(e);
    e.getExp().accept(*this);
    postCheck(e, range);
}
コード例 #15
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::ColonVar & e)
{
    auto range = preCheck(e);

    postCheck(e, range);
}
コード例 #16
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::ContinueExp & e)
{
    auto range = preCheck(e);

    postCheck(e, range);
}
コード例 #17
0
void moduleAP::sPostCheck()
{
  postCheck(parent, "", TRUE).exec();
}
コード例 #18
0
void menuAccounting::sPostCheck()
{
  postCheck(parent, "", TRUE).exec();
}
コード例 #19
0
ファイル: SLintVisitor.cpp プロジェクト: adrianafs/scilab
void SLintVisitor::visit(const ast::BreakExp & e)
{
    auto range = preCheck(e);

    postCheck(e, range);
}