From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Stuart D. Herring" Newsgroups: gmane.emacs.devel Subject: Re: Quote file name args to start-process-shell-command? Date: Thu, 12 Oct 2006 11:11:45 -0700 (PDT) Message-ID: <42118.128.165.123.18.1160676705.squirrel@webmail.lanl.gov> References: <452D54D8.7060705@student.lu.se> <452DDBC8.2060606@student.lu.se> <85y7rmou5t.fsf@lola.goethe.zz> <85bqohmvpg.fsf@lola.goethe.zz> Reply-To: herring@lanl.gov NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Trace: sea.gmane.org 1160678441 4704 80.91.229.2 (12 Oct 2006 18:40:41 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 12 Oct 2006 18:40:41 +0000 (UTC) Cc: Lennart Borgman , Eli Zaretskii , emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Oct 12 20:40:37 2006 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1GY52R-0004xF-9Y for ged-emacs-devel@m.gmane.org; Thu, 12 Oct 2006 20:12:12 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GY52Q-0008Tb-5s for ged-emacs-devel@m.gmane.org; Thu, 12 Oct 2006 14:12:10 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1GY52B-0008St-JD for emacs-devel@gnu.org; Thu, 12 Oct 2006 14:11:55 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1GY529-0008Oe-MW for emacs-devel@gnu.org; Thu, 12 Oct 2006 14:11:55 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GY529-0008OU-Gk for emacs-devel@gnu.org; Thu, 12 Oct 2006 14:11:53 -0400 Original-Received: from [192.65.95.54] (helo=mailwasher-b.lanl.gov) by monty-python.gnu.org with esmtp (Exim 4.52) id 1GY5AM-0007HR-6z; Thu, 12 Oct 2006 14:20:22 -0400 Original-Received: from mailrelay1.lanl.gov (mailrelay1.lanl.gov [128.165.4.101]) by mailwasher-b.lanl.gov (8.13.8/8.13.8/(ccn-5)) with ESMTP id k9CIBlMB024956; Thu, 12 Oct 2006 12:11:47 -0600 Original-Received: from webmail1.lanl.gov (webmail1.lanl.gov [128.165.4.106]) by mailrelay1.lanl.gov (8.13.8/8.13.8/(ccn-5)) with ESMTP id k9CIBkML022435; Thu, 12 Oct 2006 12:11:46 -0600 Original-Received: from webmail1.lanl.gov (localhost.localdomain [127.0.0.1]) by webmail1.lanl.gov (8.12.11.20060308/8.12.11) with ESMTP id k9CIBkRs010761; Thu, 12 Oct 2006 12:11:46 -0600 Original-Received: (from apache@localhost) by webmail1.lanl.gov (8.12.11.20060308/8.12.11/Submit) id k9CIBj9D010758; Thu, 12 Oct 2006 11:11:45 -0700 X-Authentication-Warning: webmail1.lanl.gov: apache set sender to herring@lanl.gov using -f Original-Received: from 128.165.123.18 (SquirrelMail authenticated user 196434) by webmail.lanl.gov with HTTP; Thu, 12 Oct 2006 11:11:45 -0700 (PDT) In-Reply-To: Original-To: "Stefan Monnier" User-Agent: SquirrelMail/1.4.6-7.el3.7lanl X-Priority: 3 (Normal) Importance: Normal X-PMX-Version: 4.7.1.128075 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:60678 Archived-At: >> I agree with the gist of your patch which removes the confusion about >> the args. > >> But it does this only in the doc string, not the code itself. This >> gives the function "hidden" backwards compatibility. > >> I don't think that is really a good idea: I think the code should >> follow suit. > > Well, I guess the docstring should do like the `sit-for' does, and mention > the old calling convention and mention that it's deprecated. Unless it makes sense on VMS (about which I know nothing) to do something like (start-process "foo" "*bar*" "ls -l") (since `start-process-shell-command' redirects to an identical `start-process' call on VMS), which would be the preferred mode of operation for this function, the function is broken already. I tend to agree with David that, as written, this function is fundamentally confused (and confusing): if the client (a Lisp program) really has separate arguments for a process (a "command line"), it should be calling `start-process' anyway. If a client has a true command line, it should (be required to) do any dynamic construction required for the command itself if only to make it obvious to the reader what construction is occurring. To me, the only question is whether the whole-command-as-string case works on VMS: if it does, we can just change the argument list, avoid calling `apply', and hope that the compatibility impact isn't too great (I see that all 2 calls to s-p-s-c in 21 use just one string, and that in 22 only pgg-pgp5.el, pgg-pgp.el, and grep.el have calls to s-p-s-c or c-p-s-c that would need changing). If my earlier example doesn't work on VMS, though, we still need to change the argument list just because the function will have to do some magic to make the command work (possibly involving emulating the shell to some extent) and it would be far too confusing to layer that transformation on top of the implied argument concatenation. For what it's worth, the implementation-equivalent `call-process-shell-command' didn't exist in 21, so there's no compatibility consideration there. If we decide to actually make the change, I'll be glad to write the change and fix those three files to be compatible. Davis -- This product is sold by volume, not by mass. If it appears too dense or too sparse, it is because mass-energy conversion has occurred during shipping.