unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* preparing the pretest
@ 2002-09-25 12:15 Francesco Potorti`
  2002-09-26  5:17 ` Eli Zaretskii
  0 siblings, 1 reply; 5+ messages in thread
From: Francesco Potorti` @ 2002-09-25 12:15 UTC (permalink / raw)


While preparing a pretest, I did a make bootstrap after upgrading my
default gcc to 3.2.  I get many of these:

gcc -c -D_BSD_SOURCE   -Demacs -DHAVE_CONFIG_H -DUSE_LUCID  -I. -I/home/pot/gnu/emacs-pretest/src -D_BSD_SOURCE -I/usr/X11R6/include -g -O2 -DPURESIZE=5000000 -I../src dired.c
In file included from dired.c:93:
regex.h:541:1: warning: "__restrict_arr" redefined
In file included from /usr/include/features.h:283,
                 from /usr/lib/gcc-lib/i386-linux/3.2.1/include/stdio.h:37,
                 from s/gnu-linux.h:157,
                 from config.h:371,
                 from dired.c:23:
/usr/include/sys/cdefs.h:212:1: warning: this is the location of the previous definition

The warning does not appear when using gcc 2.95 (and did not appear with
gcc 3.0).  The reason is that src/regex.h has this:


===File ~/gnu/emacs-pretest/src/regex.h=====================
/* For now unconditionally define __restrict_arr to expand to nothing.
   Ideally we would have a test for the compiler which allows defining
   it to restrict.  */
#define __restrict_arr
============================================================

and <sys/cdefs.h> has this:


===File /usr/include/sys/cdefs.h============================
/* ISO C99 also allows to declare arrays as non-overlapping.  The syntax is
     array_name[restrict]
   GCC 3.1 supports this.  */
#if __GNUC_PREREQ (3,1) && !defined __GNUG__
# define __restrict_arr	__restrict
#else
# ifdef __GNUC__
#  define __restrict_arr	/* Not supported in old GCC.  */
# else
#  if defined __STDC_VERSION__ && __STDC_VERSION__ >= 199901L
#   define __restrict_arr	restrict
#  else
/* Some other non-C99 compiler.  */
#   define __restrict_arr	/* Not supported.  */
#  endif
# endif
#endif
============================================================

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: preparing the pretest
  2002-09-25 12:15 preparing the pretest Francesco Potorti`
@ 2002-09-26  5:17 ` Eli Zaretskii
  2002-09-26 21:45   ` Richard Stallman
  2002-09-30  8:13   ` Francesco Potorti`
  0 siblings, 2 replies; 5+ messages in thread
From: Eli Zaretskii @ 2002-09-26  5:17 UTC (permalink / raw)
  Cc: Emacs developers


On Wed, 25 Sep 2002, Francesco Potorti` wrote:

> gcc -c -D_BSD_SOURCE   -Demacs -DHAVE_CONFIG_H -DUSE_LUCID  -I. -I/home/pot/gnu/emacs-pretest/src -D_BSD_SOURCE -I/usr/X11R6/include -g -O2 -DPURESIZE=5000000 -I../src dired.c
> In file included from dired.c:93:
> regex.h:541:1: warning: "__restrict_arr" redefined
> In file included from /usr/include/features.h:283,
>                  from /usr/lib/gcc-lib/i386-linux/3.2.1/include/stdio.h:37,
>                  from s/gnu-linux.h:157,
>                  from config.h:371,
>                  from dired.c:23:
> /usr/include/sys/cdefs.h:212:1: warning: this is the location of the previous definition
> 
> The warning does not appear when using gcc 2.95 (and did not appear with
> gcc 3.0).  The reason is that src/regex.h has this:
> 
> 
> ===File ~/gnu/emacs-pretest/src/regex.h=====================
> /* For now unconditionally define __restrict_arr to expand to nothing.
>    Ideally we would have a test for the compiler which allows defining
>    it to restrict.  */
> #define __restrict_arr

I suggest to make this definition conditional:

  #ifndef __restrict_arr
  #define __restrict_arr
  #endif

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: preparing the pretest
  2002-09-26  5:17 ` Eli Zaretskii
@ 2002-09-26 21:45   ` Richard Stallman
  2002-09-30  8:13   ` Francesco Potorti`
  1 sibling, 0 replies; 5+ messages in thread
From: Richard Stallman @ 2002-09-26 21:45 UTC (permalink / raw)
  Cc: pot, emacs-devel

    I suggest to make this definition conditional:

      #ifndef __restrict_arr
      #define __restrict_arr
      #endif

Thanks.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: preparing the pretest
  2002-09-26  5:17 ` Eli Zaretskii
  2002-09-26 21:45   ` Richard Stallman
@ 2002-09-30  8:13   ` Francesco Potorti`
  2002-10-01  6:18     ` Richard Stallman
  1 sibling, 1 reply; 5+ messages in thread
From: Francesco Potorti` @ 2002-09-30  8:13 UTC (permalink / raw)
  Cc: Emacs developers

   > gcc -c -D_BSD_SOURCE   -Demacs -DHAVE_CONFIG_H -DUSE_LUCID  -I. -I/home/pot/gnu/emacs-pretest/src -D_BSD_SOURCE -I/usr/X11R6/include -g -O2 -DPURESIZE=5000000 -I../src dired.c
   > In file included from dired.c:93:
   > regex.h:541:1: warning: "__restrict_arr" redefined
   > In file included from /usr/include/features.h:283,
   >                  from /usr/lib/gcc-lib/i386-linux/3.2.1/include/stdio.h:37,
   >                  from s/gnu-linux.h:157,
   >                  from config.h:371,
   >                  from dired.c:23:
   > /usr/include/sys/cdefs.h:212:1: warning: this is the location of the previous definition
   > 
   > The warning does not appear when using gcc 2.95 (and did not appear with
   > gcc 3.0).  The reason is that src/regex.h has this:
   > 
   > 
   > ===File ~/gnu/emacs-pretest/src/regex.h=====================
   > /* For now unconditionally define __restrict_arr to expand to nothing.
   >    Ideally we would have a test for the compiler which allows defining
   >    it to restrict.  */
   > #define __restrict_arr
   
   I suggest to make this definition conditional:
   
     #ifndef __restrict_arr
     #define __restrict_arr
     #endif
   
Done, also in the pretest branch.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: preparing the pretest
  2002-09-30  8:13   ` Francesco Potorti`
@ 2002-10-01  6:18     ` Richard Stallman
  0 siblings, 0 replies; 5+ messages in thread
From: Richard Stallman @ 2002-10-01  6:18 UTC (permalink / raw)
  Cc: eliz, emacs-devel

	 #ifndef __restrict_arr
	 #define __restrict_arr
	 #endif

    Done, also in the pretest branch.

Thanks.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2002-10-01  6:18 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-09-25 12:15 preparing the pretest Francesco Potorti`
2002-09-26  5:17 ` Eli Zaretskii
2002-09-26 21:45   ` Richard Stallman
2002-09-30  8:13   ` Francesco Potorti`
2002-10-01  6:18     ` Richard Stallman

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).