souffle
2.0.2-371-g6315b36
|
Transformation pass to remove all empty relations and rules that use empty relations. More...
#include <RemoveEmptyRelations.h>
Public Member Functions | |
RemoveEmptyRelationsTransformer * | clone () const override |
std::string | getName () const override |
Public Member Functions inherited from souffle::ast::transform::Transformer | |
bool | apply (TranslationUnit &translationUnit) |
virtual | ~Transformer ()=default |
Static Public Member Functions | |
static bool | removeEmptyRelations (TranslationUnit &translationUnit) |
Eliminate all empty relations (and their uses) in the given program. More... | |
Private Member Functions | |
bool | transform (TranslationUnit &translationUnit) override |
Static Private Member Functions | |
static bool | removeEmptyRelationUses (TranslationUnit &translationUnit, const QualifiedName &emptyRelation) |
Eliminate rules that contain empty relations and/or rewrite them. More... | |
Transformation pass to remove all empty relations and rules that use empty relations.
Definition at line 31 of file RemoveEmptyRelations.h.
|
inlineoverridevirtual |
Implements souffle::ast::transform::Transformer.
Definition at line 49 of file RemoveEmptyRelations.h.
|
inlineoverridevirtual |
Implements souffle::ast::transform::Transformer.
Definition at line 37 of file RemoveEmptyRelations.h.
|
static |
Eliminate all empty relations (and their uses) in the given program.
translationUnit | the program to be processed |
Definition at line 40 of file RemoveEmptyRelations.cpp.
References souffle::ast::Aggregator::getBodyLiterals(), souffle::ast::getClauses(), rel(), and souffle::ast::visitDepthFirst().
|
staticprivate |
Eliminate rules that contain empty relations and/or rewrite them.
translationUnit | the program to be processed |
emptyRelation | relation that is empty |
Definition at line 75 of file RemoveEmptyRelations.cpp.
References clauses.
|
inlineoverrideprivatevirtual |
Implements souffle::ast::transform::Transformer.
Definition at line 54 of file RemoveEmptyRelations.h.