[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstr
From: |
Alan Mackenzie |
Subject: |
Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstraps. |
Date: |
Sun, 25 Nov 2018 14:31:25 +0000 |
User-agent: |
Mutt/1.10.1 (2018-07-13) |
Hello, Charles.
Thanks for trying this out!
On Sun, Nov 25, 2018 at 12:26:45 +0100, Charles A. Roelli wrote:
> > Date: Fri, 23 Nov 2018 13:09:05 +0000
> > From: Alan Mackenzie <address@hidden>
> >
> > Although the branch works, it has been tested solely on 64-bit
> > GNU/Linux, the only system I have. This despite some fairly hefty
> > changes in lisp.h.
> "make bootstrap" prints the following errors here on the
> scratch/accurate-warning-pos branch:
> CC dispnew.o
> In file included from dispnew.c:27:
> lisp.h: In function ‘SYMBOLP’:
> lisp.h:1052: error: used struct type value where scalar is required
> lisp.h: In function ‘XSYMBOL’:
> lisp.h:1083: error: wrong type argument to unary exclamation mark
> lisp.h: In function ‘EQ’:
> lisp.h:1233: error: used struct type value where scalar is required
> lisp.h:1233: error: invalid operands to binary == (have ‘Lisp_Object’ and
> ‘Lisp_Object’)
> lisp.h:1233: error: invalid operands to binary == (have ‘Lisp_Object’ and
> ‘Lisp_Object’)
> (This is macOS with GCC 4.2.1.)
> Seems like the compiler is raising errors when the var
> "Vsymbols_with_pos_enabled" (a Lisp_Object) is used in a true/false
> context.
Yes, indeed.
I hope the following patch will fix it, and hope also there won't be too
many similar bugs to fix.
diff --git a/src/lisp.h b/src/lisp.h
index 4dfd065629..802c9e4259 100644
--- a/src/lisp.h
+++ b/src/lisp.h
@@ -395,7 +395,7 @@ typedef EMACS_INT Lisp_Word;
/* verify (NIL_IS_ZERO) */
#define lisp_h_EQ(x, y) ((XLI ((x)) == XLI ((y))) \
- || (Vsymbols_with_pos_enabled \
+ || (XLI (Vsymbols_with_pos_enabled) \
&& (SYMBOL_WITH_POS_P ((x)) \
? BARE_SYMBOL_P ((y)) \
? (XSYMBOL_WITH_POS((x)))->sym == (y) \
@@ -424,7 +424,7 @@ typedef EMACS_INT Lisp_Word;
#define lisp_h_BARE_SYMBOL_P(x) TAGGEDP ((x), Lisp_Symbol)
/* verify (NIL_IS_ZERO) */
#define lisp_h_SYMBOLP(x) ((BARE_SYMBOL_P ((x)) || \
- (Vsymbols_with_pos_enabled && (SYMBOL_WITH_POS_P
((x))))))
+ (XLI (Vsymbols_with_pos_enabled) &&
(SYMBOL_WITH_POS_P ((x))))))
#define lisp_h_TAGGEDP(a, tag) \
(! (((unsigned) (XLI (a) >> (USE_LSB_TAG ? 0 : VALBITS)) \
- (unsigned) (tag)) \
@@ -463,7 +463,7 @@ typedef EMACS_INT Lisp_Word;
/* verify (NIL_IS_ZERO) */
# define lisp_h_XSYMBOL(a) \
(eassert (SYMBOLP ((a))), \
- (!Vsymbols_with_pos_enabled \
+ (!XLI (Vsymbols_with_pos_enabled) \
? (XBARE_SYMBOL ((a))) \
: (BARE_SYMBOL_P ((a))) \
? (XBARE_SYMBOL ((a))) \
--
Alan Mackenzie (Nuremberg, Germany).
- scratch/accurate-warning-pos: First tentative successes., Alan Mackenzie, 2018/11/17
- Re: scratch/accurate-warning-pos: First tentative successes., Eli Zaretskii, 2018/11/17
- Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstraps., Alan Mackenzie, 2018/11/23
- Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstraps., Charles A. Roelli, 2018/11/25
- Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstraps.,
Alan Mackenzie <=
- Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstraps., Andreas Schwab, 2018/11/25
- Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstraps., Alan Mackenzie, 2018/11/25
- Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstraps., Eli Zaretskii, 2018/11/25
- Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstraps., Alan Mackenzie, 2018/11/25
- Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstraps., Eli Zaretskii, 2018/11/25
- Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstraps., Alan Mackenzie, 2018/11/25
- Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstraps., Alan Mackenzie, 2018/11/25
- Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstraps., Stefan Monnier, 2018/11/25
- Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstraps., Alan Mackenzie, 2018/11/25
- Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstraps., Stefan Monnier, 2018/11/25