ROSE 0.11.145.192
|
Checking function that apply to the whole AST.
Two categories of checker: integrity and consistency If integrity checker reports defects then the consistency checker might fail. Similarly, if the edges integrity checker reports defects then the other integrity checkers might fail.
Functions | |
bool | all (SgProject *project) |
Apply all existing Checkers. | |
bool | integrity (SgProject *project) |
check multiple low-level properties of the AST's graph. | |
bool | integrity_edges (SgProject *project) |
for all valid node in the AST's graph check that the target of all edges are valid. | |
bool | integrity_declarations (SgProject *project) |
check all declaration subgraphs (1st-nondef / defn) | |
bool | integrity_symbols (SgProject *project) |
check all symbol subgraphs. | |
bool | integrity_types (SgProject *project) |
check all type subgraphs. | |
bool | consistency (SgProject *project) |
check (potentially complex) rules | |
bool Rose::AST::Checker::all | ( | SgProject * | project | ) |
Apply all existing Checkers.
project |
Run all integrity checkers followed by the consistency checkers if the former does not find any defects.
Any defect found is saved in Rose::AST::Defect::all (aka Rose::AST::Defects::defect_t<Defects::Kind::any>::all).
bool Rose::AST::Checker::integrity | ( | SgProject * | project | ) |
check multiple low-level properties of the AST's graph.
project |
Run all integrity checkers starting by the edge integrity checker then the other integrity checkers if the edges have no defect.
Any defect found is saved in Rose::AST::Defect::all (aka Rose::AST::Defects::defect_t<Defects::Kind::any>::all).
bool Rose::AST::Checker::integrity_edges | ( | SgProject * | project | ) |
for all valid node in the AST's graph check that the target of all edges are valid.
project |
Check the edges out of all allocated nodes in the memory pool. For each (non-null) edge, it looks for the pointer in all memory pools. If not found, an IntegrityEdgeDefect is produced with Reason::invalid. If found in an unexpected memory pool, an IntegrityEdgeDefect is produced with Reason::incompatible. If found but not marked as allocated, an IntegrityEdgeDefect is produced with Reason::unallocated. A single edge can yield two defects one with Reason::incompatible and the other with Reason::unallocated.
Any defect found is saved in Rose::AST::Defect::all (aka Rose::AST::Defects::defect_t<Defects::Kind::any>::all).
bool Rose::AST::Checker::integrity_declarations | ( | SgProject * | project | ) |
check all declaration subgraphs (1st-nondef / defn)
project |
Check ...
Any defect found is saved in Rose::AST::Defect::all (aka Rose::AST::Defects::defect_t<Defects::Kind::any>::all).
bool Rose::AST::Checker::integrity_symbols | ( | SgProject * | project | ) |
check all symbol subgraphs.
project |
Check ...
Any defect found is saved in Rose::AST::Defect::all (aka Rose::AST::Defects::defect_t<Defects::Kind::any>::all).
bool Rose::AST::Checker::integrity_types | ( | SgProject * | project | ) |
check all type subgraphs.
project |
Check ...
Any defect found is saved in Rose::AST::Defect::all (aka Rose::AST::Defects::defect_t<Defects::Kind::any>::all).
bool Rose::AST::Checker::consistency | ( | SgProject * | project | ) |
check (potentially complex) rules
project |
Check ...
Any defect found is saved in Rose::AST::Defect::all (aka Rose::AST::Defects::defect_t<Defects::Kind::any>::all).