From: vance AT deneb DOT com (Stephen Vance) Subject: Re: some unusual errors 22 Sep 1998 05:57:46 -0700 Message-ID: <360669BE.A06C57B2.cygnus.gnu-win32@deneb.com> References: <199809182005 DOT QAA03634 AT venus DOT solidum DOT com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit To: Michael Richardson Cc: gnu-win32 AT cygnus DOT com Michael Richardson wrote: > I get a lot of warnings like this: > > strtod.c:1239: warning: subscript has type `char' > > This line of code is actually: > > for(s = s00; isspace(*s); s++) > > which confuses me. What, if not "char" should isspace() take??? The reason isspace() and friends are defined this way is that special characters like EOF are not always represented by "char". The standard leaves the choice of "signed char" or "unsigned char" as the default "char" as implementation defined. EOF is usually -1. If you want 8-bit chars, -1 maps to an already defined char in either representation, but as an int it is distinct. -- Stephen Vance | http://www.deneb.com Deneb Robotics, Inc. | mailto:vance AT deneb DOT com 5500 New King Street | Phone: (248) 267-9696 Troy, MI 48098-2615 | Fax: (248) 267-8585 What is done well is done quickly enough. -Augustus Caesar - For help on using this list (especially unsubscribing), send a message to "gnu-win32-request AT cygnus DOT com" with one line of text: "help".