22 #include "twa/twagraph.hh"
23 #include "misc/location.hh"
24 #include "tl/defaultenv.hh"
29 #include <misc/bitvect.hh>
43 struct parse_aut_error_list {};
46 enum class parsed_aut_type { HOA, NeverClaim, LBTT, DRA, DSA, Unknown };
61 parsed_aut_type type = parsed_aut_type::Unknown;
77 bool format_errors(std::ostream& os);
80 typedef std::shared_ptr<parsed_aut> parsed_aut_ptr;
81 typedef std::shared_ptr<const parsed_aut> const_parsed_aut_ptr;
112 spot::location last_loc;
113 std::string filename_;
137 const std::string& filename,
157 parsed_aut_ptr parse(
const bdd_dict_ptr& dict,
178 SPOT_API parsed_aut_ptr
180 const bdd_dict_ptr& dict,
static default_environment & instance()
Get the sole instance of spot::default_environment.
std::pair< spot::location, std::string > parse_aut_error
A parse diagnostic with its location.
Definition: public.hh:38
Result of the automaton parser.
Definition: public.hh:49
An environment that describes atomic propositions.
Definition: environment.hh:32
twa_graph_ptr aut
The parsed automaton.
Definition: public.hh:55
bool debug
Run the parser in debug mode?
Definition: public.hh:86
bool trust_hoa
Trust properties in HOA files.
Definition: public.hh:87
std::list< parse_aut_error > parse_aut_error_list
A list of parser diagnostics, as filled by parse.
Definition: public.hh:40
bool ignore_abort
Skip aborted automata.
Definition: public.hh:85
bool raise_errors
Raise errors as exceptions.
Definition: public.hh:88
spot::location loc
Location of the automaton in the stream.
Definition: public.hh:59
const std::string filename
Name of the stream (used for displaying syntax errors)
Definition: public.hh:63
parsed_aut_ptr parse_aut(const std::string &filename, const bdd_dict_ptr &dict, environment &env=default_environment::instance(), automaton_parser_options opts={})
Read the first spot::twa_graph from a file.
parse_aut_error_list errors
Syntax errors that occurred during parsing.
Definition: public.hh:68
Parse a stream of automata.
Definition: public.hh:110