Mail Archives: djgpp/1994/12/25/20:37:02
Subject: Pascal chr() and Fortran ICHAR() converted to C
With bith p2c and f2c (recent versions) I find serieux problems in
alphebetic sorting. O cours this does not happen with std ASCII chars, i.e.
less than 128, but for accented letters >= 128.
Both f2c and p2c convert things like a:=ord('z') simpling by affecting
the character 'a' to an integer. Unfortunately, if the character is above
127, then a sign extension occurs, giving a negative ord() or ICHAR().
Is this a djgpp problem (unlikely) or a simultaneous bug both in f2c and p2c.
If the seond holds, corrections shold be posted and therefore welcome.
D. Taupin
- Raw text -