Path: utzoo!attcan!uunet!charyb!will From: will@kfw.COM (Will Crowder) Newsgroups: comp.lang.c Subject: Re: Determining machine characteristics (was: IsUnsigned() function?) Message-ID: <1990Jul27.162611.14828@kfw.COM> Date: 27 Jul 90 16:26:11 GMT References: <1990Jul16.214155.5087@Neon.Stanford.EDU> <2936@mtung.ATT.COM> <17148@haddock.ima.isc.com> <3473@goanna.cs.rmit.oz.au> Reply-To: will@kfw.com (Will Crowder) Organization: KFW Corporation, Newbury Park, CA Lines: 15 In article <3473@goanna.cs.rmit.oz.au> ok@goanna.cs.rmit.oz.au (Richard A. O'Keefe) writes: >It's clear that an arithmetic expression which appears in _code_ must be >evaluated as if evaluated by the target machine, but need arithmetic >expressions in #ifs be evaluated the same way? Is it possible for > #if is_ones_complement() >to succeed and > if (is_ones_complement()) >to fail? Yes, it is quite possible for that to fail. The C preprocessor knows nothing about the C language itself. For instance, try using a cast in a preprocessor #if. Will