emacs-devel
[Top][All Lists]
Advanced

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

Re: Broken dbusbind.c


From: Michael Albinus
Subject: Re: Broken dbusbind.c
Date: Tue, 29 Dec 2020 21:20:57 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

John Yates <john@yates-sheets.org> writes:

Hi John,

> Here is more context:
>
> /* Check whether TYPE is a basic DBusType.  */
> #ifdef HAVE_DBUS_TYPE_IS_VALID
> #define XD_BASIC_DBUS_TYPE(type) \
>   (dbus_type_is_valid (type) && dbus_type_is_basic (type))
> #else
> #define XD_BASIC_DBUS_TYPE(type) \
>   ((type == DBUS_TYPE_BYTE) \
>    || (type == DBUS_TYPE_BOOLEAN) \
>    || (type == DBUS_TYPE_INT16) \
>    || (type == DBUS_TYPE_UINT16) \
>    || (type == DBUS_TYPE_INT32) \
>    || (type == DBUS_TYPE_UINT32) \
>    || (type == DBUS_TYPE_INT64) \
>    || (type == DBUS_TYPE_UINT64) \
>    || (type == DBUS_TYPE_DOUBLE) \
>    || (type == DBUS_TYPE_STRING) \
>    || (type == DBUS_TYPE_OBJECT_PATH) \
>    || (type == DBUS_TYPE_SIGNATURE) \
> #ifdef DBUS_TYPE_UNIX_FD
>    || (type == DBUS_TYPE_UNIX_FD) \
> #endif
>    )
> #endif
>
> Notice that, if HAVE_DBUS_TYPE_IS_VALID is defined
> we get the first #define XD_BASIC_DBUS_TYPE and
> all will be well.
>
> OTOH, if HAVE_DBUS_TYPE_IS_VALID is undefined
> we get the broken #define.  (Imagine what the C lexer
> sees when each \<NL> disappears.  The result is a line
> with a #ifdef DBUS_TYPE_UNIX_FD tacked onto the
> end.)

Might be. However, ...

> (For what it is worth I am on Ubuntu 20.10.)

... I'm also testing on Ubuntu 20.10. Why is HAVE_DBUS_TYPE_IS_VALID
undefined for you?

> /john

Best regards, Michael.



reply via email to

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