Mail Archives: djgpp/2000/08/31/19:00:58
Newsgroup: comp.os.msdos.djgpp
From: Damian Yerrick <Bullcr_pd_yerrick AT hotmail DOT comRemoveBullcr_p>
On Thu, 31 Aug 2000 00:05:38 GMT
>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).
Are .txt files guarenteed to be ASCII files? I'm not aware of any such
requirement - though I've never seen otherwise.
>>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?
In all honesty, I don't know. When I replied, I'd just been reading a
threat on the subject on comp.lang.c and it was argued quite hotly
that it is FAPP a mortal sin to assume your compter uses ASCII
encoding, so I guess I was a little brain washed ;-)
- Raw text -