Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10 5/3/83 based; site hou2d.UUCP
Path: utzoo!watmath!clyde!burl!ulysses!mhuxr!mhuxt!houxm!hou2d!osd
From: osd@hou2d.UUCP (Orlando Sotomayor-Diaz)
Newsgroups: mod.std.c
Subject: mod.std.c Digest V8#12
Message-ID: <608@hou2d.UUCP>
Date: Wed, 17-Jul-85 07:38:59 EDT
Article-I.D.: hou2d.608
Posted: Wed Jul 17 07:38:59 1985
Date-Received: Thu, 18-Jul-85 05:39:18 EDT
Organization: AT&T Bell Labs, Holmdel NJ
Lines: 177
Approved: osd@hou2d.UUCP

From: Orlando Sotomayor-Diaz (The Moderator) 


mod.std.c Digest            Tue, 16 Jul 85       Volume 8 : Issue  12 

Today's Topics:
                     D.10.1.5 The strtol function
                     D.10.4.5 The system function
D.11.2.2 the memset function, D.11.5.1 memchr, D.11.5.2 strchr,  D.11.5.5 strrchr function
                D.11.4 Length and comparison function
                   D.11 String handling 
                     D.9.4.2 The rename function
                     D.9.6.1 The fprintf function
       D.9.6.2 The fscanf function & D.9.6.4 The scanf function
                     D.9.7.11 The ungetc function
                      D.9.7.3 The fputc function
       D.9.7.7 The gets function & D.9.8.2 The fwrite function
                 D.9.8 Direct input/output functions
      D.9.9.1 The fseek function & D.9.10.4 The perror function
----------------------------------------------------------------------

Date: Sat, 13 Jul 85 00:21:14 edt
From: hcr!lsuc!msb
Subject: D.10.1.5 The strtol function
To: hcr!cbosgd!std-c

Change "between 2 and 36" (which does not mean inclusive) to "from 2 to 36"
or some such phrase (which does).

------------------------------

Date: Sat, 13 Jul 85 00:21:14 edt
From: hcr!lsuc!msb
Subject: D.10.4.5 The system function
To: hcr!cbosgd!std-c

"If the argument is a null pointer, the system function returns zero to
indicate that there is no command processor."

Say WHAT?

------------------------------

Date: Sat, 13 Jul 85 00:21:14 edt
From: hcr!lsuc!msb
Subject: D.11.2.2 the memset function, D.11.5.1 memchr, D.11.5.2 strchr,  D.11.5.5 strrchr function
To: hcr!cbosgd!std-c

All four of these use an int argument to receive what is really a character.
Memset specifies that the argument is cast to unsigned char; I don't know
why it's not plain char, unless some existing implementation has it that way.
In the case of the other three functions the action if (char)c != c, or
(unsigned char)c != c, or whatever it should be, is unspecified.
It should be specified or explicitly undefined.

------------------------------

Date: Sat, 13 Jul 85 00:21:14 edt
From: hcr!lsuc!msb
Subject: D.11.4 Length and comparison function
To: hcr!cbosgd!std-c

"If one of the characters has its high-order bit set, the result is
implementation-defined."

This contrasts with the language of C.1.2.5, Types, where instead of things
like "high-order bits" we talk about characters "that can" or cannot "be
specified as a single-character character constant without using an octal
or hexadecimal escape sequence".  If this variation is intentional, fine.

		 { decvax | ihnp4 | watmath | ... } !utzoo!lsuc!msb
		    also via { hplabs | amd | ... } !pesnta!lsuc!msb
Mark Brader		and		   uw-beaver!utcsri!lsuc!msb

------------------------------

Date: Sat, 13 Jul 85 00:21:14 edt
From: hcr!lsuc!msb
Subject: D.11 String handling 
To: hcr!cbosgd!std-c

Why do some functions use a void * argument to access an array of characters?

------------------------------

Date: Sat, 13 Jul 85 00:21:14 edt
From: hcr!lsuc!msb
Subject: D.9.4.2 The rename function
To: hcr!cbosgd!std-c

What happens if the file named new already exists?  If it's implementation-
dependent, say so.

------------------------------

Date: Sat, 13 Jul 85 00:21:14 edt
From: hcr!lsuc!msb
Subject: D.9.6.1 The fprintf function
To: hcr!cbosgd!std-c

* 1.  Conversion specifiers seem complicated enough that it might be worth
declaring them by means of a formal grammar.  For instance, are flag
characters allowed to be repeated, so that "%--d" is legal?  If so,
what does it mean?

* 2.  It would seem reasonable to allow an implementation to limit the
total length of a format string, the total width of a field, etc.

------------------------------

Date: Sat, 13 Jul 85 00:21:14 edt
From: hcr!lsuc!msb
Subject: D.9.6.2 The fscanf function & D.9.6.4 The scanf function
To: hcr!cbosgd!std-c

The last paragraph of each of these is a bit muddy.  The two "or"'s in
the first sentance of the paragraph are not parallel, and it sounds as if
the number of assigned input items can be EOF.  Also, I think the behavior
of the stream's current read position is unspecified when the function
terminates either normally or abnormally.

------------------------------

Date: Sat, 13 Jul 85 00:21:14 edt
From: hcr!lsuc!msb
Subject: D.9.7.11 The ungetc function
To: hcr!cbosgd!std-c

There's "the character specified by c" again, but this time with no
conversion.  Do you mean (char)c again?  If not, what?

------------------------------

Date: Sat, 13 Jul 85 00:21:14 edt
From: hcr!lsuc!msb
Subject: D.9.7.3 The fputc function
To: hcr!cbosgd!std-c

Why "the character specified by c (converted to an unsigned char)"?
Why not a plain char?

------------------------------

Date: Sat, 13 Jul 85 00:21:14 edt
From: hcr!lsuc!msb
Subject: D.9.7.7 The gets function & D.9.8.2 The fwrite function
To: hcr!cbosgd!std-c

Does "indeterminate" mean something different from "undefined"?
If so, elucidate.  If not, say "undefined".

------------------------------

Date: Sat, 13 Jul 85 00:21:14 edt
From: hcr!lsuc!msb
Subject: D.9.8 Direct input/output functions
To: hcr!cbosgd!std-c

Should something be said here about text streams vs binary streams?

------------------------------

Date: Sat, 13 Jul 85 00:21:14 edt
From: hcr!lsuc!msb
Subject: D.9.9.1 The fseek function & D.9.10.4 The perror function
To: hcr!cbosgd!std-c

Both of these descriptions state what the function returns in certain
cases but not in others.

------------------------------

End of mod.std.c Digest - Tue, 16 Jul 85 23:09:01 EDT
******************************
USENET -> posting only through cbosgd!std-c.
ARPA -> ... through cbosgd!std-c@BERKELEY.ARPA (NOT to INFO-C)
In all cases, you may also reply to the author(s) above.