From 07727f74f0d84fad71860ba58dbc54f1a5b82311 Mon Sep 17 00:00:00 2001 From: h_vogt Date: Sun, 27 May 2012 11:38:16 +0200 Subject: [PATCH] commands.c: 'options' equivalent to 'option' and allow 'loadsnap' and 'savesnap' which have been EXPERIMENTAL_CODE so far --- src/frontend/commands.c | 13 ++++++------- src/frontend/spiceif.c | 2 -- src/frontend/spiceif.h | 2 -- src/main.c | 2 -- 4 files changed, 6 insertions(+), 13 deletions(-) diff --git a/src/frontend/commands.c b/src/frontend/commands.c index 6bf240025..e9fb37767 100644 --- a/src/frontend/commands.c +++ b/src/frontend/commands.c @@ -86,10 +86,7 @@ #include "arg.h" -#ifdef EXPERIMENTAL_CODE -#include "com_option.h" #include "spiceif.h" /* for com_loadsnap() and com_savesnap() */ -#endif #include "com_dl.h" @@ -131,12 +128,16 @@ struct comm spcp_coms[] = { "[option] [option = value] ... : Set a variable." } , -/* PN support for altering options in interactive mode */ +/* support for altering options in interactive mode, + using either command 'option' or 'options'*/ { "option", com_option, TRUE, TRUE, { 020000, 020000, 020000, 020000 }, E_DEFHMASK, 0, LOTS, arg_set, "[option] [option = value] ... : Set a simulator option." } , -#ifdef EXPERIMENTAL_CODE + { "options", com_option, TRUE, TRUE, + { 020000, 020000, 020000, 020000 }, E_DEFHMASK, 0, LOTS, + arg_set, + "[option] [option = value] ... : Set a simulator option." } , { "savesnap", com_savesnap, FALSE, TRUE, { 1, 040000, 040000, 040000 }, E_DEFHMASK, 1, 1, NULL, @@ -145,8 +146,6 @@ struct comm spcp_coms[] = { { 1, 040000, 040000, 040000 }, E_DEFHMASK, 2, 2, NULL, "file : Load a snapshot." } , -#endif - { "alias", com_alias, FALSE, FALSE, { 02, 04, 04, 04 }, E_ADVANCED, 0, LOTS, NULL, diff --git a/src/frontend/spiceif.c b/src/frontend/spiceif.c index 2e8ec5265..3cb4ec8ad 100644 --- a/src/frontend/spiceif.c +++ b/src/frontend/spiceif.c @@ -1319,7 +1319,6 @@ if_getstat(CKTcircuit *ckt, char *name) { LTRA transmission line will not do. Many others are not tested. */ -#ifdef EXPERIMENTAL_CODE #include "ngspice/cktdefs.h" #include "ngspice/trandefs.h" @@ -1726,4 +1725,3 @@ void com_savesnap(wordlist *wl) } -#endif /* EXPERIMENTAL_CODE */ diff --git a/src/frontend/spiceif.h b/src/frontend/spiceif.h index 0e3dbcc65..ecd785bd1 100644 --- a/src/frontend/spiceif.h +++ b/src/frontend/spiceif.h @@ -13,9 +13,7 @@ void if_dump(CKTcircuit *ckt, FILE *file); void if_cktfree(CKTcircuit *ckt, INPtables *tab); int if_analQbyName(CKTcircuit *ckt, int which, JOB *anal, char *name, IFvalue *parm); -#ifdef EXPERIMENTAL_CODE void com_loadsnap(wordlist *wl); void com_savesnap(wordlist *wl); -#endif #endif /* SPICEIF_H_INCLUDED */ diff --git a/src/main.c b/src/main.c index 22e70922c..836324da5 100644 --- a/src/main.c +++ b/src/main.c @@ -353,10 +353,8 @@ if_getstat(CKTcircuit *ckt, char *name) return (NULL); } -#ifdef EXPERIMENTAL_CODE void com_loadsnap(wordlist *wl) { return; } void com_savesnap(wordlist *wl) { return; } -#endif void SMPprint( SMPmatrix *n1 , char *n2) {