1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-18 18:40:22 +02:00
Commit graph

15927 commits

Author SHA1 Message Date
Andy Wingo
e1cb762c9a Keep trucking on weak table corruption
* libguile/hashtab.c (vacuum_weak_hash_table): Don't abort if we
  apparently remove more items than are in the table; instead print a
  warning.  "Fixes" #19180.
2016-07-12 09:30:10 +02:00
Andy Wingo
9c783616cc Reduce-right not limited by stack
* module/srfi/srfi-1.scm (reduce-right): Avoid blowing out the stack.
  Fixes #17485.
2016-07-12 09:05:51 +02:00
Andy Wingo
61b8794e04 Rename win32-uname.[ch] to posix-w32.[ch]
* libguile/posix-w32.c:
* libguile/posix-w32.h: Rename from win32-uname.c and win32-uname.h.
* libguile/posix.c:
* libguile/Makefile.am
  (EXTRA_libguile_@GUILE_EFFECTIVE_VERSION@_la_SOURCES)
  (noinst_HEADERS): Adapt.
2016-07-11 23:18:27 +02:00
Andy Wingo
8e48a58fcb Ignore meta/build-env
* .gitignore: Ignore meta/build-env.
2016-07-11 23:18:27 +02:00
Andy Wingo
f6dd212045 Factor start_child out of open_process
* libguile/posix.c (start_child): Factor out from open_process.  Based
  on initial work by Eli Zaretskii.
2016-07-11 22:54:33 +02:00
Andy Wingo
0fb3e82cee More specific status:exit-val et al compilation guards
* libguile/posix.c (scm_status_exit_val, scm_status_term_sig)
  (scm_status_stop_sig): Guard on WIFEXITED et al macros instead of on
  MinGW.
2016-07-11 22:54:33 +02:00
Andy Wingo
2ef67d08ef getaffinity, setaffinity docstring cleanup
* libguile/posix.c (scm_getaffinity, scm_setaffinity): Clean up
  docstrings.  Obviously if you have the function, you don't need to be
  told that you have it in the docstring.
2016-07-11 22:17:59 +02:00
Andy Wingo
2247a56d5d Provide `kill' only if supported by the host
* libguile/posix.c (scm_kill): Only provide if the host has `kill'.  An
  incompatible change on MinGW, where this function would work only if
  the PID was the current PID, but that will be fixed by the next
  process.
2016-07-11 22:17:09 +02:00
Andy Wingo
509c4205ba More robust setuid, setgid, etc detection
* configure.ac: Check for getuid, getgid, setuid, and setgid.
* libguile/posix.c (scm_getuid, scm_getgid, scm_setuid, scm_setgid):
  Only provide Scheme functions if the OS provides these facilities.
  (scm_geteuid, scm_getegid, scm_seteuid, scm_setegid): Provide if the
  host has getuid, getgid, etc, instead of being in a MinGW guard.
2016-07-11 22:14:38 +02:00
Andy Wingo
e2c1659d95 Locale is default port encoding
* libguile/ports.c (scm_init_ports): Use the locale as the default
  charset.  This allows GUILE_INSTALL_LOCALE=1 to work properly,
  harmonizing the default port encoding with the installed locale.
2016-07-11 18:21:52 +02:00
Ludovic Courtès
a14e873cce Fix invalid use of 'PTR2SCM'.
Fixes a typo introduced in 04359b42b9.

* libguile/load.c (try_load_thunk_from_file): Use 'SCM2PTR', not
'PTR2SCM'.
2016-07-11 11:04:34 +02:00
Ludovic Courtès
2c5ab455c2 Add missing 'const' qualifier.
* libguile/stime.c (tzvar): Add 'const'.
2016-07-11 11:01:51 +02:00
Ludovic Courtès
2bdd40a696 Unconditionally include <time.h> from Gnulib.
* libguile/stime.c: Unconditionally include <time.h>.
2016-07-11 11:01:51 +02:00
Ludovic Courtès
92b8087d7d build: Remove unneeded check for 'unsetenv'.
* configure.ac: Remove check for 'unsetenv', which is unneeded since we
use Gnulib's 'unsetenv'.
2016-07-11 11:01:51 +02:00
Andy Wingo
5b7b5749e1 Add meta/build-env
* meta/build-env.in: New file which sets up an environment that does not
  inherit GUILE_LOAD_PATH / GUILE_LOAD_COMPILED_PATH (unless
  cross-compiling).
