projects
/
yosys.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
114a78d
)
More log_id() stuff
author
Clifford Wolf
<clifford@clifford.at>
Fri, 30 Jan 2015 21:22:52 +0000
(22:22 +0100)
committer
Clifford Wolf
<clifford@clifford.at>
Fri, 30 Jan 2015 21:22:52 +0000
(22:22 +0100)
kernel/log.cc
patch
|
blob
|
history
diff --git
a/kernel/log.cc
b/kernel/log.cc
index 061c5074cd5c44ec2a37e3f5a613741138f74649..ada2cabb222a924cb2a7e7b090f48cfe18737ecb 100644
(file)
--- a/
kernel/log.cc
+++ b/
kernel/log.cc
@@
-389,9
+389,13
@@
const char *log_id(RTLIL::IdString str)
{
log_id_cache.insert(str);
const char *p = str.c_str();
- if (p[0] == '\\' && p[1] != '$' && p[1] != '\\' && p[1] != 0)
- return p+1;
- return p;
+ if (p[0] != '\\')
+ return p;
+ if (p[1] == '$' || p[1] == '\\' || p[1] == 0)
+ return p;
+ if (p[1] >= '0' && p[1] <= '9')
+ return p;
+ return p+1;
}
void log_cell(RTLIL::Cell *cell, std::string indent)