delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2000/03/06/03:08:15

Date: Mon, 6 Mar 2000 09:37:37 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: Alain Magloire <alain AT qnx DOT com>
cc: djgpp-workers AT delorie DOT com
Subject: Re: iso646.h and some questions
In-Reply-To: <200003052154.QAA17956@qnx.com>
Message-ID: <Pine.SUN.3.91.1000306093659.9921C@is>
MIME-Version: 1.0
Reply-To: djgpp-workers AT delorie DOT com
Errors-To: dj-admin AT delorie DOT com
X-Mailing-List: djgpp-workers AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Sun, 5 Mar 2000, Alain Magloire wrote:

> > > No, wchar.h simply includes stddef.h.  So there's no problem in that 
> > > case.
> > 
> > No. The standard says NULL is defined in wchar.h and in stddef.h.
> 
> Yes but it does not say, it should be a specific macro

Right.  So our wchar.h includes stddef.h.

> It is up to the implementor of the library, whether you do
> 1)
> #include <stddef.h>
> 2)
> #ifndef NULL
> # define NULL 0
> #endif

Redefining NULL can be tricky, since IIRC C++ has its own ideas about
its definition.  So I think in the case of NULL, it is best to avoid
the second alternative.

> Is there a conflict between <wchar.h> and <stddef.h> that will
> prohibit <stddef.h> to be included ?

I don't recall any complaints.  OTOH, the wide-character support in
DJGPP is a trivial no-op, so I guess we won't know until it is
improved and somebody actually uses it.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019