Move extern declaration to the top, out of any function.

Thus remove VC2022 compiler warnings.
This commit is contained in:
Holger Vogt 2023-07-04 12:07:41 +02:00
parent 159e185bfe
commit d74e43f0f0
5 changed files with 9 additions and 5 deletions

View File

@ -12,6 +12,8 @@ Author: 1991 David A. Gates, U. C. Berkeley CAD Group
#include "onedext.h"
#include "oneddefs.h"
extern void CiderLoaded(int);
void
ONEdestroy(ONEdevice *pDevice)
{
@ -86,7 +88,6 @@ ONEdestroy(ONEdevice *pDevice)
FREE(pDevice);
{
extern void CiderLoaded(int);
CiderLoaded(-1);
}
}

View File

@ -12,6 +12,7 @@ Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
#include "onedext.h"
#include "oneddefs.h"
extern void CiderLoaded(int);
/* Forward Declarations */
/* static void ONEresetEvalFlag(ONEdevice *); sjb - not used */
@ -195,7 +196,6 @@ ONEbuildMesh(ONEdevice *pDevice, ONEcoord *pCoord, ONEdomain *pDomain,
FREE(nodeArray);
{
extern void CiderLoaded(int);
CiderLoaded(1);
}

View File

@ -12,6 +12,8 @@ Author: 1991 David A. Gates, U. C. Berkeley CAD Group
#include "twoddefs.h"
#include "twodext.h"
extern void CiderLoaded(int);
void
TWOdestroy(TWOdevice *pDevice)
{
@ -108,7 +110,6 @@ TWOdestroy(TWOdevice *pDevice)
FREE( pDevice );
{
extern void CiderLoaded(int);
CiderLoaded(-1);
}
}

View File

@ -19,6 +19,7 @@ Author: 1991 David A. Gates, U. C. Berkeley CAD Group
static void doMobCoeffs(TWOelem *, int);
static void resetEvalFlag(TWOdevice *pDevice);
extern void CiderLoaded(int);
void
TWObuildMesh(TWOdevice *pDevice, TWOdomain *pDomain,
@ -459,7 +460,6 @@ TWObuildMesh(TWOdevice *pDevice, TWOdomain *pDomain,
FREE(edgeArrayH);
{
extern void CiderLoaded(int);
CiderLoaded(1);
}
/*

View File

@ -107,6 +107,8 @@ FILE *flogp = NULL; /* log file ('-o logfile' command line option) */
bool orflag = FALSE; /* global for -o option */
#endif
extern int IsCiderLoaded(void);
FILE *slogp = NULL; /* soa log file ('--soa-log file' command line option) */
/* Frontend and circuit options */
@ -535,7 +537,7 @@ sp_shutdown(int exitval)
{
#ifdef CIDER
{
extern int IsCiderLoaded(void);
char *cider_quit_s = NULL;
bool cider_com_quit = TRUE;
if (exitval != EXIT_BAD) {