GNU bug report logs - #13734
24.3.50; ../src/lisp.h:2485:10: error: address expression must be an lvalue or a function designator

Previous Next

Package: emacs;

Reported by: Peter Dyballa <Peter_Dyballa <at> Freenet.DE>

Date: Sun, 17 Feb 2013 11:54:01 UTC

Severity: minor

Tags: moreinfo

Found in version 24.3.50

Done: Andreas Schwab <schwab <at> linux-m68k.org>

Bug is archived. No further changes may be made.

Full log


Message #35 received at 13734 <at> debbugs.gnu.org (full text, mbox):

From: Peter Dyballa <Peter_Dyballa <at> Freenet.DE>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: rgm <at> gnu.org, schwab <at> linux-m68k.org, 13734 <at> debbugs.gnu.org
Subject: Re: bug#13734: 24.3.50;
	../src/lisp.h:2485:10: error: address expression must be an lvalue
	or	a function designator
Date: Sat, 2 Mar 2013 00:25:41 +0100
Am 01.03.2013 um 21:27 schrieb Eli Zaretskii:

> Can you post a cpp-preprocessed code of that line in lisp.h, when
> configured --with-wide-int, from the compilation of a C source which
> triggers the error (lwlib.c, I think)?

I can't! In the middle of C pre-processing this happens:

	In file included from lwlib.c:24:
	../src/lisp.h:3841:52: error: macro "EQ" requires 2 arguments, but only 1 given

I have the output from the configuration with 32-bit libraries, and I can also produce the output when configured for 64-bit libraries…


The original GCC invocation when configured --with-wide-int was:

	gcc-4.2 -std=gnu99 -c -I/sw/include  -I/usr/X11/include -I/sw/include -I/sw/include/freetype2 -I/usr/X11/include -I/usr/X11R6/include  `echo  | sed 's/ -Wwrite-strings//'`   -g3 -H -pipe -fPIC -fno-common -Os -march=core2 -mtune=core2 -m32 -fomit-frame-pointer -msse4.2 -Demacs -I../src -I.../emacs-24.3.50/lwlib -I.../emacs-24.3.50/lwlib/../src -I../lib -I.../emacs-24.3.50/lwlib/../lib lwlib.c

which I changed to

	gcc-4.2 -std=gnu99 -E -I/sw/include  -I/usr/X11/include -I/sw/include -I/sw/include/freetype2 -I/usr/X11/include -I/usr/X11R6/include  `echo  | sed 's/ -Wwrite-strings//'`   -g3 -H -pipe -fPIC -fno-common -Os -march=core2 -mtune=core2 -m32 -fomit-frame-pointer -msse4.2 -Demacs -I../src -I.../emacs-24.3.50/lwlib -I.../emacs-24.3.50/lwlib/../src -I../lib -I.../emacs-24.3.50/lwlib/../lib lwlib.c -o lwlib-wide.ii

being invoked on the command line. I then removed the -H flag and also -o lwlib-wide.ii because there must be some output until the error occurs, at least. And it did! So I finally invoked

	gcc-4.2 -std=gnu99 -E -I/sw/include  -I/usr/X11/include -I/sw/include -I/sw/include/freetype2 -I/usr/X11/include -I/usr/X11R6/include  `echo  | sed 's/ -Wwrite-strings//'`   -g3 -pipe -fPIC -fno-common -Os -march=core2 -mtune=core2 -m32 -fomit-frame-pointer -msse4.2 -Demacs -I../src -I.../emacs-24.3.50/lwlib -I.../emacs-24.3.50/lwlib/../src -I../lib -I.../emacs-24.3.50/lwlib/../lib lwlib.c > lwlib-wide.ii

'wc lwlib-wide.ii' delivers

   23447   55614  560933 lwlib-wide.ii

This is the pre-processed function:

	static __attribute__ ((__unused__)) Lisp_Object *
	aref_addr (Lisp_Object array, ptrdiff_t idx)
	{
	  return & (((void) (0 && ((((enum Lisp_Type) ((EMACS_UINT) ((array)) >> VALBITS)) == Lisp_Vectorlike)))), (struct Lisp_Vector *) ((gl_uintptr_t) (((array) & (9223372036854775807LL >> (3 - 1)))) | DATA_SEG_BITS)))->contents[idx];
	}


