From f7b4327454669c5f4b4c8ffb934734279b61ada9 Mon Sep 17 00:00:00 2001 From: nijtmans Date: Tue, 27 Apr 2010 12:36:21 +0000 Subject: If tclInt.h or tclPort.h is already included, don't include again. Follow-up to [Bug 2991415]: tclport.h #included before limits.h See comments in [Bug 2991415] --- ChangeLog | 13 +++++++++++++ compat/strtod.c | 3 +-- compat/strtol.c | 3 +-- generic/regguts.h | 12 ------------ generic/tclBasic.c | 6 ++---- generic/tclExecute.c | 4 +--- generic/tclIORChan.c | 4 ++-- generic/tclIORTrans.c | 4 ++-- generic/tclOOInt.h | 4 ++-- generic/tclObj.c | 3 +-- generic/tclStrToD.c | 11 +++-------- generic/tclTomMath.h | 13 ++++--------- generic/tclTomMathInterface.c | 3 +-- generic/tclUtil.c | 3 +-- 14 files changed, 34 insertions(+), 52 deletions(-) diff --git a/ChangeLog b/ChangeLog index 005ae29..be9c57a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,6 +2,19 @@ * generic/tclIOUtil.c (Tcl_FSGetNativePath): [Bug 2992292]: tclIOUtil.c assignment type mismatch compiler warning + * generic/regguts.h If tclInt.h or tclPort.h is already + * generic/tclBasic.c included, don't include + * generic/tclExecute.c again. Follow-up to [Bug 2991415]: + * generic/tclIORChan.c tclport.h #included before limits.h + * generic/tclIORTrans.c See comments in [Bug 2991415] + * generic/tclObj.c + * generic/tclOOInt.h + * generic/tclStrToD.c + * generic/tclTomMath.h + * generic/tclTomMathInterface.c + * generic/tclUtil.c + * compat/strtod.c + * compat/strtol.c 2010-04-27 Kevin B. Kenny diff --git a/compat/strtod.c b/compat/strtod.c index 7171101..89ad625 100644 --- a/compat/strtod.c +++ b/compat/strtod.c @@ -9,11 +9,10 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: strtod.c,v 1.10 2010/03/04 22:29:05 nijtmans Exp $ + * RCS: @(#) $Id: strtod.c,v 1.11 2010/04/27 12:36:23 nijtmans Exp $ */ #include "tclInt.h" -#include #ifndef TRUE #define TRUE 1 diff --git a/compat/strtol.c b/compat/strtol.c index 85c2520..1c52a9e 100644 --- a/compat/strtol.c +++ b/compat/strtol.c @@ -9,10 +9,9 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: strtol.c,v 1.7 2008/04/27 22:21:28 dkf Exp $ + * RCS: @(#) $Id: strtol.c,v 1.8 2010/04/27 12:36:23 nijtmans Exp $ */ -#include #include "tclInt.h" /* diff --git a/generic/regguts.h b/generic/regguts.h index f72542c..e57b8f8 100644 --- a/generic/regguts.h +++ b/generic/regguts.h @@ -39,15 +39,6 @@ * Things that regcustom.h might override. */ -/* standard header files (NULL is a reasonable indicator for them) */ -#ifndef NULL -#include -#include -#include -#include -#include -#endif - /* assertions */ #ifndef assert #ifndef REG_DEBUG @@ -96,9 +87,6 @@ #endif /* want size of a char in bits, and max value in bounded quantifiers */ -#ifndef CHAR_BIT -#include -#endif #ifndef _POSIX2_RE_DUP_MAX #define _POSIX2_RE_DUP_MAX 255 /* normally from */ #endif diff --git a/generic/tclBasic.c b/generic/tclBasic.c index 11ddefd..3a37aac 100644 --- a/generic/tclBasic.c +++ b/generic/tclBasic.c @@ -16,16 +16,14 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclBasic.c,v 1.452 2010/04/25 13:39:25 msofer Exp $ + * RCS: @(#) $Id: tclBasic.c,v 1.453 2010/04/27 12:36:21 nijtmans Exp $ */ #include "tclInt.h" #include "tclOOInt.h" #include "tclCompile.h" -#include -#include -#include #include "tommath.h" +#include #if NRE_ENABLE_ASSERTS #include diff --git a/generic/tclExecute.c b/generic/tclExecute.c index 3c440c3..7132535 100644 --- a/generic/tclExecute.c +++ b/generic/tclExecute.c @@ -14,15 +14,13 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclExecute.c,v 1.477 2010/04/24 17:07:32 msofer Exp $ + * RCS: @(#) $Id: tclExecute.c,v 1.478 2010/04/27 12:36:21 nijtmans Exp $ */ #include "tclInt.h" #include "tclCompile.h" #include "tommath.h" - #include -#include #if NRE_ENABLE_ASSERTS #include diff --git a/generic/tclIORChan.c b/generic/tclIORChan.c index 95a488e..4d9832c 100644 --- a/generic/tclIORChan.c +++ b/generic/tclIORChan.c @@ -15,10 +15,10 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclIORChan.c,v 1.47 2010/03/30 21:17:13 andreas_kupries Exp $ + * RCS: @(#) $Id: tclIORChan.c,v 1.48 2010/04/27 12:36:22 nijtmans Exp $ */ -#include +#include "tclInt.h" #include #include diff --git a/generic/tclIORTrans.c b/generic/tclIORTrans.c index 801f5fb..608ff88 100644 --- a/generic/tclIORTrans.c +++ b/generic/tclIORTrans.c @@ -15,10 +15,10 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclIORTrans.c,v 1.15 2010/03/17 16:35:42 andreas_kupries Exp $ + * RCS: @(#) $Id: tclIORTrans.c,v 1.16 2010/04/27 12:36:21 nijtmans Exp $ */ -#include +#include "tclInt.h" #include #include diff --git a/generic/tclOOInt.h b/generic/tclOOInt.h index 192d684..56da45d 100644 --- a/generic/tclOOInt.h +++ b/generic/tclOOInt.h @@ -9,13 +9,13 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclOOInt.h,v 1.17 2010/03/05 15:32:16 dkf Exp $ + * RCS: @(#) $Id: tclOOInt.h,v 1.18 2010/04/27 12:36:21 nijtmans Exp $ */ #ifndef TCL_OO_INTERNAL_H #define TCL_OO_INTERNAL_H 1 -#include +#include "tclInt.h" #include "tclOO.h" /* diff --git a/generic/tclObj.c b/generic/tclObj.c index f16cb66..0d80189 100644 --- a/generic/tclObj.c +++ b/generic/tclObj.c @@ -13,12 +13,11 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclObj.c,v 1.172 2010/03/30 16:31:09 dgp Exp $ + * RCS: @(#) $Id: tclObj.c,v 1.173 2010/04/27 12:36:21 nijtmans Exp $ */ #include "tclInt.h" #include "tommath.h" -#include #include /* diff --git a/generic/tclStrToD.c b/generic/tclStrToD.c index b9b9950..fdfdb5e 100755 --- a/generic/tclStrToD.c +++ b/generic/tclStrToD.c @@ -14,19 +14,14 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclStrToD.c,v 1.42 2010/04/02 19:23:58 kennykb Exp $ + * RCS: @(#) $Id: tclStrToD.c,v 1.43 2010/04/27 12:36:22 nijtmans Exp $ * *---------------------------------------------------------------------- */ -#include -#include -#include -#include -#include +#include "tclInt.h" +#include "tommath.h" #include -#include -#include /* * Define KILL_OCTAL to suppress interpretation of numbers with leading zero diff --git a/generic/tclTomMath.h b/generic/tclTomMath.h index 48bb603..4e28663 100644 --- a/generic/tclTomMath.h +++ b/generic/tclTomMath.h @@ -15,17 +15,12 @@ #ifndef BN_H_ #define BN_H_ +#include "tclInt.h" #include #ifndef MODULE_SCOPE #define MODULE_SCOPE extern #endif -#include -#include -#include -#include -#include - #ifndef MIN #define MIN(x,y) ((x)<(y)?(x):(y)) #endif @@ -830,7 +825,7 @@ MODULE_SCOPE const char *mp_s_rmap; #endif #ifdef __cplusplus - } +} #endif #endif @@ -838,6 +833,6 @@ MODULE_SCOPE const char *mp_s_rmap; /* $Source: /root/tcl/repos-to-convert/tcl/generic/tclTomMath.h,v $ */ /* Based on Tom's version 1.8 */ -/* $Revision: 1.11 $ */ -/* $Date: 2009/10/06 16:31:01 $ */ +/* $Revision: 1.12 $ */ +/* $Date: 2010/04/27 12:36:21 $ */ diff --git a/generic/tclTomMathInterface.c b/generic/tclTomMathInterface.c index 8de65db..eb93fe6 100644 --- a/generic/tclTomMathInterface.c +++ b/generic/tclTomMathInterface.c @@ -11,12 +11,11 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclTomMathInterface.c,v 1.14 2010/02/24 10:45:04 dkf Exp $ + * RCS: @(#) $Id: tclTomMathInterface.c,v 1.15 2010/04/27 12:36:21 nijtmans Exp $ */ #include "tclInt.h" #include "tommath.h" -#include MODULE_SCOPE const TclTomMathStubs tclTomMathStubs; diff --git a/generic/tclUtil.c b/generic/tclUtil.c index 71e4093..b583af5 100644 --- a/generic/tclUtil.c +++ b/generic/tclUtil.c @@ -11,11 +11,10 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclUtil.c,v 1.114 2010/03/05 14:34:04 dkf Exp $ + * RCS: @(#) $Id: tclUtil.c,v 1.115 2010/04/27 12:36:22 nijtmans Exp $ */ #include "tclInt.h" -#include #include /* -- cgit v0.12