Add support for [+].
* src/ltlast/bunop.cc (bunop::format): Output [*1..] as [+]. * src/ltlvisit/tostring.cc: Output "a*" as "a[*]" for consistency. * src/ltlparse/ltlparse.yy, src/ltlparse/ltlscan.ll: Recognize [+]. * src/ltltest/tostring.test, src/ltltest/equals.test, src/tgbatest/ltl2tgba.test: More tests.
This commit is contained in:
parent
126b724a98
commit
567b460738
7 changed files with 28 additions and 12 deletions
|
|
@ -119,6 +119,14 @@ namespace spot
|
|||
bunop::format() const
|
||||
{
|
||||
std::ostringstream out;
|
||||
|
||||
// Syntactic sugaring
|
||||
if (min_ == 1 && max_ == unbounded)
|
||||
{
|
||||
out << "[+]";
|
||||
return out.str();
|
||||
}
|
||||
|
||||
out << "[*";
|
||||
if (min_ != 0 || max_ != unbounded)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue