ltlcross: diagnose missing i/o specifications earlier.
* src/misc/formater.cc, src/misc/formater.hh (scan): New method. (prime): Use it. * src/bin/ltlcross.cc (translator_runner::translator_runner): Scan each specification string, and report those missing an input or output %-sequence. * NEWS: Mention it.
This commit is contained in:
parent
edd687a301
commit
6a547371d7
4 changed files with 52 additions and 12 deletions
|
|
@ -1,6 +1,6 @@
|
|||
// -*- coding: utf-8 -*-
|
||||
// Copyright (C) 2012 Laboratoire de Recherche et Développement de
|
||||
// l'Epita (LRDE).
|
||||
// Copyright (C) 2012, 2013 Laboratoire de Recherche et Développement
|
||||
// de l'Epita (LRDE).
|
||||
//
|
||||
// This file is part of Spot, a model checking library.
|
||||
//
|
||||
|
|
@ -117,16 +117,32 @@ namespace spot
|
|||
{
|
||||
}
|
||||
|
||||
/// \brief Scan the %-sequences occuring in \a fmt.
|
||||
///
|
||||
/// Set has['c'] for each %c in \a fmt. \a has must
|
||||
/// be 256 wide.
|
||||
/// @{
|
||||
void
|
||||
scan(const char* fmt, std::vector<bool>& has) const;
|
||||
|
||||
void
|
||||
scan(const std::string& fmt, std::vector<bool>& has) const
|
||||
{
|
||||
scan(fmt.c_str(), has);
|
||||
}
|
||||
/// @}
|
||||
|
||||
/// Collect the %-sequences occurring in \a fmt.
|
||||
/// @{
|
||||
void
|
||||
prime(const char* fmt);
|
||||
|
||||
/// Collect the %-sequences occurring in \a fmt.
|
||||
void
|
||||
prime(const std::string& fmt)
|
||||
{
|
||||
prime(fmt.c_str());
|
||||
}
|
||||
/// @}
|
||||
|
||||
/// Whether %c occurred in the primed formats.
|
||||
bool
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue