diff options
author | clairexen <claire@symbioticeda.com> | 2020-09-17 18:21:53 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-09-17 18:21:53 +0200 |
commit | 9e937961dc026751f8961dfff12aa50411750070 (patch) | |
tree | 4130d805accae2d2505ae0e626082ce7f2c1c6f0 /frontends | |
parent | 859e52af59e75689f7b0615899bc3356ba5a7ca1 (diff) | |
parent | daee2d967f5785c83123a1afa5b8bdcddf3da1d8 (diff) | |
download | yosys-9e937961dc026751f8961dfff12aa50411750070.tar.gz yosys-9e937961dc026751f8961dfff12aa50411750070.tar.bz2 yosys-9e937961dc026751f8961dfff12aa50411750070.zip |
Merge pull request #2330 from antmicro/arrays-fix-multirange-access
Fix unsupported subarray access detection
Diffstat (limited to 'frontends')
-rw-r--r-- | frontends/ast/simplify.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/frontends/ast/simplify.cc b/frontends/ast/simplify.cc index 0ba2ab6ac..153a42e19 100644 --- a/frontends/ast/simplify.cc +++ b/frontends/ast/simplify.cc @@ -1523,7 +1523,7 @@ bool AstNode::simplify(bool const_fold, bool at_zero, bool in_lvalue, int stage, for (int i = 0; 2*i < GetSize(id2ast->multirange_dimensions); i++) { - if (GetSize(children[0]->children) < i) + if (GetSize(children[0]->children) <= i) log_file_error(filename, location.first_line, "Insufficient number of array indices for %s.\n", log_id(str)); AstNode *new_index_expr = children[0]->children[i]->children.at(0)->clone(); |