Include file:

#include "mcrl2/data/selection.h
class mcrl2::data::used_data_equation_selector

Component for selecting a subset of equations that are actually used in an encompassing specification.

This component can be used with the constructor of data::rewriter derived classes to select a smaller set of equations that are used as rewrite rules. This limited set of rewrite rules should be enough for the purpose of rewriting objects that occur in the encompassing specification (the context).Use of this component can have a dramatic effect of rewriter initialisation time and overall performance.

Private attributes

bool add_all
std::set<function_symbol> m_used_symbols

Private member functions

void add_symbol(const function_symbol &f)
void add_symbols(Range const &r)

Protected member functions

void add_data_specification_symbols(const data_specification &specification)

Public member functions

void add_function_symbols(const data_expression &t)
bool operator()(const data::function_symbol &f) const

Check whether the symbol is used.

bool operator()(const data_equation &e) const

Check whether data equation relates to used symbols, and therefore is important.


default constructor

used_data_equation_selector(data_specification const &data_spec, Range const &context)

context is a range of function symbols

used_data_equation_selector(const data_specification &specification, const std::set<function_symbol> &function_symbols, const std::set<data::variable> &global_variables)
used_data_equation_selector(const data_specification&)

select all equations