From 35dffef61890c0504185dd5292c9b6508dd42eb6 Mon Sep 17 00:00:00 2001 From: stefan schippers Date: Wed, 3 Apr 2024 00:56:05 +0200 Subject: [PATCH] has_included_subcircuit(): extend case insensitivity also on included subckt pins vs symbol pins --- src/token.c | 1 + src/xschem.tcl | 2 +- xschem_library/examples/symbol_include.cir | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/token.c b/src/token.c index 40d6e80d..64df894c 100644 --- a/src/token.c +++ b/src/token.c @@ -1868,6 +1868,7 @@ static int has_included_subcircuit(int inst, int symbol, char **result) char *pin_expanded_ptr, *pin_expanded = NULL; char *net_expanded_ptr, *net_expanded = NULL; my_strdup2(_ALLOC_ID_, &pin_expanded, expandlabel(name, &pin_mult)); + strtolower(pin_expanded); my_strdup2(_ALLOC_ID_, &net_expanded, net_name(inst, i, &net_mult, 0, 1)); net_expanded_ptr = net_expanded; pin_expanded_ptr = pin_expanded; diff --git a/src/xschem.tcl b/src/xschem.tcl index c420ec5b..1c93f92b 100644 --- a/src/xschem.tcl +++ b/src/xschem.tcl @@ -835,7 +835,7 @@ proc has_included_subcircuit {symname spice_sym_def} { } } # puts $pinlist - return [join $pinlist] + return [string tolower [join $pinlist]] } # should not be called directly by user diff --git a/xschem_library/examples/symbol_include.cir b/xschem_library/examples/symbol_include.cir index 710fc558..2ac36f41 100644 --- a/xschem_library/examples/symbol_include.cir +++ b/xschem_library/examples/symbol_include.cir @@ -1,6 +1,6 @@ * example of a subcircuit contained in a file -.subckt symbol_include Z Y[5] Y[4] Y[3] Y[2] +.subckt xsymbol_include z y[5] y[4] y[3] y[2] + VCC VSS + A[2] A[1] A[0] B C W=10 L=1 ...