25 #ifndef SPOT_LTLAST_UNOP_HH
26 # define SPOT_LTLAST_UNOP_HH
49 Closure, NegClosure, NegClosureMarked
91 virtual void accept(
visitor& v)
const;
99 const char* op_name()
const;
102 virtual std::string
dump()
const;
105 static unsigned instance_count();
108 static std::ostream& dump_instances(std::ostream& os);
111 typedef std::pair<type, const formula*> pair;
112 typedef std::map<pair, const unop*> map;
113 static map instances;
132 if (f->
kind() != formula::UnOp)
134 return static_cast<const unop*
>(f);
143 is_unop(
const formula* f, unop::type op)
145 if (
const unop* uo = is_unop(f))
156 is_Not(
const formula* f)
158 return is_unop(f, unop::Not);
166 is_X(
const formula* f)
168 return is_unop(f, unop::X);
176 is_F(
const formula* f)
178 return is_unop(f, unop::F);
186 is_G(
const formula* f)
188 return is_unop(f, unop::G);
196 is_GF(
const formula* f)
198 if (
const unop* op = is_G(f))
199 return is_F(op->child());
208 is_FG(
const formula* f)
210 if (
const unop* op = is_F(f))
211 return is_G(op->child());
217 #endif // SPOT_LTLAST_UNOP_HH
Formula visitor.
Definition: visitor.hh:41
SPOT_API std::ostream & dump(std::ostream &os, const formula *f)
Dump a formula tree.
Unary operators.
Definition: unop.hh:40