Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site se-sd.UUCP Path: utzoo!watmath!clyde!burl!ulysses!gamma!epsilon!zeta!sabre!petrus!bellcore!decvax!ittatc!dcdwest!sdcsvax!ncr-sd!se-sd!cbk From: cbk@se-sd.UUCP (cbk) Newsgroups: net.lang.c Subject: Re: Command line arguments, redirection, etc. Message-ID: <36@se-sd.UUCP> Date: Wed, 19-Feb-86 18:08:50 EST Article-I.D.: se-sd.36 Posted: Wed Feb 19 18:08:50 1986 Date-Received: Fri, 21-Feb-86 05:38:26 EST Reply-To: cbk@se-sd.UUCP (Carl Kuck) Followup-To: net.lang.c Organization: NCR Corporation, SE - San Diego Lines: 48 Keywords: redirection arguments [ Inscribed on the line, in very tiny letters, were the words: EAT ME ] Hopefully, this "discussion" about argument passing, redirection, and such can be put to rest once and for all. Here's my two cents worth, having just completed porting the PCC C compiler to a proprietary, decidedly non-UNIX (tm) operating system. 1. Redirection of standard I/O is a part of C, piping is not. Ref: K&R, chapter 7 "Finally, the routines are meant to be 'portable', in the sense that they will exist *in compatible form* on any system where C exists"... The routines mentioned are those which use "standard I/O". See page 144... "output can be redirected to a file by using >...", and "On the UNIX system, a pipe can also be used..." This implies that redirection is required functionality, whereas piping is a part of a particular operating system. 2. Command-line arguments are a part of C. Ref: K&R, chapter 5.11 "In environments that support C, there is a way to pass command-line arguments or parameters to a program when it begins executing." It sounds to me like this whole issue boils down to whether or not someone has taken the time to *correctly* implement C to provide the functionality as specified in K&R (or whatever else happens to be your favorite standard). [ Personal opinion, FLAME ON ] Any implementation of C that doesn't provide redirection and command-line argument passing is half-assed at best. [ FLAME OFF] You know, I feel better already! Hey kiddies, get out YOUR copy of K&R and read, read, read! -- Carl Kuck (apply all standard disclaimers to the preceeding babble) UseNet (west) : {wherever}!sdcsvax!ncr-sd!se-sd!cbk (east) : {wherever}!ihnp4!ncr-sd!se-sd!cbk PacBell: (619) 450-6271 (w), 944-1705 (h) Quote #1: Only those who attempt the absurd can achieve the impossible. Quote #2: 55 mph isn't a good idea, it's just the law...