diff --git a/doc/ngspice.texi b/doc/ngspice.texi index 355227bfb..6f17e59f4 100644 --- a/doc/ngspice.texi +++ b/doc/ngspice.texi @@ -7743,10 +7743,6 @@ Do not check to make sure that there are no circuits suspended and no plots un saved. Normally Ngspice warns the user when he tries to quit if this is the case. -@item nobjthack - -Assume that BJTs have 4 nodes. - @item noparse Don't attempt to parse input files when they are read in (useful for @@ -7956,9 +7952,7 @@ recognized. BJTs can have either 3 or 4 nodes, which makes it difficult for the subcircuit expansion routines to decide what to rename. If the fourth parameter has been declared as a model name, then it is assumed that -there are 3 nodes, otherwise it is considered a node. To disable this, -you can set the variable "nobjthack" which forces BJTs to have 4 nodes -(for the purposes of subcircuit expansion, at least). +there are 3 nodes, otherwise it is considered a node. The @@name[param] notation might not work with trace, iplot, etc. yet. diff --git a/src/frontend/miscvars.c b/src/frontend/miscvars.c index bfd9388be..9632ef862 100644 --- a/src/frontend/miscvars.c +++ b/src/frontend/miscvars.c @@ -81,7 +81,6 @@ char *ft_setkwords[] = { "moremode", "nfreqs", "noasciiplotvalue", - "nobjthack", "nobreak", "noclobber", "node", diff --git a/src/frontend/subckt.c b/src/frontend/subckt.c index 9ec555ca7..86143e3dc 100644 --- a/src/frontend/subckt.c +++ b/src/frontend/subckt.c @@ -126,7 +126,6 @@ struct subs { * list of translated names (i.e. after subckt expansion) */ -static bool nobjthack = FALSE; /* flag indicating use of the experimental numparams library */ static bool use_numparams = FALSE; @@ -219,7 +218,6 @@ inp_subcktexpand(struct line *deck) { (void) strcpy(model, ".model"); if (!cp_getvar("modelline", CP_STRING, model)) (void) strcpy(model, ".model"); - nobjthack = cp_getvar("nobjthack", CP_BOOL, NULL); use_numparams = cp_getvar("numparams", CP_BOOL, NULL); @@ -1510,8 +1508,6 @@ numnodes(char *name, struct subs *subs, wordlist const *modnames) /* for a given device type. */ /* Paolo Nenzi Jan-2001 */ - /* I hope that works, this code is very very untested */ - if ((c == 'm') || (c == 'p') || (c == 'q')) { /* IF this is a mos, cpl or bjt*/ i = 0; s = buf; @@ -1541,12 +1537,10 @@ numnodes(char *name, struct subs *subs, wordlist const *modnames) return (0); } return (i-1); /* compensate the unnecessary increment in the while cycle */ - } /* if (c == 'm' . . . */ - - if (nobjthack || (c != 'q')) /* for all other elements */ + } else { + /* for all other elements */ return (n); - - return (0); + } } diff --git a/src/ngspice.txt b/src/ngspice.txt index 884f67c6a..bc3d3e02a 100644 --- a/src/ngspice.txt +++ b/src/ngspice.txt @@ -5621,7 +5621,6 @@ TEXT: H no circuits suspended and no plots un- TEXT: H saved. Normally Spice3 warns the user TEXT: H when he tries to quit if this is the TEXT: H case. -TEXT: H nobjthack Assume that BJTs have 4 nodes. TEXT: H noparse Don't attempt to parse input files when TEXT: H they are read in (useful for debugging). TEXT: H Of course, they cannot be run if they @@ -5807,9 +5806,7 @@ TEXT: H BJTs can have either 3 or 4 nodes, which makes it dif- TEXT: H ficult for the subcircuit expansion routines to decide what TEXT: H to rename. If the fourth parameter has been declared as a TEXT: H model name, then it is assumed that there are 3 nodes, oth- -TEXT: H erwise it is considered a node. To disable this, you can -TEXT: H set the variable "nobjthack" which forces BJTs to have 4 -TEXT: H nodes (for the purposes of subcircuit expansion, at least). +TEXT: H erwise it is considered a node. TEXT: H TEXT: H The @name[param] notation might not work with trace, TEXT: H iplot, etc. yet.