From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Kevin Ryde Newsgroups: gmane.lisp.guile.devel Subject: set-program-arguments from scheme Date: Sun, 14 Jan 2007 09:25:17 +1100 Message-ID: <87k5zqimya.fsf@zip.com.au> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: sea.gmane.org 1168727153 6199 80.91.229.12 (13 Jan 2007 22:25:53 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sat, 13 Jan 2007 22:25:53 +0000 (UTC) Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Sat Jan 13 23:25:50 2007 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1H5rJg-0001YS-5D for guile-devel@m.gmane.org; Sat, 13 Jan 2007 23:25:36 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1H5rJg-0005Iq-0T for guile-devel@m.gmane.org; Sat, 13 Jan 2007 17:25:36 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1H5rJb-0005Ik-Nh for guile-devel@gnu.org; Sat, 13 Jan 2007 17:25:31 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1H5rJZ-0005IH-AM for guile-devel@gnu.org; Sat, 13 Jan 2007 17:25:31 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1H5rJZ-0005IE-79 for guile-devel@gnu.org; Sat, 13 Jan 2007 17:25:29 -0500 Original-Received: from [61.8.2.231] (helo=mailout2.pacific.net.au) by monty-python.gnu.org with esmtp (Exim 4.52) id 1H5rJY-0003oX-NN for guile-devel@gnu.org; Sat, 13 Jan 2007 17:25:29 -0500 Original-Received: from mailproxy2.pacific.net.au (mailproxy2.pacific.net.au [61.8.2.163]) by mailout2.pacific.net.au (Postfix) with ESMTP id 63D7B6E08F for ; Sun, 14 Jan 2007 09:25:25 +1100 (EST) Original-Received: from localhost (ppp27B1.dyn.pacific.net.au [61.8.39.177]) by mailproxy2.pacific.net.au (Postfix) with ESMTP id C20A927404 for ; Sun, 14 Jan 2007 09:25:26 +1100 (EST) Original-Received: from gg by localhost with local (Exim 4.63) (envelope-from ) id 1H5rJN-0001nM-JF for guile-devel@gnu.org; Sun, 14 Jan 2007 09:25:17 +1100 Original-To: guile-devel@gnu.org Mail-Copies-To: never User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/21.4 (gnu/linux) X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.devel:6421 Archived-At: --=-=-= How about making scm_set_program_arguments() available at the scheme level too? As say (set-program-arguments lst) (without the "first" arg business of the C level). The C func is good for when you munch some options at the C level in an scm_boot_guile, having it at the scheme level would be for the same thing if do it in scheme instead. --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=feature.c.set-prog-args.diff --- feature.c.~1.62.2.1.~ 2006-02-14 08:58:57.000000000 +1100 +++ feature.c 2007-01-13 17:41:19.000000000 +1100 @@ -76,6 +76,21 @@ scm_fluid_set_x (progargs_fluid, args); } +SCM_DEFINE (scm_set_program_arguments_scm, "set-program-arguments", 1, 0, 0, + (SCM lst), + "Set the command line arguments to be returned by\n" + "@code{program-arguments} (and @code{command-line}). @var{lst}\n" + "should be a list of strings, the first of which is the program\n" + "name (either a script name, or just @code{\"guile\"}).\n" + "\n" + "Program arguments are held in a fluid and therefore have a\n" + "separate value in each Guile thread.") +#define FUNC_NAME s_scm_program_arguments +{ + return scm_fluid_set_x (progargs_fluid, lst); +} +#undef FUNC_NAME + --=-=-= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Guile-devel mailing list Guile-devel@gnu.org http://lists.gnu.org/mailman/listinfo/guile-devel --=-=-=--