projects
/
yosys.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5f9cd2e
)
frontends/json/jsonparse.cc: Like the upto field read_json can also read the signedne...
author
Vamsi K Vytla
<vamsi.vytla@gmail.com>
Mon, 27 Apr 2020 17:36:18 +0000
(10:36 -0700)
committer
Vamsi K Vytla
<vamsi.vytla@gmail.com>
Mon, 27 Apr 2020 17:36:18 +0000
(10:36 -0700)
frontends/json/jsonparse.cc
patch
|
blob
|
history
diff --git
a/frontends/json/jsonparse.cc
b/frontends/json/jsonparse.cc
index 7aceffbfce4fff59d04ca44bd58dea115789d340..8ae7c657861c28790fa6b4b6a5a401932405f107 100644
(file)
--- a/
frontends/json/jsonparse.cc
+++ b/
frontends/json/jsonparse.cc
@@
-309,6
+309,12
@@
void json_import(Design *design, string &modname, JsonNode *node)
port_wire->upto = val->data_number != 0;
}
+ if (port_node->data_dict.count("signed") != 0) {
+ JsonNode *val = port_node->data_dict.at("signed");
+ if (val->type == 'N')
+ port_wire->is_signed = val->data_number != 0;
+ }
+
if (port_node->data_dict.count("offset") != 0) {
JsonNode *val = port_node->data_dict.at("offset");
if (val->type == 'N')
@@
-573,4
+579,3
@@
struct JsonFrontend : public Frontend {
} JsonFrontend;
YOSYS_NAMESPACE_END
-