🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: net.lang.c
Article #9740

Re: C structs & A question about octet

#9740
From: Henry Spencer
Date: Fri, 07 Nov 1986 19:32
10 lines
1119 bytes
>     Is there any spec that a puts() should a \n at the end of everything?  My
> Microsoft 4.0 compiler does it, and I can't find any reference that describes
> puts() doing something like that in K&R.  Is this a new standard?

No, it's an extremely old one.  You won't find puts() (or its friend gets())
in K&R at all -- they are too old and too thoroughly obsolete.  Try using
fputs(), which is the modern equivalent (and does not add a newline).
-- 
				Henry Spencer @ U of Toronto Zoology
				{allegra,ihnp4,decvax,pyramid}!utzoo!henry
Technical Details
Message-ID: <7297@utzoo.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!henry
References: <2904@rsch.WISC.EDU>, <2005@well.UUCP>

Show Full Headers
Complete Article Headers
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: arc1-ca.pugleaf.net!utzoo!henry
From: henry@utzoo.UUCP (Henry Spencer)
Newsgroups: net.lang.c
Subject: Re: C structs & A question about octet
Message-ID: <7297@utzoo.UUCP>
Date: Fri, 7-Nov-86 14:32:55 EST
Article-I.D.: utzoo.7297
Posted: Fri Nov  7 14:32:55 1986
Date-Received: Fri, 7-Nov-86 14:32:55 EST
References: <2904@rsch.WISC.EDU>, <2005@well.UUCP>
Organization: U of Toronto Zoology
Lines: 10
Keywords: Alignment, structs, word sizes, puts(), \n