avoid multiple declarations of controlled_exit(), add 'noreturn' attribute
This commit is contained in:
parent
9a9e1c5413
commit
aa7a7606c7
|
|
@ -4,6 +4,8 @@
|
|||
* Free software under the terms of the GNU Lesser General Public License
|
||||
*/
|
||||
|
||||
#include "ngspice/ngspice.h"
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
|
|
@ -19,8 +21,6 @@
|
|||
|
||||
#include "general.h"
|
||||
|
||||
#include "ngspice/fteext.h" /* controlled_exit() */
|
||||
|
||||
|
||||
/*
|
||||
* fetch a human answer to a y/n question from stdin
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ Todo:
|
|||
#include "general.h"
|
||||
#include "numparam.h"
|
||||
|
||||
#include "ngspice/fteext.h" /* controlled_exit() */
|
||||
#include "ngspice/fteext.h"
|
||||
|
||||
|
||||
extern bool ft_batchmode;
|
||||
|
|
|
|||
|
|
@ -19,8 +19,6 @@
|
|||
#include "fftw3.h"
|
||||
#endif
|
||||
|
||||
extern void controlled_exit(int status);
|
||||
|
||||
|
||||
void
|
||||
f_alpha(int n_pts, int n_exp, double X[], double Q_d, double alpha)
|
||||
|
|
|
|||
|
|
@ -350,6 +350,5 @@ extern bool ft_intrpt;
|
|||
extern bool ft_setflag;
|
||||
|
||||
/* error.c */
|
||||
extern void controlled_exit(int status);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -299,6 +299,13 @@ extern void SetAnalyse(char *analyse, int percent);
|
|||
|
||||
void soa_printf(CKTcircuit *ckt, GENinstance *instance, const char *fmt, ...);
|
||||
|
||||
#ifdef __GNUC__
|
||||
extern void controlled_exit(int status) __attribute__ ((noreturn));
|
||||
#else
|
||||
extern void controlled_exit(int status);
|
||||
#endif
|
||||
|
||||
|
||||
/* macro to ignore unused variables and parameters */
|
||||
#define NG_IGNORE(x) (void)x
|
||||
#define NG_IGNOREABLE(x) (void)x
|
||||
|
|
|
|||
|
|
@ -12,11 +12,6 @@ Copyright 1990 Regents of the University of California. All rights reserved.
|
|||
*/
|
||||
#include "ngspice/ngspice.h"
|
||||
|
||||
/* We need this because some tests in cmaths and some executables other
|
||||
than ngspice and ngnutmeg under LINUX don't know about controlled_exit */
|
||||
#if defined HAS_WINGUI || defined SHARED_MODULE
|
||||
extern void controlled_exit(int status);
|
||||
#endif
|
||||
|
||||
#ifdef SHARED_MODULE
|
||||
#ifndef HAVE_LIBPTHREAD
|
||||
|
|
|
|||
|
|
@ -21,7 +21,6 @@ File: b3soiddld.c 98/5/01
|
|||
#include "ngspice/devdefs.h"
|
||||
#include "ngspice/suffix.h"
|
||||
|
||||
#include "ngspice/fteext.h" /* controlled_exit() */
|
||||
|
||||
#define MAX_EXP 5.834617425e14
|
||||
#define MIN_EXP 1.713908431e-15
|
||||
|
|
|
|||
|
|
@ -21,7 +21,6 @@ File: b3soifdld.c 98/5/01
|
|||
#include "ngspice/devdefs.h"
|
||||
#include "ngspice/suffix.h"
|
||||
|
||||
#include "ngspice/fteext.h" /* controlled_exit() */
|
||||
|
||||
#define MAX_EXP 5.834617425e14
|
||||
#define MIN_EXP 1.713908431e-15
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ Author: 1985 Thomas L. Quarles
|
|||
#include "ngspice/sperror.h"
|
||||
|
||||
#include "dev.h"
|
||||
#include "ngspice/fteext.h" /* controlled_exit() */
|
||||
#include "ngspice/fteext.h"
|
||||
|
||||
int
|
||||
CKTask(CKTcircuit *ckt, GENinstance *instance, int which, IFvalue *value, IFvalue *selector)
|
||||
|
|
|
|||
|
|
@ -10,7 +10,6 @@ Author: 1992 Charles Hough
|
|||
#include "ngspice/sperror.h"
|
||||
#include "ngspice/suffix.h"
|
||||
|
||||
#include "ngspice/fteext.h" /* controlled_exit() */
|
||||
|
||||
VI_list *pool_vi;
|
||||
static double ratio[MAX_CP_TX_LINES];
|
||||
|
|
|
|||
|
|
@ -14,7 +14,6 @@ Modified: 2004 Paolo Nenzi - (ng)spice integration
|
|||
|
||||
#include "ngspice/multi_line.h"
|
||||
|
||||
#include "ngspice/fteext.h" /* controlled_exit() */
|
||||
|
||||
|
||||
#define VECTOR_ALLOC(vec, n) { \
|
||||
|
|
|
|||
|
|
@ -10,7 +10,6 @@ Author: 1992 Charles Hough
|
|||
#include "ngspice/sperror.h"
|
||||
#include "ngspice/suffix.h"
|
||||
|
||||
#include "ngspice/fteext.h" /* controlled_exit() */
|
||||
|
||||
static double ratio[MAX_CP_TX_LINES];
|
||||
static int update_cnv_txl(TXLine*, double);
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ Author: 1992 Charles Hough
|
|||
#include "ngspice/sperror.h"
|
||||
#include "ngspice/suffix.h"
|
||||
|
||||
#include "ngspice/fteext.h" /* controlled_exit() */
|
||||
|
||||
static int ReadTxL(TXLinstance*, CKTcircuit*);
|
||||
/*static int multC();*/
|
||||
|
|
|
|||
|
|
@ -11,7 +11,6 @@ Author: 1987 Wayne A. Christopher, U. C. Berkeley CAD Group
|
|||
#include "ngspice/inpptree.h"
|
||||
#include "inpxx.h"
|
||||
|
||||
extern void controlled_exit(int status);
|
||||
|
||||
static INPparseNode *mkcon(double value);
|
||||
static INPparseNode *mkb(int type, INPparseNode * left,
|
||||
|
|
|
|||
Loading…
Reference in New Issue