Merge branch 'master' into netgen-1.5
This commit is contained in:
commit
2cb3937ee3
|
|
@ -1632,6 +1632,7 @@ PrematchLists(char *name1, int file1, char *name2, int file2)
|
||||||
ECompList *list0X, *listX0;
|
ECompList *list0X, *listX0;
|
||||||
int hascontents1, hascontents2;
|
int hascontents1, hascontents2;
|
||||||
int match, modified = 0;
|
int match, modified = 0;
|
||||||
|
int not_top;
|
||||||
|
|
||||||
if (file1 == -1)
|
if (file1 == -1)
|
||||||
tc1 = LookupCell(name1);
|
tc1 = LookupCell(name1);
|
||||||
|
|
@ -1902,6 +1903,8 @@ PrematchLists(char *name1, int file1, char *name2, int file2)
|
||||||
// Remove non-matching zero-value devices. This can
|
// Remove non-matching zero-value devices. This can
|
||||||
// be done on a per-instance basis.
|
// be done on a per-instance basis.
|
||||||
|
|
||||||
|
not_top = (PeekCompareQueueTop(NULL, NULL, NULL, NULL) == -1) ? FALSE : TRUE;
|
||||||
|
|
||||||
ecomp = (ECompare *)HashFirst(&compdict);
|
ecomp = (ECompare *)HashFirst(&compdict);
|
||||||
while (ecomp != NULL) {
|
while (ecomp != NULL) {
|
||||||
if ((ecomp->num1 != ecomp->num2) && (ecomp->cell1 != NULL) &&
|
if ((ecomp->num1 != ecomp->num2) && (ecomp->cell1 != NULL) &&
|
||||||
|
|
@ -1958,7 +1961,7 @@ PrematchLists(char *name1, int file1, char *name2, int file2)
|
||||||
/* because it will just show up as a */
|
/* because it will just show up as a */
|
||||||
/* port mismatch error as it should. */
|
/* port mismatch error as it should. */
|
||||||
|
|
||||||
if (!(tc1->flags & CELL_TOP) &&
|
if ((not_top == TRUE) &&
|
||||||
(ecomp->cell1->class != CLASS_ISOURCE)) {
|
(ecomp->cell1->class != CLASS_ISOURCE)) {
|
||||||
int found1 = FALSE;
|
int found1 = FALSE;
|
||||||
int found2 = FALSE;
|
int found2 = FALSE;
|
||||||
|
|
@ -2096,6 +2099,27 @@ PrematchLists(char *name1, int file1, char *name2, int file2)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* (See comments above about removing shorts */
|
||||||
|
/* between two ports.) */
|
||||||
|
|
||||||
|
if ((not_top == TRUE) &&
|
||||||
|
(ecomp->cell2->class != CLASS_ISOURCE)) {
|
||||||
|
int found1 = FALSE;
|
||||||
|
int found2 = FALSE;
|
||||||
|
for (ob1 = tc2->cell; ob1; ob1 = ob1->next) {
|
||||||
|
if (!IsPort(ob1)) break;
|
||||||
|
else if (ob1->node == node1)
|
||||||
|
found1 = TRUE;
|
||||||
|
else if (ob1->node == node2)
|
||||||
|
found2 = TRUE;
|
||||||
|
if (found1 && found2) {
|
||||||
|
found = FALSE;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (found) break;
|
if (found) break;
|
||||||
}
|
}
|
||||||
if (found) {
|
if (found) {
|
||||||
|
|
|
||||||
|
|
@ -3773,20 +3773,23 @@ int CreateCompareQueue(char *name1, int file1, char *name2, int file2)
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*----------------------------------------------*/
|
/*----------------------------------------------------------------*/
|
||||||
/* Read the top of the compare queue, but do */
|
/* Read the top of the compare queue, but do not alter the stack. */
|
||||||
/* not alter the stack. */
|
/* Return -1 if there is no compare queue. This is a way to */
|
||||||
/*----------------------------------------------*/
|
/* check if the current cells being checked are the topmost in */
|
||||||
|
/* the queue. Call with all NULL values for a quick check for a */
|
||||||
|
/* top-level compare. */
|
||||||
|
/*----------------------------------------------------------------*/
|
||||||
|
|
||||||
int PeekCompareQueueTop(char **name1, int *file1, char **name2, int *file2)
|
int PeekCompareQueueTop(char **name1, int *file1, char **name2, int *file2)
|
||||||
{
|
{
|
||||||
if (CompareQueue == NULL)
|
if (CompareQueue == NULL)
|
||||||
return -1;
|
return -1;
|
||||||
|
|
||||||
*name1 = CompareQueue->class1;
|
if (name1) *name1 = CompareQueue->class1;
|
||||||
*file1 = CompareQueue->file1;
|
if (file1) *file1 = CompareQueue->file1;
|
||||||
*name2 = CompareQueue->class2;
|
if (name2) *name2 = CompareQueue->class2;
|
||||||
*file2 = CompareQueue->file2;
|
if (file2) *file2 = CompareQueue->file2;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue