Definition of isprint()

Larry Jones scjones at sdrc.UUCP
Wed Dec 14 08:40:13 AEST 1988


We're using SAS C on an IBM mainframe and just ran into an
interesting problem.  SAS has defined "printing character" in
terms of what is printable on an ancient line printer so some
obviously printable characters such as "{", "}", "[", "]", "\",
and "!" cause isprint() to return 0!

Am I the only one who thinks this is less than useful?

The dpANS seems to allow this, since "printing character" is
implementation defined, but it seems to me that the C source
character set should be specified as printable in the "C" locale.
The problem seems to be that the exact semantics of ispunct() are
not specified for the "C" locale.

Was this an oversight or was it intentional?  I was there, but I
don't remember.

----
Larry Jones                         UUCP: uunet!sdrc!scjones
SDRC                                      scjones at sdrc.uucp
2000 Eastman Dr.                    BIX:  ltl
Milford, OH  45150                  AT&T: (513) 576-2070
"Save the Quayles" - Mark Russell



More information about the Comp.std.c mailing list