discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

gcc31 compile problem


From: Pete French
Subject: gcc31 compile problem
Date: Thu, 21 Nov 2002 15:27:22 +0000

Compiling 'gui' undder gcc31 gives me problems when PSOperators.h
includes DPSOperators.h - the error message complains that va_start
is used in a non varargs function in PSPrintf() - which is incorrect
in itself as the va_start is within DPSPrintf().

The problem is due to the static inlining of the iinner function which
causes problems when nested within the outer one. A simple fix is to
simply declare the function as 'static'. The optimiser should be able to
decide whether too inline it or not anyway (as far as I know).

The version of gcc causing the problem is gcc version 3.1.1 [FreeBSD]

-bat.

Patch:

*** gnustep/core/gui/Headers/AppKit/DPSOperators.h.orig Thu Nov 21 15:15:57 2002
--- gnustep/core/gui/Headers/AppKit/DPSOperators.h      Thu Nov 21 15:16:18 2002
***************
*** 451,457 ****
  /* ----------------------------------------------------------------------- */
  /* Postscript Client functions */
  /* ----------------------------------------------------------------------- */
! static inline void
  DPSPrintf(GSCTXT *ctxt, const char * fmt, ...)
  __attribute__((unused));
  
--- 451,457 ----
  /* ----------------------------------------------------------------------- */
  /* Postscript Client functions */
  /* ----------------------------------------------------------------------- */
! static void
  DPSPrintf(GSCTXT *ctxt, const char * fmt, ...)
  __attribute__((unused));
  
***************
*** 1171,1177 ****
  /* ----------------------------------------------------------------------- */
  /* Postscript Client functions */
  /* ----------------------------------------------------------------------- */
! static inline void
  DPSPrintf(GSCTXT *ctxt, const char * fmt, ...)
  {
    va_list ap;
--- 1171,1177 ----
  /* ----------------------------------------------------------------------- */
  /* Postscript Client functions */
  /* ----------------------------------------------------------------------- */
! static void
  DPSPrintf(GSCTXT *ctxt, const char * fmt, ...)
  {
    va_list ap;








reply via email to

[Prev in Thread] Current Thread [Next in Thread]