delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/08/31/04:45:23

From: Damian Yerrick <Bullcr_pd_yerrick AT hotmail DOT comRemoveBullcr_p>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: BAD strupr, BAD getw
Organization: Pin Eight Software http://pineight.8m.com/
Message-ID: <lg7rqsgqt0j335li1o9e294c2b2h1p81hr@4ax.com>
References: <ue4cqsg0k83m0461605mnkssjo43odacen AT 4ax DOT com> <39a9a972 DOT 29351296 AT news DOT wins DOT uva DOT nl>
X-Newsreader: Forte Agent 1.7/32.534
MIME-Version: 1.0
Lines: 44
X-Trace: +rnM+ksvmowk2qB6pgq2ic3Tb15HBwrnZKIkvXSIwcKuVE+j0AB7dp2THieXnqZPK+OZK2jsn2z3!54Le3P/+Fk4RTPgVcDTJvSG7ONPj/zkDFeNeiX70SwNObq3kpU9YH7+B8f3bgimZzMSajlXdSzh8!qw==
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: Thu, 31 Aug 2000 00:05:38 GMT
Distribution: world
Date: Thu, 31 Aug 2000 00:05:38 GMT
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

On Wed, 30 Aug 2000 22:14:30 GMT, eglebbk AT dds DOT nl (Evert Glebbeek)
wrote:

>Newsgroup: comp.os.msdos.djgpp
> From: Radical NetSurfer <radsmail AT juno DOT com>
> On Fri, 25 Aug 2000 02:44:18 -0400
>
>>Tonight we had to create our very own code for
>>
>>strupr
>>
>>simply because DJGPP does NOT implement this function
>>correctly at ALL :(

Or implement a function
  char *strxlate(char *string, int (*xlatefunc)(int));
where strupr(string) would be written strxlate(string, toupper)

>Portable programs shouldn't be assuming an ASCII character set.

They can if they're reading files guaranteed to be ASCII or something
similar (e.g. .txt files).

>IMHO, the point of programming in C is to actually produce
>portable code.

According to the ANSI/ISO C standard, is a file created by fopen()
(ANSI, POSIX) and written to with fprintf() (ANSI, POSIX) guaranteed
to be usable in another program that uses fopen() (ANSI, POSIX),
fgets() (ANSI, POSIX), and sscanf() (ANSI, POSIX)?

Are there any systems that:
 o are in common use in The Year 2000,
 o are typically programmed in C, and
 o use an encoding for Basic Latin other than ASCII, such as Baudot or
   EBCDIC?

-- 
MS (n)  1. A debilitating and surprisingly widespread affliction
  that renders the sufferer barely able to perform the simplest
  task.  2. A disease, multiple sclerosis (see).

This is McAfee VirusScan. Add these two lines to your signature to
prevent the spread of signature viruses.  http://www.mcafee.com/

- Raw text -


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