Skip to content

Commit bcbc0d2

Browse files
committed
double backslash fix
1 parent 00702e1 commit bcbc0d2

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

netlist_bitblast/src/BitBlaster.cpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,17 @@ namespace BITBLAST {
3939
std::string BitBlaster::filterIcarusSDFUnsupportedCharacters(
4040
const std::string &st) {
4141
std::string result;
42+
char c_1 = ' ';
4243
for (uint32_t i = 0; i < st.size(); i++) {
4344
char c = st[i];
44-
if (c == '.' || c == ':' || c == '/')
45+
if (c == '\\' && c_1 == '\\') {
46+
result = result.substr(0, result.size()-1);
47+
result += "_";
48+
} else if (c == '.' || c == ':' || c == '/')
4549
result += "_";
4650
else
4751
result += c;
52+
c_1 = c;
4853
}
4954
return result;
5055
}

0 commit comments

Comments
 (0)