projects
/
yosys.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4f187d5
)
Replace assert in get_reference with more useful error message
author
Lofty
<dan.ravensloft@gmail.com>
Wed, 17 Mar 2021 02:43:25 +0000
(
02:43
+0000)
committer
Marcelina KoĆcielnicka
<mwk@0x04.net>
Wed, 17 Mar 2021 08:32:13 +0000
(09:32 +0100)
kernel/rtlil.h
patch
|
blob
|
history
diff --git
a/kernel/rtlil.h
b/kernel/rtlil.h
index 10cb039d5d720008ca6ac8bc61c46dd318c438b8..a747b9d3c8a13c784048b7d1abc451136b7ac4b5 100644
(file)
--- a/
kernel/rtlil.h
+++ b/
kernel/rtlil.h
@@
-166,7
+166,8
@@
namespace RTLIL
log_assert(p[0] == '$' || p[0] == '\\');
log_assert(p[1] != 0);
for (const char *c = p; *c; c++)
- log_assert((unsigned)*c > (unsigned)' ');
+ if ((unsigned)*c <= (unsigned)' ')
+ log_error("Found control character or space (0x%02hhx) in string '%s' which is not allowed in RTLIL identifiers\n", *c, p);
#ifndef YOSYS_NO_IDS_REFCNT
if (global_free_idx_list_.empty()) {