And this is – presumingly – the function with EQ with only one argument:

	static __attribute__ ((__unused__)) int
	functionp (Lisp_Object object)
	{
	  if ((((enum Lisp_Type) ((EMACS_UINT) ((object)) >> VALBITS)) == Lisp_Symbol) && !((Ffboundp (object)) == (Qnil)))
	    {
	      object = Findirect_function (object, Qt);
	
	      if ((((enum Lisp_Type) ((EMACS_UINT) ((object)) >> VALBITS)) == Lisp_Cons) && (((0 + (((((void) (0 && ((((enum Lisp_Type) ((EMACS_UINT) ((object)) >> VALBITS)) == Lisp_Cons)))), (struct Lisp_Cons *) ((gl_uintptr_t) (((object) & (9223372036854775807LL >> (3 - 1)))) | DATA_SEG_BITS)))->car)))) == (Qautoload)))
	 {
	
	
	   int i;
	   for (i = 0; i < 4 && (((enum Lisp_Type) ((EMACS_UINT) ((object)) >> VALBITS)) == Lisp_Cons); i++)
	     object = (0 + (((((void) (0 && ((((enum Lisp_Type) ((EMACS_UINT) ((object)) >> VALBITS)) == Lisp_Cons)))), (struct Lisp_Cons *) ((gl_uintptr_t) (((object) & (9223372036854775807LL >> (3 - 1)))) | DATA_SEG_BITS)))->u.cdr)));
	
	   return ! ((((enum Lisp_Type) ((EMACS_UINT) ((object)) >> VALBITS)) == Lisp_Cons) && !EQ, Qnil));
	 }
	    }
	
	  if (((((enum Lisp_Type) ((EMACS_UINT) ((object)) >> VALBITS)) == Lisp_Vectorlike) && ((((struct vectorlike_header *) ((gl_uintptr_t) (((object) & (9223372036854775807LL >> (3 - 1)))) | DATA_SEG_BITS)))->size & ((((1) ? ~ ((1) ? (- ((0) + 1) << ((32) ? (32) - 1 : 0)) : (0)) : ((((0) + 1) << ((32) ? (32) - 1 - (1) : 0)) - 1) * 2 + 1) - ((1) ? ~ ((1) ? (- ((0) + 1) << ((32) ? (32) - 1 : 0)) : (0)) : ((((0) + 1) << ((32) ? (32) - 1 - (1) : 0)) - 1) * 2 + 1) / 2) | PVEC_TYPE_MASK)) == ((((1) ? ~ ((1) ? (- ((0) + 1) << ((32) ? (32) - 1 : 0)) : (0)) : ((((0) + 1) << ((32) ? (32) - 1 - (1) : 0)) - 1) * 2 + 1) - ((1) ? ~ ((1) ? (- ((0) + 1) << ((32) ? (32) - 1 : 0)) : (0)) : ((((0) + 1) << ((32) ? (32) - 1 - (1) : 0)) - 1) * 2 + 1) / 2) | ((PVEC_SUBR) << PSEUDOVECTOR_AREA_BITS)))))
	    return (((void) (0 && (((((enum Lisp_Type) ((EMACS_UINT) ((object)) >> VALBITS)) == Lisp_Vectorlike) && ((((struct vectorlike_header *) ((gl_uintptr_t) (((object) & (9223372036854775807LL >> (3 - 1)))) | DATA_SEG_BITS)))->size & ((((1) ? ~ ((1) ? (- ((0) + 1) << ((32) ? (32) - 1 : 0)) : (0)) : ((((0) + 1) << ((32) ? (32) - 1 - (1) : 0)) - 1) * 2 + 1) - ((1) ? ~ ((1) ? (- ((0) + 1) << ((32) ? (32) - 1 : 0)) : (0)) : ((((0) + 1) << ((32) ? (32) - 1 - (1) : 0)) - 1) * 2 + 1) / 2) | PVEC_TYPE_MASK)) == ((((1) ? ~ ((1) ? (- ((0) + 1) << ((32) ? (32) - 1 : 0)) : (0)) : ((((0) + 1) << ((32) ? (32) - 1 - (1) : 0)) - 1) * 2 + 1) - ((1) ? ~ ((1) ? (- ((0) + 1) << ((32) ? (32) - 1 : 0)) : (0)) : ((((0) + 1) << ((32) ? (32) - 1 - (1) : 0)) - 1) * 2 + 1) / 2) | ((PVEC_SUBR) << PSEUDOVECTOR_AREA_BITS))))))), (struct Lisp_Subr *) ((gl_uintptr_t) (((object) & (9223372036854775807LL >> (3 - 1)))) | DATA_SEG_BITS)))->max_args != UNEVALLED;
	  else if (((((enum Lisp_Type) ((EMACS_UINT) ((object)) >> VALBITS)) == Lisp_Vectorlike) && ((((struct vectorlike_header *) ((gl_uintptr_t) (((object) & (9223372036854775807LL >> (3 - 1)))) | DATA_SEG_BITS)))->size & ((((1) ? ~ ((1) ? (- ((0) + 1) << ((32) ? (32) - 1 : 0)) : (0)) : ((((0) + 1) << ((32) ? (32) - 1 - (1) : 0)) - 1) * 2 + 1) - ((1) ? ~ ((1) ? (- ((0) + 1) << ((32) ? (32) - 1 : 0)) : (0)) : ((((0) + 1) << ((32) ? (32) - 1 - (1) : 0)) - 1) * 2 + 1) / 2) | PVEC_TYPE_MASK)) == ((((1) ? ~ ((1) ? (- ((0) + 1) << ((32) ? (32) - 1 : 0)) : (0)) : ((((0) + 1) << ((32) ? (32) - 1 - (1) : 0)) - 1) * 2 + 1) - ((1) ? ~ ((1) ? (- ((0) + 1) << ((32) ? (32) - 1 : 0)) : (0)) : ((((0) + 1) << ((32) ? (32) - 1 - (1) : 0)) - 1) * 2 + 1) / 2) | ((PVEC_COMPILED) << PSEUDOVECTOR_AREA_BITS)))))
	    return 1;
	  else if ((((enum Lisp_Type) ((EMACS_UINT) ((object)) >> VALBITS)) == Lisp_Cons))
	    {
	      Lisp_Object car = (0 + (((((void) (0 && ((((enum Lisp_Type) ((EMACS_UINT) ((object)) >> VALBITS)) == Lisp_Cons)))), (struct Lisp_Cons *) ((gl_uintptr_t) (((object) & (9223372036854775807LL >> (3 - 1)))) | DATA_SEG_BITS)))->car)));
	      return ((car) == (Qlambda)) || ((car) == (Qclosure));
	    }
	  else
	    return 0;
	}

I wrote "presumingly" because GNU Emacs did not perform forward-sexp on the opening { starting the function definition.


--
Greetings

  Pete

Basic, n.:
	A programming language. Related to certain social diseases in that those who have it will not admit it in polite company.





This bug report was last modified 12 years and 142 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.