descend_schematic(): vectorize #netxxx nets if connected to bussed pins, before hashing, so resolved_net(...) will return the correct net portmapping

This commit is contained in:
stefan schippers 2023-06-01 06:40:24 +02:00
parent e9c8569800
commit e948edbffa
2 changed files with 4 additions and 11 deletions

View File

@ -1712,8 +1712,10 @@ int descend_schematic(int instnumber)
my_strdup2(_ALLOC_ID_, &single_n,
find_nth(net_node, ",", ((inst_number - 1) * mult + k - 1) % net_mult + 1));
single_n_ptr = single_n;
if(single_n_ptr[0] == '#') single_n_ptr++;
if(single_n_ptr[0] == '#') {
my_mstrcat(_ALLOC_ID_, &single_n, "[", my_itoa((inst_mult - inst_number + 1) * mult - k), "]", NULL);
single_n_ptr = single_n + 1;
}
str_hash_lookup(&xctx->portmap[xctx->currsch + 1], single_p, single_n_ptr, XINSERT);
dbg(1, "descend_schematic(): %s: %s ->%s\n", xctx->inst[n].instname, single_p, single_n_ptr);
}

View File

@ -278,7 +278,6 @@ list: B_NAME {
my_free(_ALLOC_ID_, &$1);
$$.m = 1;
}
| list B_NAME {
dbg(3, "yyparse(): list B_NAME, $2=%s\n", $2);
$$.str = expandlabel_strcat($1.str, $2);
@ -286,7 +285,6 @@ list: B_NAME {
my_free(_ALLOC_ID_, &$2);
$$.m = $1.m;
}
| list '*' B_NUM
{
dbg(3, "yyparse(): list * B_NUM\n");
@ -548,12 +546,5 @@ index_nobracket: B_IDXNUM B_DOUBLEDOT B_IDXNUM B_DOUBLEDOT B_IDXNUM B_DOUBLEDOT
check_idx(&$$, ++$$[0]);
$$[$$[0]]=$3;
}
/*
| B_IDXNUM ',' index_nobracket
{
if($$==NULL) dbg(0, "null\n");
}
*/
%%