* libguile/bytevectors.h:
* libguile/bytevectors.c (scm_c_take_gc_bytevector): Rename this
internal function, from scm_c_take_bytevector. This indicates that
unlike the other scm_take_* functions, this one takes GC-managed
memory.
* libguile/objcodes.c (scm_objcode_to_bytecode):
* libguile/vm.c (really_make_boot_program): Use
scm_gc_malloc_pointerless, not scm_malloc. Thanks to Stefan
Israelsson Tampe!
* libguile/r6rs-ports.c:
* libguile/strings.c: Adapt to renames.
* libguile/posix.c (scm_tmpfile): Fix to actually close the new
tmpfile, causing its deletion, while keeping an fd to the file open.
Fixes a leak both in memory and disk space on POSIX systems; MINGW
systems will leak however. A FIXME for later.
* module/srfi/srfi-1.scm (check-arg, wrong-type-arg): Refactor arg type
checkers to be macros, and do the minimal amount of work in the
functions themselves. Use these checkers consistently for all
procedure arguments in this module. This catches user errors early;
see bug 33628.
* module/srfi/srfi-9.scm (define-record-type): Instead of defining the
RTD using make-vtable, use make-struct with the record-type-vtable,
and record the type name and fields names in the vtable. This way
SRFI-9 records are compatible with boot-9 records. Also we use a
generic printer, instead of generating one anew.
* libguile/i18n.c (get_current_locale): Hold the locale name in a
GC-managed string, not a mallocated string. Thanks to Stefan
Israelsson Tampe for the report.
* libguile/srfi-1.h:
* libguile/srfi-1.c (scm_srfi1_drop_right, scm_srfi1_take_right): Remove
these internal functions, replacing with Scheme implementations.
* module/srfi/srfi-1.scm (take-right, drop-right): Add these impls from
the reference code. They do the right thing for improper lists,
according to the spec, but they diverge for circular lists. Oh well.
* test-suite/tests/srfi-1.test ("drop-right", "take-right"): Add more
tests.
* module/language/tree-il.scm (tree-il->scheme): Fix incorporation of
`lambda' in a `case-lambda'.
* test-suite/tests/tree-il.test ("tree-il->scheme"): Add a test.
* module/web/http.scm (parse-month, parse-rfc-822-date):
(parse-rfc-850-date, parse-asctime-date, parse-date):
(write-date): Parse and write dates without regard to the current
locale, using a custom parser. Also permits parsing of the deprecated
RFC 850 and asctime() date formats.
* module/srfi/srfi-19.scm (priv:locale-number-separator, priv:locale-am)
(priv:locale-am): Inline definitions.
Strip priv: prefix from module vars, as it's unnecessary, except for
in a couple cases.
* libguile/load.c (search_path): Extract from scm_search_path, to
give the caller the stat buffer of the found path.
(scm_search_path, scm_sys_search_load_path): Adapt accordingly.
(compiled_is_fresh): Take the stat buffers directly.
(scm_primitive_load_path, scm_init_eval_in_scheme): Adapt to
search_path / compiled_is_fresh changes to avoid duplicate states in
search-path.
* libguile/load.c (scm_primitive_load_path): Don't canonicalize the
filename unless we need to look in the fallback path. Fixes a stat
explosion; see http://savannah.gnu.org/bugs/?33815.
* libguile/scmsigs.c (GC_get_suspend_signal): Fix the back-compatibility
shim for this function to work on some other cases; I hadn't realized
that gcconfig.h could set SIG_SUSPEND. Thanks to Aleix Conchillo
Flaqué for the report.
* meta/guild.in (display-version): Display the version, not the
effective version.
* module/scripts/help.scm (list-commands)[help]: Add proper footer, as
per the GCS.
* doc/ref/scheme-using.texi (Using Guile Tools): Remove redundant
footnote introduced in e108c961fe.
Mention the version where the new name was introduced.
* meta/guild.in (display-version): Use (ice-9 command-line)'s
version-etc.
(main): Dispatch --help to guild help.
* module/scripts/help.scm: New file, a copy of list.scm, but with a
better name.
* module/Makefile.am: Add help.scm to the list.
* module/scripts/list.scm: Change to be an alias to "help".
(list-scripts): Restore this API.
* module/scripts/: Add %summary entries, and in many cases,
%include-in-guild-list entries to inhibit a script from appearing in
"guild list". Update list.scm to respect this new variable.
* module/scripts/PROGRAM.scm: Remove this useless template, which was
cluttering `guild list'. We'll perhaps cull the list a bit more in
2.2.
* module/Makefile.am: Adapt.
* module/scripts/list.scm (strip-extensions): Don't list programs
without extensions.
(main): Be prettier. Parse out a %summary from modules, for a brief
synopsis.
* libguile/Makefile.am (libpath.h): Define SCM_SITE_CCACHE_DIR. Defined
as site-ccache/ instead of site/ccache/ to indicate that we don't expect
further subdirectories, and also to avoid confusion about whether
extensions/ is a site-specific or not.
* libguile/load.c (scm_init_load_path): Add SCM_SITE_CCACHE_DIR to the
default load-compiled path.
* module/web/request.scm (build-request): Make sure that HTTP/1.1
requests have the Host header set, per RFC 2616 section 9.
* test-suite/tests/web-request.test ("example-1"): Add test.
* libguile/goops.c (fix_cpl): Fix bug in placement of debug assertion.
(create_standard_classes): Put <extended-generic> before
<generic-with-setter> in <extended-generic-with-setter>'s direct
supers, so that the slot allocation is a superset of
<generic-with-setter>, which results in the `setter' being allocated
in the same place.
Likewise fix <extended-accessor> to place <extended-generic> before
<generic-with-setter>, not just <generic>.
* libguile/modules.c (resolve_duplicate_binding): Fix unbound -> #f
conversion for the imported bindings. Pass the existing entry in the
import obarray as the resolved var (7th arg), and properly pass #f as
the value (8th arg) if there is no such binding. Fixes
merge-generics; before, the <boolean> type test (indicating no
previous value) was not being triggered. This bug has been present
since 2007 at least, though it was not in 1.8.
* test-suite/tests/modules.test ("duplicate bindings"): Add a test that
the var and val are both #f. These types are used by GOOPS.
* module/system/repl/command.scm (time): Use the high-precision timers
instead of stime(2). Changes the output format of `,time' too;
perhaps there is a better way.