* iface/gspn/gspn.cc, src/ltlvisit/basicreduce.cc,
src/ltlvisit/destroy.cc, src/ltlvisit/dotty.cc,
src/ltlvisit/dump.cc, src/ltlvisit/length.cc,
src/ltlvisit/nenoform.cc, src/ltlvisit/reduce.cc,
src/ltlvisit/syntimpl.cc, src/ltlvisit/tostring.cc,
src/tgba/formula2bdd.cc, src/tgba/tgbabddconcreteproduct.cc,
src/tgba/tgbatba.cc, src/tgbaalgos/dotty.cc,
src/tgbaalgos/dupexp.cc, src/tgbaalgos/lbtt.cc,
src/tgbaalgos/ltl2tgba_lacim.cc, src/tgbaalgos/neverclaim.cc,
src/tgbaalgos/save.cc, src/tgbaalgos/stats.cc,
src/tgbaalgos/gtec/nsheap.cc, src/tgbaalgos/gtec/nsheap.hh:
Declare private classes and helper function in anonymous namespaces.
* HACKING, src/sanity/style.test: Document and check this.
Also check for trailing { after namespace or class.
* src/ltlast/predecl.hh, src/ltlast/visitor.hh,
src/tgba/tgbareduc.hh: Fix trailing {.
This commit is contained in:
parent
5176caf4d2
commit
7d27fd3796
28 changed files with 3128 additions and 3025 deletions
|
|
@ -28,66 +28,68 @@ namespace spot
|
|||
{
|
||||
namespace ltl
|
||||
{
|
||||
|
||||
class dump_visitor : public const_visitor
|
||||
namespace
|
||||
{
|
||||
public:
|
||||
dump_visitor(std::ostream& os)
|
||||
: os_(os)
|
||||
class dump_visitor: public const_visitor
|
||||
{
|
||||
}
|
||||
public:
|
||||
dump_visitor(std::ostream& os)
|
||||
: os_(os)
|
||||
{
|
||||
}
|
||||
|
||||
virtual
|
||||
~dump_visitor()
|
||||
{
|
||||
}
|
||||
virtual
|
||||
~dump_visitor()
|
||||
{
|
||||
}
|
||||
|
||||
void
|
||||
visit(const atomic_prop* ap)
|
||||
{
|
||||
os_ << "AP(" << ap->name() << ")";
|
||||
}
|
||||
void
|
||||
visit(const atomic_prop* ap)
|
||||
{
|
||||
os_ << "AP(" << ap->name() << ")";
|
||||
}
|
||||
|
||||
void
|
||||
visit(const constant* c)
|
||||
{
|
||||
os_ << "constant(" << c->val_name() << ")";
|
||||
}
|
||||
void
|
||||
visit(const constant* c)
|
||||
{
|
||||
os_ << "constant(" << c->val_name() << ")";
|
||||
}
|
||||
|
||||
void
|
||||
visit(const binop* bo)
|
||||
{
|
||||
os_ << "binop(" << bo->op_name() << ", ";
|
||||
bo->first()->accept(*this);
|
||||
os_ << ", ";
|
||||
bo->second()->accept(*this);
|
||||
os_ << ")";
|
||||
}
|
||||
void
|
||||
visit(const binop* bo)
|
||||
{
|
||||
os_ << "binop(" << bo->op_name() << ", ";
|
||||
bo->first()->accept(*this);
|
||||
os_ << ", ";
|
||||
bo->second()->accept(*this);
|
||||
os_ << ")";
|
||||
}
|
||||
|
||||
void
|
||||
visit(const unop* uo)
|
||||
{
|
||||
os_ << "unop(" << uo->op_name() << ", ";
|
||||
uo->child()->accept(*this);
|
||||
os_ << ")";
|
||||
}
|
||||
void
|
||||
visit(const unop* uo)
|
||||
{
|
||||
os_ << "unop(" << uo->op_name() << ", ";
|
||||
uo->child()->accept(*this);
|
||||
os_ << ")";
|
||||
}
|
||||
|
||||
void
|
||||
visit(const multop* mo)
|
||||
{
|
||||
os_ << "multop(" << mo->op_name() << ", ";
|
||||
unsigned max = mo->size();
|
||||
mo->nth(0)->accept(*this);
|
||||
for (unsigned n = 1; n < max; ++n)
|
||||
{
|
||||
os_ << ", ";
|
||||
mo->nth(n)->accept(*this);
|
||||
}
|
||||
os_ << ")";
|
||||
}
|
||||
private:
|
||||
std::ostream& os_;
|
||||
};
|
||||
void
|
||||
visit(const multop* mo)
|
||||
{
|
||||
os_ << "multop(" << mo->op_name() << ", ";
|
||||
unsigned max = mo->size();
|
||||
mo->nth(0)->accept(*this);
|
||||
for (unsigned n = 1; n < max; ++n)
|
||||
{
|
||||
os_ << ", ";
|
||||
mo->nth(n)->accept(*this);
|
||||
}
|
||||
os_ << ")";
|
||||
}
|
||||
private:
|
||||
std::ostream& os_;
|
||||
};
|
||||
}
|
||||
|
||||
std::ostream&
|
||||
dump(std::ostream& os, const formula* f)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue