Line data Source code
1 : // Author(s): Wieger Wesselink 2 : // Copyright: see the accompanying file COPYING or copy at 3 : // https://github.com/mCRL2org/mCRL2/blob/master/COPYING 4 : // 5 : // Distributed under the Boost Software License, Version 1.0. 6 : // (See accompanying file LICENSE_1_0.txt or copy at 7 : // http://www.boost.org/LICENSE_1_0.txt) 8 : // 9 : /// \file mcrl2/pbes/detail/occurring_variable_visitor.h 10 : /// \brief Add your file description here. 11 : 12 : #ifndef MCRL2_PBES_DETAIL_OCCURRING_VARIABLE_VISITOR_H 13 : #define MCRL2_PBES_DETAIL_OCCURRING_VARIABLE_VISITOR_H 14 : 15 : #include "mcrl2/pbes/traverser.h" 16 : 17 : namespace mcrl2 18 : { 19 : 20 : namespace pbes_system 21 : { 22 : 23 : namespace detail 24 : { 25 : 26 : struct occurring_variable_visitor: public pbes_expression_traverser<occurring_variable_visitor> 27 : { 28 : typedef pbes_expression_traverser<occurring_variable_visitor> super; 29 : using super::enter; 30 : using super::leave; 31 : using super::apply; 32 : 33 : std::set<propositional_variable_instantiation> variables; 34 : 35 4226 : void apply(const propositional_variable_instantiation& x) 36 : { 37 4226 : variables.insert(x); 38 4226 : } 39 : }; 40 : 41 : } // namespace detail 42 : 43 : } // namespace pbes_system 44 : 45 : } // namespace mcrl2 46 : 47 : #endif // MCRL2_PBES_DETAIL_OCCURRING_VARIABLE_VISITOR_H