diff --git a/src/frontend/inpcom.c b/src/frontend/inpcom.c index 00f7311be..349ddcf82 100644 --- a/src/frontend/inpcom.c +++ b/src/frontend/inpcom.c @@ -1215,10 +1215,11 @@ inp_chk_for_multi_in_vcvs(struct line *c, int *line_number) char *fcn_b; - if ((fcn_b = strstr(line, "nand(")) != NULL || - (fcn_b = strstr(line, "and(")) != NULL || - (fcn_b = strstr(line, "nor(")) != NULL || - (fcn_b = strstr(line, "or(")) != NULL) + if (((fcn_b = strstr(line, "nand(")) != NULL || + (fcn_b = strstr(line, "and(")) != NULL || + (fcn_b = strstr(line, "nor(")) != NULL || + (fcn_b = strstr(line, "or(")) != NULL) && + isspace_c(fcn_b[-1])) { struct line *a_card, *model_card, *next_card; char keep, *comma_ptr, *xy_values1[5], *xy_values2[5]; @@ -1228,6 +1229,19 @@ inp_chk_for_multi_in_vcvs(struct line *c, int *line_number) int xy_count1, xy_count2; bool ok = FALSE; +#ifndef XSPICE + fprintf(stderr, + "\n" + "Error: XSPICE is required to run the 'multi-input pwl' option in line %d\n" + " %s\n" + "\n" + "See manual chapt. 31 for installation instructions\n", + *line_number, + line + ); + controlled_exit(EXIT_BAD); +#endif + do { ref_e = skip_non_ws(line);