diff options
author | Clifford Wolf <clifford@clifford.at> | 2013-12-27 15:05:52 +0100 |
---|---|---|
committer | Clifford Wolf <clifford@clifford.at> | 2013-12-27 15:05:52 +0100 |
commit | 72026a934ecfd072b2e0964a12ba4fdafc0f276e (patch) | |
tree | ae7ca07eb95e8bf5f18ff7d0f725b7ea83130c2b /frontends/verilog/preproc.cc | |
parent | ebf9abfeb6c65821ee4f1ef0f4ab16660348c45f (diff) | |
download | yosys-72026a934ecfd072b2e0964a12ba4fdafc0f276e.tar.gz yosys-72026a934ecfd072b2e0964a12ba4fdafc0f276e.tar.bz2 yosys-72026a934ecfd072b2e0964a12ba4fdafc0f276e.zip |
Fixed parsing of macros with no arguments and expansion text starting with "("
Diffstat (limited to 'frontends/verilog/preproc.cc')
-rw-r--r-- | frontends/verilog/preproc.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/frontends/verilog/preproc.cc b/frontends/verilog/preproc.cc index 023c4dbcc..501adf059 100644 --- a/frontends/verilog/preproc.cc +++ b/frontends/verilog/preproc.cc @@ -309,9 +309,10 @@ std::string frontend_verilog_preproc(FILE *f, std::string filename, const std::m std::map<std::string, int> args; skip_spaces(); name = next_token(true); - skip_spaces(); int newline_count = 0; int state = 0; + if (skip_spaces() != "") + state = 3; while (!tok.empty()) { tok = next_token(); if (state == 0 && tok == "(") { |