Skip to content

Commit

Permalink
Move common C library headers to system.h
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisJefferson authored and fingolfin committed May 17, 2018
1 parent a2b030e commit 33a936b
Show file tree
Hide file tree
Showing 14 changed files with 1 addition and 24 deletions.
3 changes: 0 additions & 3 deletions src/boehm_gc.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,6 @@
#endif

#include <pthread.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>

#define LARGE_GC_SIZE (8192 * sizeof(UInt))
#define TL_GC_SIZE (256 * sizeof(UInt))
Expand Down
2 changes: 0 additions & 2 deletions src/debug.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@
#if defined(HAVE_BACKTRACE) && defined(PRINT_BACKTRACE)
#include <execinfo.h>
#include <signal.h>
#include <stdlib.h>
#include <stdio.h>

static void BacktraceHandler(int sig) NORETURN;

Expand Down
2 changes: 0 additions & 2 deletions src/error.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,6 @@
#include "hpc/thread.h"
#endif

#include <stdio.h>


static Obj ErrorInner;

Expand Down
2 changes: 0 additions & 2 deletions src/gasman.c
Original file line number Diff line number Diff line change
Expand Up @@ -118,8 +118,6 @@
#include "sysfiles.h"
#include "sysmem.h"

#include <stdio.h>

#ifdef GAP_MEM_CHECK
#include <sys/mman.h>
#endif
Expand Down
2 changes: 0 additions & 2 deletions src/gvars.c
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,6 @@
#include <pthread.h>
#endif

#include <stdio.h>


#ifdef HPCGAP
#define USE_GVAR_BUCKETS
Expand Down
2 changes: 0 additions & 2 deletions src/integer.c
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,6 @@
#include "stats.h"
#include "stringobj.h"

#include <stdio.h>


/* TODO: Remove after Ward2 */
#ifndef WARD_ENABLED
Expand Down
2 changes: 0 additions & 2 deletions src/macfloat.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,6 @@
#include "saveload.h"
#include "stringobj.h"

#include <stdio.h>


/****************************************************************************
**
Expand Down
1 change: 0 additions & 1 deletion src/profile.c
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@

#include "hpc/thread.h"

#include <stdio.h>
#include <sys/time.h> // for gettimeofday
#ifdef HAVE_SYS_RESOURCE_H
#include <sys/resource.h> // definition of 'struct rusage'
Expand Down
1 change: 0 additions & 1 deletion src/sysfiles.c
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@
#include <assert.h>
#include <errno.h>
#include <fcntl.h>
#include <stdio.h>
#include <termios.h>
#include <time.h>
#include <unistd.h>
Expand Down
2 changes: 0 additions & 2 deletions src/sysfiles.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@

#include "system.h"

#include <stdio.h> // for FILE

/****************************************************************************
**
*F * * * * * * * * * * * * * * dynamic loading * * * * * * * * * * * * * * *
Expand Down
1 change: 1 addition & 0 deletions src/system.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
#include <setjmp.h>
#include <stdint.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>


Expand Down
2 changes: 0 additions & 2 deletions src/vars.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,6 @@
#include "hpc/guards.h"
#endif

#include <stdio.h>

/****************************************************************************
**
*V CurrLVars . . . . . . . . . . . . . . . . . . . . . local variables bag
Expand Down
1 change: 0 additions & 1 deletion src/vars.h
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,6 @@ static inline Obj CURR_FUNC(void)
#ifdef TRACEFRAMES
extern Obj STEVES_TRACING;
extern Obj True;
#include <stdio.h>
#endif

static inline void SetBrkCallTo( Expr expr, const char * file, int line ) {
Expand Down
2 changes: 0 additions & 2 deletions src/weakptr.c
Original file line number Diff line number Diff line change
Expand Up @@ -439,8 +439,6 @@ Obj FuncUnbindElmWPObj( Obj self, Obj wp, Obj pos)
** collection.
*/

#include <stdio.h>

// Provide implementation of ElmDefListFuncs
Obj ElmDefWPList(Obj wp, Int ipos, Obj def)
{
Expand Down

0 comments on commit 33a936b

Please sign in to comment.