Article View: comp.std.unix
Article #736Re: Is there a standard prototype for `execvp'?
From: Henry Spencer
Date: Mon, 04 Feb 1991 19:39
Date: Mon, 04 Feb 1991 19:39
19 lines
1443 bytes
1443 bytes
Submitted-by: henry@zoo.toronto.edu (Henry Spencer) In article <17574@cs.utexas.edu> donn@hpfcrn.fc.hp.com (Donn Terry) writes: > int execvp (const char *file, char *const argv[]); > >It was generally agreed during balloting that what really was wanted >was "const char * const argv[]". However, ANSI C disagrees: that's >a syntax error! This puzzled me a bit, since that is *not* a syntax error, but a bit of private correspondence with Donn cleared it up. The problem is not that the declaration is illegal, but that `char *[]' and `const char *const []' are not assignment-compatible -- the "inner" const does not magically get ignored like the "outer" one -- so this would break backward compatibility. -- "Maybe we should tell the truth?" | Henry Spencer at U of Toronto Zoology "Surely we aren't that desperate yet." | henry@zoo.toronto.edu utzoo!henry Volume-Number: Volume 22, Number 106
Technical Details
Message-ID:
<17634@cs.utexas.edu>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!jsqReferences:
<17528@cs.utexas.edu> <17573@cs.utexas.edu> <17574@cs.utexas.edu>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!jsq From: henry@zoo.toronto.edu (Henry Spencer) Newsgroups: comp.std.unix Subject: Re: Is there a standard prototype for `execvp'? Message-ID: <17634@cs.utexas.edu> Date: 4 Feb 91 19:39:21 GMT References: <17528@cs.utexas.edu> <17573@cs.utexas.edu> <17574@cs.utexas.edu> Sender: jsq@cs.utexas.edu Organization: U of Toronto Zoology Lines: 19 Approved: jsq@cs.utexas.edu (Moderator, John S. Quarterman) X-Submissions: std-unix@uunet.uu.net