EOL is now accepted as ';' replacement on lines that look like: feature_xyz(option)
authorNiels Moseley <n.a.moseley@moseleyinstruments.com>
Mon, 25 Mar 2019 11:15:10 +0000 (12:15 +0100)
committerNiels Moseley <n.a.moseley@moseleyinstruments.com>
Mon, 25 Mar 2019 11:15:10 +0000 (12:15 +0100)
passes/techmap/libparse.cc

index 878ca31605b65517217dd4f2f08eaf21a99298ac..9dc3e96ab44f6dacafa2df83b9c7af1db1dda5dc 100644 (file)
@@ -202,12 +202,11 @@ LibertyAst *LibertyParser::parse()
        {
                tok = lexer(str);
 
-               if (tok == ';')
+        // allow both ';' and new lines to 
+        // terminate a statement.
+               if ((tok == ';') || (tok == 'n'))
                        break;
 
-               if (tok == 'n')
-                       continue;
-
                if (tok == ':' && ast->value.empty()) {
                        tok = lexer(ast->value);
                        if (tok != 'v')