diff options
author | Clifford Wolf <clifford@clifford.at> | 2013-08-11 13:33:38 +0200 |
---|---|---|
committer | Clifford Wolf <clifford@clifford.at> | 2013-08-11 13:33:38 +0200 |
commit | 080f0aac3490114c483cc37c1febd0698970d0fe (patch) | |
tree | 208dbd8b5ed81742d57ca528a841714e0fd11450 /kernel | |
parent | 6068b8902f1e182a404423cdf686643719bbfdd7 (diff) | |
download | yosys-080f0aac3490114c483cc37c1febd0698970d0fe.tar.gz yosys-080f0aac3490114c483cc37c1febd0698970d0fe.tar.bz2 yosys-080f0aac3490114c483cc37c1febd0698970d0fe.zip |
Added ";;" as shortcut for "; clean;"
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/register.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/kernel/register.cc b/kernel/register.cc index f6f5804b5..9f6fe37d3 100644 --- a/kernel/register.cc +++ b/kernel/register.cc @@ -149,12 +149,15 @@ void Pass::call(RTLIL::Design *design, std::string command) std::string str = p; int strsz = str.size(); if (strsz > 0 && str[strsz-1] == ';') { + int num_semikolon = 0; while (strsz > 0 && str[strsz-1] == ';') - strsz--; + strsz--, num_semikolon++; if (strsz > 0) args.push_back(str.substr(0, strsz)); call(design, args); args.clear(); + if (num_semikolon == 2) + call(design, "clean"); } else args.push_back(str); } |