From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andy Wingo Newsgroups: gmane.lisp.guile.devel Subject: Re: Patch: New section "Invoking Guile" for chapter "Programming in Scheme" Date: Sun, 24 Apr 2011 16:33:44 +0200 Message-ID: References: <8CDD0063C9BEB29-FC8-5987@web-mmc-d08.sysops.aol.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1303655641 13989 80.91.229.12 (24 Apr 2011 14:34:01 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 24 Apr 2011 14:34:01 +0000 (UTC) Cc: guile-devel@gnu.org To: Mark Harig Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Sun Apr 24 16:33:57 2011 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1QE0Nn-0003TZ-HD for guile-devel@m.gmane.org; Sun, 24 Apr 2011 16:33:55 +0200 Original-Received: from localhost ([::1]:55744 helo=lists2.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QE0Nm-0006zO-TN for guile-devel@m.gmane.org; Sun, 24 Apr 2011 10:33:54 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:37213) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QE0Nk-0006zJ-7E for guile-devel@gnu.org; Sun, 24 Apr 2011 10:33:53 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QE0Ni-0006LV-Sx for guile-devel@gnu.org; Sun, 24 Apr 2011 10:33:52 -0400 Original-Received: from a-pb-sasl-sd.pobox.com ([64.74.157.62]:56419 helo=sasl.smtp.pobox.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QE0Ni-0006LO-OQ for guile-devel@gnu.org; Sun, 24 Apr 2011 10:33:50 -0400 Original-Received: from sasl.smtp.pobox.com (unknown [127.0.0.1]) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTP id 4EA9A471B; Sun, 24 Apr 2011 10:35:51 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; s=sasl; bh=rKxjrdhvI53xGdeqLW9npNf1xfc=; b=WjRGWp n/duBZoL4ZabOF6IiAjv19ERGK/Y5GX2pien8ISk4q41cbRQFd7iKtKj0W7kymlM rYZE9+AvJzBWfRTNvdviEFKqtoeOoBmZN04W46uBIp16b0EaiS7rajqM3Zl1aqlL E6D99hhHJSm3I98WqzF70EQusf08RsRZ/LOIg= DomainKey-Signature: a=rsa-sha1; c=nofws; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; q=dns; s=sasl; b=x9RstMbyZP7rtPTkP6VUVYtAsUmR0817 cX0NmPyiGNCOjP12gKRB+5H4ZBwekiNFpjrC+C3qzXpG5kgrGatmZnGX74vZJ5Hc tw3f2+lOSaCgFIPmVhuMaQDy5PEqhEVMIFSPyzJMlI1bdk3KwLy6OY6q33Jxdx37 8/iAGf5WV+Q= Original-Received: from a-pb-sasl-sd.pobox.com (unknown [127.0.0.1]) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTP id 3B8C1471A; Sun, 24 Apr 2011 10:35:50 -0400 (EDT) Original-Received: from unquote.localdomain (unknown [90.164.198.39]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTPSA id 4FB8F4719; Sun, 24 Apr 2011 10:35:48 -0400 (EDT) In-Reply-To: <8CDD0063C9BEB29-FC8-5987@web-mmc-d08.sysops.aol.com> (Mark Harig's message of "Sat, 23 Apr 2011 15:46:13 -0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) X-Pobox-Relay-ID: 2671F4FC-6E80-11E0-B4B1-E8AB60295C12-02397024!a-pb-sasl-sd.pobox.com X-detected-operating-system: by eggs.gnu.org: Solaris 10 (beta) X-Received-From: 64.74.157.62 X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Original-Sender: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.devel:12328 Archived-At: On Sat 23 Apr 2011 21:46, Mark Harig writes: > Here is a set of patches to add the new section "Invoking Guile" to > the chapter "Programming in Scheme." They look good in general, though I have some comments. I would like Neil to look over them as well, or at least say he's OK with them. First, your patches should be "atomic"; see http://www.kernel.org/pub/software/scm/git/docs/user-manual.html#patch-series for some commentary. In particular see point 3. The manual should be working after each patch. The commit logs are good. > +@item -s @var{script} @var{arg...} > +@cindex script mode > +Read and evaluate Scheme source code from the file @var{script}, as the > +@code{load} function would. After loading @var{script}, exit. Any > +command-line arguments @var{arg...} following @var{script} become the > +script's arguments; the @code{command-line} function returns a list of > +strings of the form @code{(@var{script} @var{arg...})}. The "-s" is actually optional, and only *needed* if your script starts with a dash. So please document "guile foo.scm" as the default, and just mention "-s" in case of the script starting with a dash, or if you are writing some other shell script. Use @itemx in this case, I think. > +strings, even those that are written as numerals. (Note that here we > +are referring to names and values that are defined in the operating > +system shell from which Guile is invoked. This is not the same as a > +Scheme environment that is defined within a running instance of guile. "Guile", I think. > +How to set environment variables before starting Guile depends on the > +operating system, and especially the shell that you are using. For > +example, here's how to set the environment variable @env{ORGANIZATION} > +to @samp{not very much} using Bash: > + > +@example > +export ORGANIZATION="not very much" > +@end example > + > +@noindent > +and here's how to do it in csh or tcsh: > + > +@example > +setenv ORGANIZATION "not very much" > +@end example Perhaps the tcsh example is superfluous. Perhaps we should also mention the way to set env vars for one invocation: "GUILE_AUTO_COMPILE=0 guile". > +If you wish to retrieve or change the value of the shell environment > +variables that effect the run-time behavior of Guile from within a > +running instance of guile, see @xref{Runtime Environment}. "affect" > +@item GUILE_HUSH > +@vindex GUILE_HUSH > +The @code{#/} notation for lists provokes a warning message from Guile. > +This syntax will be removed from Guile in the near future. > + > +To disable the warning message, set the @env{GUILE_HUSH} environment > +variable to any non-empty value. This variable does not exist. > +@item GUILE_INIT_MALLOC_LIMIT > +@vindex GUILE_INIT_MALLOC_LIMIT > +@item GUILE_MIN_YIELD_MALLOC > +@vindex GUILE_MIN_YIELD_MALLOC > +@cindex garbage collecting > +@item GUILE_MAX_SEGMENT_SIZE > +@vindex GUILE_MAX_SEGMENT_SIZE > +@item GUILE_INIT_SEGMENT_SIZE_2 > +@vindex GUILE_INIT_SEGMENT_SIZE_2 > +@item GUILE_INIT_SEGMENT_SIZE_1 > +@vindex GUILE_INIT_SEGMENT_SIZE_1 > +@item GUILE_MIN_YIELD_2 > +@vindex GUILE_MIN_YIELD_2 Since switching to the BDW GC, these variables are not used any more. GC_FREE_SPACE_DIVISOR is parsed by Guile though. The GC itself does appear to do a number of getenv calls, but we can't really document those in Guile I don't think. > +@item GUILE_SYSTEM_LOAD_COMPILED_PATH > +@item GUILE_SYSTEM_PATH > +@item GUILE_SYSTEM_LTDL_PATH These are paths that Guile itself uses to look up .go, .scm, and .so files, respectively. They have default values, relative to $prefix, but can be overridden if you really know what you're doing. This is only really useful when building Guile itself. > +@item GUILE_INIT_SEGMENT_SIZE_1 > +@item GUILE_MIN_YIELD_1 > +@item GUILE_INIT_SEGMENT_SIZE_2 > +@item GUILE_MIN_YIELD_2 > +@item GUILE_MAX_SEGMENT_SIZE > +@item GUILE_INIT_HEAP_SIZE_1 > +@item GUILE_INIT_HEAP_SIZE_2 Not used any more. > +@item GUILE_WARN_DEPRECATED > +@vindex GUILE_WARN_DEPRECATED > +Please provide a description of me. @ref to Deprecation. wingo@unquote:~/src/guile$ meta/guile GNU Guile 2.0.0.202-514ff6 Copyright (C) 1995-2011 Free Software Foundation, Inc. Guile comes with ABSOLUTELY NO WARRANTY; for details type `,show w'. This program is free software, and you are welcome to redistribute it under certain conditions; type `,show c' for details. Enter `,help' for help. scheme@(guile-user)> (feature? 'foo) $1 = #f scheme@(guile-user)> Some deprecated features have been used. Set the environment variable GUILE_WARN_DEPRECATED to "detailed" and rerun the program to get more information. Set it to "no" to suppress this message. wingo@unquote:~/src/guile$ GUILE_WARN_DEPRECATED=detailed meta/guile GNU Guile 2.0.0.202-514ff6 Copyright (C) 1995-2011 Free Software Foundation, Inc. Guile comes with ABSOLUTELY NO WARRANTY; for details type `,show w'. This program is free software, and you are welcome to redistribute it under certain conditions; type `,show c' for details. Enter `,help' for help. scheme@(guile-user)> (feature? 'foo) `feature?' is deprecated. Use `provided?' instead. $1 = #f scheme@(guile-user)> wingo@unquote:~/src/guile$ Otherwise, looking very good. Thank you for this work, and looking forward to the revised patchset :-) Cheers, Andy -- http://wingolog.org/