This is the mail archive of the guile@sourceware.cygnus.com mailing list for the Guile project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: includes in _scm.h


Dirk Herrmann <dirk@ida.ing.tu-bs.de> writes:

> Hello!
> 
> Most of the guile files include _scm.h.  This file includes a large number
> of other header files.  I question that this makes sense:  When I changed
> a line in vectors.h, almost everything had to be recompiled, because
> vectors.h is included by _scm.h.
> 
> Some statistics:
>   75 .c files directly include _scm.h
>   30 .c files need definitions from vectors.h
> 
> Thus, changing vectors.h leads to an unnecessary recompilation of 45
> files.
> 
> Shouldn't this be avoided?  Maybe someone knows strong reasons for having
> such an include-everything file, but if this is not the case I propose to
> have each .c file explicitly include all headers that it needs.

I, too, believe it's worth avoiding.  Of course, for libguile.h, we
should have all the files included so that there is a single include
file for programs that want to use guile, but internally we should do
better.  What is your precise proposal?

Greg

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]