From owner-freebsd-hackers Mon May 14 23:48:52 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from segfault.kiev.ua (segfault.kiev.ua [193.193.193.4]) by hub.freebsd.org (Postfix) with ESMTP id C8D2237B422 for ; Mon, 14 May 2001 23:48:43 -0700 (PDT) (envelope-from netch@iv.nn.kiev.ua) Received: (from uucp@localhost) by segfault.kiev.ua (8) with UUCP id JSP10096; Tue, 15 May 2001 09:48:21 +0300 (EEST) (envelope-from netch@iv.nn.kiev.ua) Received: (from netch@localhost) by iv.nn.kiev.ua (8.11.3/8.11.3) id f4F6aAP02035; Tue, 15 May 2001 09:36:10 +0300 (EEST) (envelope-from netch) Date: Tue, 15 May 2001 09:36:10 +0300 From: Valentin Nechayev To: Alfred Perlstein Cc: Erik Trulsson , hackers@FreeBSD.ORG Subject: Re: wint_t Message-ID: <20010515093610.A1835@iv.nn.kiev.ua> References: <20010514164401.A61243@dragon.nuxi.com> <20010515023221.A41666@student.uu.se> <20010514174502.J2009@fw.wintelcom.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20010514174502.J2009@fw.wintelcom.net>; from bright@wintelcom.net on Mon, May 14, 2001 at 05:45:02PM -0700 X-42: On Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Mon, May 14, 2001 at 17:45:02, bright (Alfred Perlstein) wrote about "Re: wint_t": > > The C standard says that wchar_t should be able to all members of thye > > largest extended chracter set. AFAIK FreeBSD doesn't have any character > > set which requires more than 8 bits. > > wint_t should also be able to hold all members of the largest character > > set plus one extra value (WEOF). Also it must be at least 16 bits. > Wouldn't it be kinda painful unless we did this with a 16 bit type? Modern Unicode allows character codes more than 65534. wchar_t(65536) is Egyptian glyph;) Maximum allowed AFAIR is 2**31-1. So at least 32 bits integer type required if you don't want adapt system to former millennium requires. But wint_t must be no narrower than wchar_t. and define wchar_t as unsigned long. System headers define wchar_t as int (thru _BSD_WCHAR_T_ and _BSD_CT_RUNE_T_). This difference in size and signness is at least annoying. I suppose wchar_t should be __uint32_t, and wint_t - __int32_t, but this may break binary compatibility. /netch To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message