Added support for #-comments in same line as command
authorClifford Wolf <clifford@clifford.at>
Thu, 6 Feb 2014 13:26:39 +0000 (14:26 +0100)
committerClifford Wolf <clifford@clifford.at>
Thu, 6 Feb 2014 13:26:39 +0000 (14:26 +0100)
kernel/register.cc

index 949d7c628e0c1974837268265408b21ae88c8787..10ba4f2747ad68e516b1e7ad4d6f87f7356e5cbf 100644 (file)
@@ -148,6 +148,8 @@ void Pass::call(RTLIL::Design *design, std::string command)
        for (char *p = strtok_r(s, " \t\r\n", &saveptr); p; p = strtok_r(NULL, " \t\r\n", &saveptr)) {
                std::string str = p;
                int strsz = str.size();
+               if (str == "#")
+                       break;
                if (strsz > 0 && str[strsz-1] == ';') {
                        int num_semikolon = 0;
                        while (strsz > 0 && str[strsz-1] == ';')