* libguile/read.c (read_token): Don't take the string-write mutex when
reading a token into a buffer, because it's assumed that the buffer is
fresh (not seen by other threads), and a soft port can call a
procedure that needs the string-write mutex.
* libguile/vm-engine.c (VM_NAME): Engines take the VM itself (not the
vp), so they can pass the VM to hooks. No more hook args, we dispatch
without them.
* libguile/vm-engine.h (RUN_HOOK): Dispatch the hook if the trace level
is positive (instead of if the hook is there). Don't cache registers
on return from the dispatch.
* libguile/vm.h:
* libguile/vm.c (vm_dispatch_hook): Don't bother with a dynwind; instead
decrement the trace level when going into a hook, and if we have a
nonlocal exit, the trace level never gets incremented again. Worse is
better.
(make_vm, scm_vm_trace_level, scm_set_vm_trace_level_x): New concept,
trace level. If positive, we run the hooks, otherwise we don't. Should
work. Removed scm_vm_trace_frame, I don't think that was the right way
to do it.
* module/system/vm/vm.scm: Replace vm-trace-frame with vm-trace-level
and set-vm-trace-level!; the hooks actually get the frame as an
argument now.
* libguile/eval.h:
* libguile/eval.c (scm_call_n): New function, applies a function to an
array of args.
* libguile/hooks.h:
* libguile/hooks.c (scm_c_run_hookn): New function, runs a hook with an
array of args.
* doc/ref/intro.texi (Introduction): Add menu entries and sections for
`Guile and the GNU Project', `Interactive Programming' and
`Supporting Multiple Languages'.
* module/texinfo.scm (parser-error): Throw to 'parser-error, as ssax's
input-parse does.
(texi-command-depth): Fix docstring so as not to confuse emacs.
(parse-table-args): Fix parser-error call to include port.
* module/statprof.scm (make-call-data): Change so that call-data holds
the proc, not its name. Remove set-call-data-name!.
(get-call-data): Adapt caller.
(sample-stack-procs): Always sample procedures on the stack, even
anonymous ones.
(profile-signal-handler): Fix stack cutting to work with compiled
statprof.scm.
(count-call): Always count calls, even to anonymous procedures.
(statprof-call-data->stats): Use call-data-printable for printing the
call data.
(statprof-display-anomolies): Fix a couple longstanding bugs caught by
compiler warnings.
* module/Makefile.am (LIB_SOURCES): Add statprof, sxml, and texinfo to
the build.
(NOCOMP_SOURCES): Reindent, and add the upstream SSAX files.
* module/statprof.scm:
* module/sxml/apply-templates.scm:
* module/sxml/fold.scm:
* module/sxml/simple.scm:
* module/sxml/ssax.scm:
* module/sxml/ssax/input-parse.scm:
* module/sxml/transform.scm:
* module/sxml/upstream/COPYING.SSAX:
* module/sxml/upstream/SSAX.scm:
* module/sxml/upstream/SXML-tree-trans.scm:
* module/sxml/upstream/SXPath-old.scm:
* module/sxml/upstream/assert.scm:
* module/sxml/upstream/input-parse.scm:
* module/sxml/xpath.scm:
* module/texinfo.scm:
* module/texinfo/docbook.scm:
* module/texinfo/html.scm:
* module/texinfo/indexing.scm:
* module/texinfo/plain-text.scm:
* module/texinfo/reflection.scm:
* module/texinfo/serialize.scm:
* module/texinfo/string-utils.scm: Add files from guile-lib to Guile.
It's only Richard, Andreas, Rob, and myself that have copyright on
these, and we have all assigned to the FSF. SSAX itself is in the
public domain.
* libguile/goops.h:
* libguile/goops.c (scm_add_method): Remove this function. It didn't
work, and even if we fixed it to work it wouldn't be as good as using
Scheme's `add-method!'.
* libguile/load.c (scm_init_load_path): Search first in Guile's
version-specific path (the library path), *then* in the site dir. This
should allow us to import some of Guile-lib's modules into Guile,
perhaps customizing them with Guile-version-specific foo, without
accidentally falling back to system-installed guile-lib in the
sitedir. Also should reduce the number of stats by half, in the common
case.
* module/ice-9/psyntax.scm (gen-label, new-mark): Labels and marks need
to be unique across read/write boundaries -- it's not sufficient for
them to simply be unique within a process by virtue of (string #\i)
constructing a new object. This used to mostly work before, because
the collapsing of duplicate constants didn't catch many syntax-object
cases -- but for some reason the attached test case brings out the
problem. So switch to use gensyms. Potentially more costly, but it's
what upstream psyntax does now.
This bug took me fully two days to figure out.
* module/ice-9/psyntax-pp.scm: Regenerated.
* test-suite/tests/syncase.test ("serializable labels and marks"): Add
test case.
Also continue adding a bit more structure to the introductory "what is
Guile" material.
* doc/ref/intro.texi (Introduction): Split `What is Guile?' (which is
a bad heading, since we've already answered that...) into `Guile and
Scheme' and `Combining with C'. Further splits will follow, to
cover the other toplevel bullet points.
(Guile and Scheme): Remove `packaged for use in a wide variety of
environments', as I don't see what this can mean to the reader at
this point. Add text about R6RS and SRFIs.
(Reporting Bugs fits better immediately after the tour of how to use
Guile)
* doc/ref/intro.texi: Move `Manual Conventions' to after `Reporting
Bugs', and rename to `Typographical Conventions'.
* doc/ref/intro.texi (Discouraged and Deprecated): Move from here...
* doc/ref/api-discdepr.texi: ...to new file here.
* doc/ref/guile.texi: Include api-discdepr.texi, and include
`Discouraged and Deprecated' in API chapter menu.
* doc/ref/Makefile.am (guile_TEXINFOS): Add api-discdepr.texi.
(The principle here is that Preface should only contain
meta-information about the manual, such as how to use it and who wrote
it; plus any political points that we want to draw attention to.)
* doc/ref/preface.texi (Preface): Make unnumbered, for consistency
with other GNU manuals (e.g. Emacs, GSL). Merge layout text into
top level. Simplify first sentence. Move section on conventions
away...
* doc/ref/intro.texi (Introduction to Guile): ...to here.
A few of the @xref references to external manuals in the documentation
are using an old 4-argument form that produces an undefined reference
in the printed manual. The following patch makes them consistent with
the 5-argument @xrefs used elsewhere in the manual.
--
Brian Gough
Network Theory Ltd,
Publishing Free Software Manuals --- http://www.network-theory.co.uk/
>From 6ca0417830dc5a98699a15808591dc1f2a90dfac Mon Sep 17 00:00:00 2001
From: Brian Gough <bjg@gnu.org>
Date: Mon, 14 Dec 2009 21:34:59 +0000
Subject: [PATCH] make the use of the 5-argument @xref command consistent
when referring to other manuals.
This patch adds a short introduction to the SLIB section of the manual
with a link to the SLIB homepage.
--
Brian Gough
Network Theory Ltd,
Publishing Free Software Manuals --- http://www.network-theory.co.uk/
>From 60548b6e039bf57694b7841996cfda011cb8a4bf Mon Sep 17 00:00:00 2001
From: Brian Gough <bjg@gnu.org>
Date: Mon, 14 Dec 2009 20:49:27 +0000
Subject: [PATCH] added brief introduction about SLIB
In the "Hash Tables Example" in the manual, hashq needs 2 arguments
instead of 1 (patch below). I've updated the hash table output as
well to match the current version.
--
Brian Gough
Network Theory Ltd,
Publishing Free Software Manuals --- http://www.network-theory.co.uk/
>From fdb6101d2e064620746ebfc9f9cd28bbdd2470e8 Mon Sep 17 00:00:00 2001
From: Brian Gough <bjg@gnu.org>
Date: Mon, 14 Dec 2009 19:59:32 +0000
Subject: [PATCH] update docs for Hash Table Examples
hashq now takes two arguments
order of elements in hash table is different now
* meta/uninstalled-env.in: Don't use the `-q' and `-E' options, which are
specific to GNU grep. Don't set-and-export environment variables at
once since this is a GNU Bash extension.