From mboxrd@z Thu Jan 1 00:00:00 1970 From: Wolfgang Denk Date: Sat, 26 Sep 2020 10:55:09 +0200 Subject: [PATCH 0/3] add "call" command In-Reply-To: <823e5d31-7022-346e-b3a3-e36a4a295764@prevas.dk> References: <20200925111942.4629-1-rasmus.villemoes@prevas.dk> <4b00225d-d960-4a14-9aec-110ddddf7f30@gmx.de> <4118922.1601039395@gemini.denx.de> <99821acf-b921-2c06-05b8-dd32058f28f2@gmx.de> <823e5d31-7022-346e-b3a3-e36a4a295764@prevas.dk> Message-ID: <4185668.1601110509@gemini.denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Rasmus, In message <823e5d31-7022-346e-b3a3-e36a4a295764@prevas.dk> you wrote: > > Though I'd probably make it > > run varname -- arg1 arg2 arg3 Or rather run arg1 arg2 ... -- varname1 varname2 ... > instead: Just use -- as a separator [that has precedent as "stop doing > X, use the rest as argv", though X is normally "interpret options" and > now it would be "read function names to run"], and only allow a single > "function" to be called. Otherwise, I don't there's any natural answer > to whether all the varnameX or only the last should be called with the > positional arguments. "run" has always taken any number of vaiable names to run, and this behaviour should be kept. If there are arguments, these are the same for all of these. If you need indivisual argument settings, you must break the sommand in parts combined with &&. Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de (null cookie; hope that's ok)