std::string source;
std::string source_name;
+ unsigned source_index;
unsigned current_line;
std::string::const_iterator iter;
std::string::const_iterator source_end;
ProgramParser();
~ProgramParser();
- ProgramSyntax::Module &parse(const std::string &, const std::string &);
- ProgramSyntax::Module &parse(IO::Base &, const std::string &);
+ ProgramSyntax::Module &parse(const std::string &, const std::string &, unsigned = 0);
+ ProgramSyntax::Module &parse(IO::Base &, const std::string &, unsigned = 0);
private:
void parse_source();
bool is_identifier(const std::string &);
void preprocess();
+ void preprocess_version();
void preprocess_pragma();
void preprocess_pragma_msp();
void preprocess_stage();