aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2020-11-18 21:46:32 +0100
committerTristan Gingold <tgingold@free.fr>2020-11-18 21:46:32 +0100
commit91f6952a77cd4174e96e4e6c086c3c2779dcdf84 (patch)
treeca39dfd0b6716f44f05c68e531ede1852664edee
parent3676b888c5adf51788a1398384152e6a74406f6c (diff)
downloadghdl-yosys-plugin-91f6952a77cd4174e96e4e6c086c3c2779dcdf84.tar.gz
ghdl-yosys-plugin-91f6952a77cd4174e96e4e6c086c3c2779dcdf84.tar.bz2
ghdl-yosys-plugin-91f6952a77cd4174e96e4e6c086c3c2779dcdf84.zip
ghdl.cc: allow extended identifier of length 1
-rw-r--r--src/ghdl.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ghdl.cc b/src/ghdl.cc
index 2ddab7d..05b319e 100644
--- a/src/ghdl.cc
+++ b/src/ghdl.cc
@@ -48,7 +48,7 @@ static std::string user_to_str(Name_Id id)
char c = s[len];
if (c == 0)
break;
- if (c == '\\' && s[len + 1] == 0 && len > 2)
+ if (c == '\\' && s[len + 1] == 0 && len > 1)
break;
if (!((c >= 'a' && c <= 'z')
|| (c >= 'A' && c <= 'Z')