From: Damian Yerrick Newsgroups: comp.os.msdos.djgpp Subject: Re: signed - unsigned chars Organization: Pin Eight Software Message-ID: <9mng8souup59ge1iavmcusk9044mqnoo83@4ax.com> References: <000701bf63ef$41a61440$0307028a AT prmivv03> X-Newsreader: Forte Agent 1.7/32.534 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Lines: 23 X-Trace: /Kp2luH7R0F5wESnpolL23AkAsN4IIxCp62K6ZmpXPdYuBeQZrRLujZUW5Lqrqy4M+utG2hc8zua!GFQ2TJRGBl4eXMsgLpozVsqbkOJghT31H8XpwocWA5+WVHt0gBWdPNf/u1/4deHHoRciPXZhLg== X-Complaints-To: abuse AT gte DOT net X-Abuse-Info: Please be sure to forward a copy of ALL headers X-Abuse-Info: Otherwise we will be unable to process your complaint properly NNTP-Posting-Date: Fri, 21 Jan 2000 13:30:50 GMT Distribution: world Date: Fri, 21 Jan 2000 13:30:50 GMT To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com "Petr Maxa" wrote in message <000701bf63ef$41a61440$0307028a AT prmivv03>... >Hi I am just porting a code from Borland C++, and there is a possibility in >"Compiler->Code Generation" to set "Unsigned chars" (option -K) and in "C++ >Options->C++ Compatibility" set "Do not treat 'char' as distinct type" >(option -K2). > >I am working on a project, where is very important to have all chars as >unsigned types. There is now a problem to accomplish this, as compiler >treats constant chars as signed types. typedef unsigned char byte; and use byte instead of char. const byte tilde = '~'; -- Damian Yerrick http://yerricde.tripod.com/ View full sig at http://www.rose-hulman.edu/~yerricde/sig.html Comment on story ideas at http://home1.gte.net/frodo/quickjot.html And yes, I have set my attribute line to emulate Outhouse Express.