* doc/ref/Makefile.am (autoconf-macros.texi):
* libguile/Makefile.am (snarf2checkedtexi):
* module/Makefile.am (ice-9/psyntax-pp.go):
* test-suite/standalone/Makefile.am (GUILE_INSTALL_LOCALE):
* am/guilec (.scm.go): Use build-env.
* configure.ac: Create build-env.
2016-07-10 13:21:38 +02:00
Andy Wingo
a39ac7db60 Avoid Gnulib unistr/* modules
(unistr/base, unistr/u8-mbtouc, unistr/u8-mbtouc-unsafe)
(unistr/u8-mbtoucr, unistr/u8-prev unistr/u8-uctomb, unitypes): --avoid
these modules.
2016-07-10 12:57:55 +02:00
Andy Wingo
a92acb5fa4 Update Gnulib to 68b6ade.
Also add --conditional-dependencies to the flags.  See:
https://lists.gnu.org/archive/html/guile-devel/2016-07/msg00012.html
2016-07-07 12:39:14 +02:00
Andy Wingo
04359b42b9 Skip incompatible .go files
* libguile/load.c (load_thunk_from_path, try_load_thunk_from_file):
  New functions.
  (search_path): Simplify.
  (scm_primitive_load_path, scm_init_eval_in_scheme): Use the new
  functions to load compiled files.
* module/ice-9/boot-9.scm (load-in-vicinity): Skip invalid .go files.

Inspired by a patch from Jan Nieuwenhuizen <janneke@gnu.org>.
2016-06-29 18:10:24 +02:00
Andy Wingo
abc003fb45 Update NEWS
* NEWS: Update.
2016-06-29 13:10:50 +02:00
Andy Wingo
2b421e02e1 Update Gnulib to 6835fc458f30b94f15d69c35a79cbc2dfabe2d06. 2016-06-29 11:32:05 +02:00
Andy Wingo
bfca4367b0 Update git-version-gen.diff
* gnulib-local/build-aux/git-version-gen.diff: Update to apply to latest
  gnulib.
2016-06-29 11:11:53 +02:00
Andy Wingo
543ec017ef Temporarily use git-version-gen from gnulib 2016-06-29 11:03:50 +02:00
Andy Wingo
e9538ef69b Update NEWS 2016-06-29 10:49:14 +02:00
Ludovic Courtès
8f644ef87a doc: smobs: Fix typos.
* doc/ref/api-smobs.texi (Smobs): Fix typos.
2016-06-28 22:51:57 +02:00
Ludovic Courtès
a5094286c9 Update NEWS. 2016-06-28 22:47:10 +02:00
David Pirotte
a0e96d978d Do not track some test-suite files
* .gitignore:  Adding test-smob-mark-race to the list of the test-suite
  files we do not track.
2016-06-27 09:35:35 +02:00
Andy Wingo
811024669a Add documentation pointer from getopt-long to SRFI-37.
* doc/ref/mod-getopt-long.texi (getopt-long): Point to SRFI-37.
2016-06-26 22:38:00 +02:00
Andy Wingo
da0f1eadaa Favor "escape continuation" over "one-shot continuation" in manual
* doc/ref/api-control.texi (Prompt Primitives): Remove mention of
  one-shot continuations, as it's possible to invoke them multiple times
  if the continuation is re-entered through other means.
2016-06-26 22:38:00 +02:00
Andy Wingo
96f55b7f36 Check for strtod_l before using it.
Based on a patch by Andy Stormont <astormont@racktopsystems.com>.

* configure.ac: Check for strtod_l.
* libguile/i18n.c (scm_locale_string_to_integer): Fix style.
  (scm_locale_string_to_inexact): Check for strtod_l.
2016-06-26 22:37:47 +02:00
Andy Wingo
45b80a1fa8 Constant-folding eq? and eqv? uses deduplication
* test-suite/tests/peval.test ("partial evaluation"): Add tests.
* module/language/tree-il/peval.scm (peval): Constant-fold eq? and eqv?
  using equal?, anticipating deduplication.
2016-06-26 22:37:33 +02:00
Andy Wingo
ef2943e806 Prevent (@ (ice-9 boot-9) x)
* module/ice-9/boot-9.scm: Prevent re-loading, perhaps via (@ (ice-9
  boot-9) foo).  (ice-9 boot-9) isn't a module.  Fixes #21801.
2016-06-26 22:31:21 +02:00
Andy Wingo
a0d76d9c9e Fix texinfo->html for @acronym, @itemize
* module/texinfo/html.scm (itemize, acronym, tag-replacements, rules):
  Fix HTML serialization of @itemize and @acronym.  Fixes #21772.
* test-suite/tests/texinfo.html.test: New file.
* test-suite/Makefile.am: Add new file.
2016-06-26 22:30:57 +02:00
Daniel Llorens
937bd9509c Avoid stifling readline history when looking up options
With this patch, history is never stifled unless (readline-set!) is used.

* src/guile-readline/readline.c (scm_readline_options)
2016-06-26 22:30:05 +02:00
Andy Wingo
8707958e6c Fix typo about `keywords' read option
* doc/ref/api-data.texi (Keyword Read Syntax): Fix typo.  Thanks to
  Glenn Michaels for the report and fix.
2016-06-26 22:27:54 +02:00
Andy Wingo
1d5e60df84 Fix ,profile in pure modules
* libguile/scmsigs.c (close_1): Make the async closure in an environment
  where `lambda' has its usual meaning.  Fixes #21013.
2016-06-26 22:27:49 +02:00
Andy Wingo
9591da310e Clarify use of the term "scanning" in the manual
* doc/ref/api-memory.texi (Garbage Collection Functions):
* doc/ref/libguile-concepts.texi (Garbage Collection): Attempt to be
  clear that scanning is a thing that happens in the mark phase.  Fixes
  #20907 I think.
2016-06-26 22:27:18 +02:00
Andy Wingo
387010196f Fix R6RS fold-left documentation
* doc/ref/r6rs.texi (rnrs lists): Fix documentation of fold-left.
2016-06-26 22:26:59 +02:00
Andy Wingo
ea352d9e54 Fix bug that exposed `list' invocations to CSE
* module/language/tree-il/effects.scm (make-effects-analyzer):
  Fix analysis for list, cons, make-prompt-tage, and vector; &allocation
  is a `cause' effect.  Fixes #21899.
* test-suite/tests/cse.test ("cse"): Add test case.
2016-06-24 19:03:36 +02:00
Andy Wingo
b8e3e2ff4f CSE visits prompt body in values context
* module/language/tree-il/cse.scm (cse): Visit prompt body in values
  context, similar to recent peval fix.
2016-06-24 18:53:58 +02:00
David Pirotte
c9710a9586 Updating NEWS for 2.0.12 - draft
* NEWS:  Updating NEWS for 2.0.12 - draft
2016-06-23 23:04:30 +02:00
Andy Wingo
f763f353e4 Register R6RS port and bytevector internals early
* libguile/bytevectors.c (sym_big, sym_little): Rename from scm_sym_big
  and scm_sym_little, and don't use the snarf mechanism as we need to
  initialize this value eagerly in case the C API is used before the
  Scheme module is loaded.
  (scm_bootstrap_bytevectors): Initialize the endianness symbols here.
* libguile/r6rs-ports.c (scm_register_r6rs_ports): Register the R6RS
  port kinds here, for the same reason.
2016-06-23 18:31:55 +02:00
Andy Wingo
cf1d313940 Fix memory leak in scm_from_{u,}int64 on 32-bit platforms
* libguile/conv-integer.i.c (SCM_FROM_TYPE_PROTO):
* libguile/conv-uinteger.i.c (SCM_FROM_TYPE_PROTO): Fix a big in which
  scm_from_int64 and scm_from_uint64 on a 32-bit platform leaked memory
  if they needed to allocate a bignum.  Fixes #20079.
2016-06-23 15:00:00 +02:00
Andy Wingo
8dff3af087 Fix race between SMOB marking and finalization
* libguile/smob.c (clear_smobnum): New helper.
  (finalize_smob): Re-set the smobnum to the "finalized smob" type
  before finalizing.  Fixes #19883.
  (scm_smob_prehistory): Pre-register a "finalized smob" type, which has
  no mark procedure.
* test-suite/standalone/test-smob-mark-race.c: New file.
* test-suite/standalone/Makefile.am: Arrange to build and run the new
  test.
2016-06-23 12:17:51 +02:00
Andy Wingo
08df681976 Remove unused internal i18n functions
* libguile/i18n.c (str_upcase, str_downcase, str_upcase_l)
  (str_downcase_l): Remove unused inline functions.  Based on a patch by
  Pedro Aguilar <paguilar@paguilar.org>.  Fixes #19172.
2016-06-22 16:48:03 +02:00
Andy Wingo
dde0d17f8e Use source file permissions for compiled files
* module/system/base/compile.scm (call-with-output-file/atomic): Use the
  permissions of the source file, if available, as the permissions of
  the compiled file.  Fixes #18477.
2016-06-21 18:05:16 +02:00
Andy Wingo
8c8499a5e4 Document pretty-print #:max-expr-width
* doc/ref/misc-modules.texi (Pretty Printing): Document #:max-expr-width
  keyword argument.  Fixes #17657.
2016-06-21 18:05:10 +02:00
Andy Wingo
961e226104 Detect too-old libunistring at configure-time.
* configure.ac: Detect too-old libunistring at configure-time.  Fixes
  #17399.
2016-06-21 18:04:48 +02:00
Andy Wingo
64039f3d12 Update and-let-star.test
* test-suite/tests/and-let-star.test ("and-let*"): Update test
  expectations.
2016-06-21 18:04:42 +02:00
Taylan Ulrich Bayırlı/Kammer
4034a9c5fe Add SRFI-2 (and-let*) test suite.
* test-suite/tests/srfi-2.test: New file.
* test-suite/Makefile.am (SCM_TESTS): Add it.
2016-06-21 18:04:34 +02:00
Taylan Ulrich Bayırlı/Kammer
57e8775915 Fix SRFI-2 (and-let*) implementation.
* module/ice-9/and-let-star.scm (%and-let*): Re-implemented this in a
  more verbose but accurate way.
2016-06-21 18:04:24 +02:00